public final class PropertiesFileMetadataLoader extends Object
type=cm:content
aspects=cm:versionable, custom:myAspect
cm\:title=This is the value of the cm:title field.
cm\:description=This is the value of the cm:description field.
cm\:taggable=workspace://SpacesStore/3da6c395-3a4b-4a57-836d-8e5
custom\:myProperty=This is the value of the custom:myProperty field.
custom\:aDateProperty=2001-01-01T12:00:00.000+01:00
Notes:
XmlPropertiesFileMetadataLoader
instead.MetadataLoader
MetadataLoader.Metadata
Modifier and Type | Field and Description |
---|---|
protected org.alfresco.service.cmr.dictionary.DictionaryService |
dictionaryService |
protected String |
metadataFileExtension |
protected String |
multiValuedSeparator |
protected org.alfresco.service.namespace.NamespaceService |
namespaceService |
METADATA_SUFFIX
Constructor and Description |
---|
PropertiesFileMetadataLoader(ServiceRegistry serviceRegistry) |
PropertiesFileMetadataLoader(ServiceRegistry serviceRegistry,
String multiValuedSeparator) |
Modifier and Type | Method and Description |
---|---|
String |
getMetadataFileExtension() |
void |
loadMetadata(ImportableItem.ContentAndMetadata contentAndMetadata,
MetadataLoader.Metadata metadata)
Method that populates the type, aspects and properties to attach to a given file or space.
|
protected Map<String,Serializable> |
loadMetadataFromFile(Path metadataFile)
Method that actually loads the properties from the file.
|
protected final org.alfresco.service.namespace.NamespaceService namespaceService
protected final org.alfresco.service.cmr.dictionary.DictionaryService dictionaryService
protected final String multiValuedSeparator
protected final String metadataFileExtension
public PropertiesFileMetadataLoader(ServiceRegistry serviceRegistry)
public PropertiesFileMetadataLoader(ServiceRegistry serviceRegistry, String multiValuedSeparator)
protected Map<String,Serializable> loadMetadataFromFile(Path metadataFile)
metadataFile
- The file to load the properties from (must not be null).Properties
object loaded from that file.org.alfresco.repo.bulkimport.metadataloaders.AbstractMapBasedMetadataLoader#loadMetadataFromFile(java.io.File)
public final String getMetadataFileExtension()
getMetadataFileExtension
in interface MetadataLoader
MetadataLoader.getMetadataFileExtension()
public final void loadMetadata(ImportableItem.ContentAndMetadata contentAndMetadata, MetadataLoader.Metadata metadata)
MetadataLoader
loadMetadata
in interface MetadataLoader
contentAndMetadata
- The contentAndMetadata from which to obtain the metadata (will not be null).metadata
- The metadata object to populate (will not be null, and may already be partially populated).Copyright © 2005–2017 Alfresco Software. All rights reserved.