@AlfrescoPublicApi public static enum MetadataExtracter.OverwritePolicy extends Enum<MetadataExtracter.OverwritePolicy>
Enum Constant and Description |
---|
CAUTIOUS
This policy only puts the extracted value if there is no value (null or otherwise) in the properties map.
|
EAGER
This policy puts the new value if:
the extracted property is not null
null extracted values are return in the 'modified' map.
|
PRAGMATIC
This policy puts the new value if:
the extracted property is not null
either:
there is no target key for the property
the target value is null
the string representation of the target value is an empty string
or:
the extracted property is a media related one (eg Image, Audio or Video)
null extracted values are return in the 'modified' map.
|
PRUDENT
This policy puts the new value if:
the extracted property is not null
there is no target key for the property
the target value is null
the string representation of the target value is an empty string
null extracted values are return in the 'modified' map.
|
Modifier and Type | Method and Description |
---|---|
Map<org.alfresco.service.namespace.QName,Serializable> |
applyProperties(Map<org.alfresco.service.namespace.QName,Serializable> extractedProperties,
Map<org.alfresco.service.namespace.QName,Serializable> targetProperties)
Apply the overwrite policy for the extracted properties.
|
static MetadataExtracter.OverwritePolicy |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static MetadataExtracter.OverwritePolicy[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final MetadataExtracter.OverwritePolicy EAGER
public static final MetadataExtracter.OverwritePolicy PRAGMATIC
public static final MetadataExtracter.OverwritePolicy PRUDENT
public static final MetadataExtracter.OverwritePolicy CAUTIOUS
public static MetadataExtracter.OverwritePolicy[] values()
for (MetadataExtracter.OverwritePolicy c : MetadataExtracter.OverwritePolicy.values()) System.out.println(c);
public static MetadataExtracter.OverwritePolicy valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic Map<org.alfresco.service.namespace.QName,Serializable> applyProperties(Map<org.alfresco.service.namespace.QName,Serializable> extractedProperties, Map<org.alfresco.service.namespace.QName,Serializable> targetProperties)
Copyright © 2005–2017 Alfresco Software. All rights reserved.