Package ubic.gemma.rest.util.args
Class AbstractArrayArg<T>
- java.lang.Object
-
- ubic.gemma.rest.util.args.AbstractArg<List<T>>
-
- ubic.gemma.rest.util.args.AbstractArrayArg<T>
-
- Direct Known Subclasses:
AbstractEntityArrayArg
,ExcludeArg
,StringArrayArg
public abstract class AbstractArrayArg<T> extends AbstractArg<List<T>>
Class representing an API argument that should be an array.If you use this alongside a
QueryParam
, make sure that you include aParameter
with the 'explode' attribute set toExplode.FALSE
, otherwise the serialization will not be correct.- Author:
- tesarst
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
AbstractArrayArg(List<T> values)
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description protected static List<String>
splitAndTrim(String arg)
Split a string by the ',' comma character and trim the resulting pieces.-
Methods inherited from class ubic.gemma.rest.util.args.AbstractArg
getValue, toString
-
-
-
-
Field Detail
-
ERROR_MSG
protected static final String ERROR_MSG
- See Also:
- Constant Field Values
-
-
Method Detail
-
splitAndTrim
protected static List<String> splitAndTrim(String arg)
Split a string by the ',' comma character and trim the resulting pieces. This is meant to be used for parsing query arguments that use a comma as a delimiter.- Parameters:
arg
- the string to process- Returns:
- trimmed strings exploded from the input.
-
-