[DS-1883] Un-deprecate DCValue and rename it.

It seems that the reason for deprecation was objection to the *name*,
since it is not strictly for DC anymore.
This commit is contained in:
Mark H. Wood
2014-10-02 15:28:47 -04:00
parent a5d077b708
commit e440e64739
122 changed files with 611 additions and 609 deletions

View File

@@ -18,7 +18,7 @@ import java.util.List;
import java.util.Map;
import java.util.Map.Entry;
import org.dspace.authorize.AuthorizeException;
import org.dspace.content.DCValue;
import org.dspace.content.Metadatum;
import org.dspace.content.DSpaceObject;
import org.dspace.content.Item;
import org.dspace.content.ItemIterator;
@@ -130,8 +130,8 @@ public class EZIDIdentifierProvider
}
Item item = (Item)dso;
DCValue[] identifiers = item.getMetadata(MD_SCHEMA, DOI_ELEMENT, DOI_QUALIFIER, null);
for (DCValue identifier : identifiers)
Metadatum[] identifiers = item.getMetadata(MD_SCHEMA, DOI_ELEMENT, DOI_QUALIFIER, null);
for (Metadatum identifier : identifiers)
{
if ((null != identifier.value) && (identifier.value.startsWith(DOI_SCHEME)))
{
@@ -367,8 +367,8 @@ public class EZIDIdentifierProvider
}
Item item = (Item)object;
DCValue found = null;
for (DCValue candidate : item.getMetadata(MD_SCHEMA, DOI_ELEMENT, DOI_QUALIFIER, null))
Metadatum found = null;
for (Metadatum candidate : item.getMetadata(MD_SCHEMA, DOI_ELEMENT, DOI_QUALIFIER, null))
{
if (candidate.value.startsWith(DOI_SCHEME))
{
@@ -402,10 +402,10 @@ public class EZIDIdentifierProvider
Item item = (Item)dso;
// delete from EZID
DCValue[] metadata = item.getMetadata(MD_SCHEMA, DOI_ELEMENT, DOI_QUALIFIER, null);
Metadatum[] metadata = item.getMetadata(MD_SCHEMA, DOI_ELEMENT, DOI_QUALIFIER, null);
List<String> remainder = new ArrayList<String>();
int skipped = 0;
for (DCValue id : metadata)
for (Metadatum id : metadata)
{
if (!id.value.startsWith(DOI_SCHEME))
{
@@ -472,10 +472,10 @@ public class EZIDIdentifierProvider
Item item = (Item)dso;
DCValue[] metadata = item.getMetadata(MD_SCHEMA, DOI_ELEMENT, DOI_QUALIFIER, null);
Metadatum[] metadata = item.getMetadata(MD_SCHEMA, DOI_ELEMENT, DOI_QUALIFIER, null);
List<String> remainder = new ArrayList<String>();
int skipped = 0;
for (DCValue id : metadata)
for (Metadatum id : metadata)
{
if (!id.value.equals(idToDOI(identifier)))
{
@@ -629,10 +629,10 @@ public class EZIDIdentifierProvider
for (Entry<String, String> datum : crosswalk.entrySet())
{
DCValue[] values = item.getMetadataByMetadataString(datum.getValue());
Metadatum[] values = item.getMetadataByMetadataString(datum.getValue());
if (null != values)
{
for (DCValue value : values)
for (Metadatum value : values)
{
String key = datum.getKey();
String mappedValue;