|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.ow2.weblab.service.normaliser.tika.metadatawriter.MappingDescription
public class MappingDescription
This class aims to provide a mapping between a Tika metadata and an
annotation represented by an URI. Currently only Date and URI are used,
others are mapped as text properties. See
Property.ValueType for
more info.
PoKHelper,
Metadata,
URI,
Property| Field Summary | |
|---|---|
protected org.apache.commons.logging.Log |
logger
The logger to be used inside this class. |
| Constructor Summary | |
|---|---|
MappingDescription(Property property,
java.net.URI uri)
Constructor that take a XMP Property as argument and the
URI that should map it. |
|
| Method Summary | |
|---|---|
protected java.net.URI |
getAnnotation_URI()
Protected getter for destination URI |
protected Property |
getPropertyLinked()
Protected getter for property to map |
void |
write(Metadata metadataToWrite,
PoKHelper pokHelperToWriteInto,
java.net.URI documentUri)
This method is a delegate for MetadataWriter.write(Metadata, PoKHelper, URI). |
protected void |
writeDate(Metadata metadataToWrite,
PoKHelper pokHelperToWriteInto,
java.net.URI documentUri)
This method defines how to write a Date metadata. |
protected void |
writeText(Metadata metadataToWrite,
PoKHelper pokHelperToWriteInto,
java.net.URI documentUri)
This method defines how to write a Text metadata. |
protected void |
writeURI(Metadata metadataToWrite,
PoKHelper pokHelperToWriteInto,
java.net.URI documentUri)
This method defines how to write an URI metadata. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final org.apache.commons.logging.Log logger
| Constructor Detail |
|---|
public MappingDescription(Property property,
java.net.URI uri)
XMP Property as argument and the
URI that should map it. For Tika metadata not represented
with a Property object, it should be represented as Text property
property - the Tika property to mapuri - The URI representing the mapping| Method Detail |
|---|
public void write(Metadata metadataToWrite,
PoKHelper pokHelperToWriteInto,
java.net.URI documentUri)
metadataToWrite - Metadata set to writepokHelperToWriteInto - PokHelper to write intodocumentUri - The document URI that will be used for reference
protected void writeText(Metadata metadataToWrite,
PoKHelper pokHelperToWriteInto,
java.net.URI documentUri)
write and simply writes the text
as is. It should only be overridden in subclasses that needs to modify or
add some text value to the property.
metadataToWrite - Metadata set to writepokHelperToWriteInto - PokHelper to write intodocumentUri - The document URI that will be used for reference
protected void writeURI(Metadata metadataToWrite,
PoKHelper pokHelperToWriteInto,
java.net.URI documentUri)
write and writes the URI using
createResStat of
PokHelper. It should only be overridden in subclasses that needs to
modify the URI of the property.
metadataToWrite - Metadata set to writepokHelperToWriteInto - PokHelper to write intodocumentUri - The document URI that will be used for reference
protected void writeDate(Metadata metadataToWrite,
PoKHelper pokHelperToWriteInto,
java.net.URI documentUri)
write and writes the Date using
Joda Time. It should only be overridden in subclasses that needs to
modify, for example, the Date format of the property.
metadataToWrite - Metadata set to writepokHelperToWriteInto - PokHelper to write intodocumentUri - The document URI that will be used for referenceprotected java.net.URI getAnnotation_URI()
protected Property getPropertyLinked()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||