Package org.dspace.app.rest.model
Class MetadataRest
- java.lang.Object
-
- org.dspace.app.rest.model.MetadataRest
-
public class MetadataRest extends Object
Rest representation of a map of metadata keys to ordered lists of values.
-
-
Constructor Summary
Constructors Constructor Description MetadataRest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object object)SortedMap<String,List<MetadataValueRest>>getMap()Gets the map.inthashCode()MetadataRestput(String key, MetadataValueRest... values)Sets the metadata values for a given key.
-
-
-
Method Detail
-
getMap
public SortedMap<String,List<MetadataValueRest>> getMap()
Gets the map.- Returns:
- the map of keys to ordered values.
-
put
public MetadataRest put(String key, MetadataValueRest... values)
Sets the metadata values for a given key.- Parameters:
key- the key.values- the values. The values will be ordered according to theirplacevalue, if nonnegative. Values that are negative (the default is -1) are assumed to be non-explicitly set and will will be ordered at the end of any explicitly ordered values, in the order they are passed to this method.- Returns:
- this instance, to support chaining calls for easy initialization.
-
-