public class DSpaceCSVLine
extends java.lang.Object
implements java.io.Serializable
| Constructor and Description |
|---|
DSpaceCSVLine()
Create a new CSV line for a new item
|
DSpaceCSVLine(int itemId)
Create a new CSV line
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(java.lang.String key,
java.lang.String value)
Add a new metadata value to this line
|
java.util.List<java.lang.String> |
get(java.lang.String key)
Get all the values that match the given metadata key.
|
java.lang.String |
getAction()
Get any action associated with this line
|
int |
getID()
Get the item ID that this line represents
|
java.util.Set<java.lang.String> |
keys()
Get all the metadata keys that are represented in this line
|
protected java.lang.String |
toCSV(java.util.List<java.lang.String> headings)
Write this line out as a CSV formatted string, in the order given by the headings provided
|
protected java.lang.String |
valueToCSV(java.util.List<java.lang.String> values)
Internal method to create a CSV formatted String joining a given set of elements
|
public DSpaceCSVLine(int itemId)
itemId - The item ID of the linepublic DSpaceCSVLine()
public int getID()
public void add(java.lang.String key,
java.lang.String value)
key - The metadata key (e.g. dc.contributor.author)value - The metadata valuepublic java.util.List<java.lang.String> get(java.lang.String key)
key - The metadata keypublic java.lang.String getAction()
public java.util.Set<java.lang.String> keys()
protected java.lang.String toCSV(java.util.List<java.lang.String> headings)
headings - The headings which define the order the elements must be presented inprotected java.lang.String valueToCSV(java.util.List<java.lang.String> values)
values - The values to create the string fromCopyright © 2018 DuraSpace. All Rights Reserved.