|
DLESE Tools v1.6.0 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.dlese.dpc.index.writer.FileIndexingServiceWriter
org.dlese.dpc.index.writer.XMLFileIndexingWriter
org.dlese.dpc.index.writer.ItemFileIndexingWriter
org.dlese.dpc.index.writer.ADNFileIndexingWriter
public class ADNFileIndexingWriter
Creates a Lucene Document from an ADN-item metadata source file.
The Lucene Document fields that are created by this class are (in
addition the the ones listed for FileIndexingServiceWriter):
doctype - Set to 'adn'. Stored. Note: the actual indexing of this field happens in
the superclass FileIndexingServiceWriter.
additional fields - A number of additional fields are defined. See the Java code for
method addFrameworkFields(Document, Document) for details.
| Constructor Summary | |
|---|---|
ADNFileIndexingWriter()
Create a ADNFileIndexingWriter that indexes the given collection in field collection. |
|
ADNFileIndexingWriter(boolean isDupDoc)
Create a ADNFileIndexingWriter that indexes the given collection in field collection. |
|
| Method Summary | |
|---|---|
protected String[] |
_getIds()
Gets the id(s) for this item. |
protected void |
addFrameworkFields(org.apache.lucene.document.Document newDoc,
org.apache.lucene.document.Document existingDoc)
Adds custom fields to the index that are unique to this framework. |
protected void |
destroy()
Release map resources for GC after processing. |
protected void |
finalize()
Perform finalization... |
protected Date |
getAccessionDate()
Returns the accession date for the item, or null if this item is not accessioned. |
protected String |
getAccessionStatus()
Returns the accession status of this record, for example 'accessioned'. |
protected MmdRec[] |
getAllMmdRecs()
Returns the MmdRecs for all records that catalog this resouce, including myMmdRec. |
protected MmdRec[] |
getAssociatedMmdRecs()
Returns the MmdRecs for records in other collections that catalog the same resource, not including myMmdRec. |
protected String |
getAudienceBeneficiary()
The audience beneficiary. |
protected String |
getAudienceInstructionalGoal()
The audience instructionalGoal. |
protected String |
getAudienceTeachingMethod()
The audience teachingMethod. |
protected String |
getAudienceToolFor()
The audience tool for. |
protected String |
getAudienceTypicalAgeRange()
The audience typical age range. |
protected BoundingBox |
getBoundingBox()
Gets the boundingBox attribute of the ADNFileIndexingWriter object |
String[] |
getCollections()
Returns unique collection keys for the item being indexed, separated by spaces. |
protected String |
getContent()
Returns the content of the item this record catalogs, or null if not available. |
protected String[] |
getContentStandards()
Gets the contentStandards attribute of the ADNFileIndexingWriter object |
protected String |
getContentType()
Returns the content type of the item this record catalogs, or null if not available. |
protected String |
getCost()
Returns the item's cost. |
protected Date |
getCreationDate()
Returns the date this item was first created, or null if not available. |
protected String |
getCreator()
Returns the items creator's full name. |
protected String |
getCreatorEmailAlt()
Gets the creator's alternate email. |
protected String |
getCreatorEmailPrimary()
Gets the creator's primary email. |
protected String |
getCreatorLastName()
Returns the items creator's last name. |
String |
getDescription()
Gets the description attribute of the ADNFileIndexingWriter object |
String |
getDocType()
Gets the docType attribute of the ADNFileIndexingWriter, which is 'adn.' |
protected String |
getEventNames()
Gets all event names as text. |
protected String[] |
getGradeRange()
Gets the gradeRange attribute of the ADNFileIndexingWriter object |
protected boolean |
getHasRelatedResource()
Returns true if the item has one or more related resource, false otherwise. |
protected String |
getKeywords()
Returns the item's keywords sorted and separated by the '+' symbol. |
protected MmdRec |
getMyMmdRec()
Returns the MmdRec for this record only. |
static long |
getNumInstances()
Gets the numInstances attribute of the ADNFileIndexingWriter class |
protected String |
getOrganizationEmail()
Gets the oraganization email. |
protected String |
getOrganizationInstDepartment()
Gets the oraganizations institution department name. |
protected String |
getOrganizationInstName()
Gets the oraganizations institution name. |
protected String |
getPersonInstDepartment()
Gets the persons institution department name. |
protected String |
getPersonInstName()
Gets the persons institution name. |
protected String |
getPlaceNames()
Gets all place names as text. |
String |
getReaderClass()
Gets the name of the concrete DocReader class that is used to read
this type of Document, which is "ItemDocReader". |
protected String[] |
getRelatedResourceIds()
Returns the IDs of related resources that are cataloged by ID, or null if none are present |
protected String[] |
getRelatedResourceUrls()
Returns the URLs of related resources that are cataloged by URL, or null if none are present |
protected String[] |
getResourceTypes()
Gets the resourceTypes attribute of the ADNFileIndexingWriter object |
protected String[] |
getSubjects()
Gets the subjects attribute of the ADNFileIndexingWriter object |
protected String |
getTemporalCoverageNames()
Gets all temporal coverage names as text. |
String |
getTitle()
Gets the title attribute of the ADNFileIndexingWriter object |
protected String |
getUrlMirrors()
Gets the mirror URLs encoded as terms, if any. |
String[] |
getUrls()
Gets the url(s) from the ADN record(s). |
protected String |
getValidationReport()
Gets a report detailing any errors found in the validation of the data, or null if no error was found. |
boolean |
indexFullContentInDefaultAndStems()
Default and stems fields handled here, so do not index full content. |
void |
initItem(File source,
org.apache.lucene.document.Document existingDoc)
Initialize the XML map, MmdRecs and other data prior to processing |
void |
setIsSingleDoc(boolean isSingleDoc)
Sets the whether this writer should write a single record doc rather than a multi-item doc. |
| Methods inherited from class org.dlese.dpc.index.writer.ItemFileIndexingWriter |
|---|
addFields, getMyAnnoResultDocs, getWhatsNewDate, getWhatsNewType, init |
| Methods inherited from class org.dlese.dpc.index.writer.XMLFileIndexingWriter |
|---|
addCustomFields, getDeletedDoc, getDocGroup, getDom4jDoc, getFieldContent, getFieldContent, getFieldName, getIds, getIndex, getMyCollectionDoc, getOaiModtime, getPrimaryId, getRecordDataService, getRelatedIds, getRelatedIdsMap, getRelatedUrls, getRelatedUrlsMap, getTermStringFromStringArray, getXmlIndexer, getXmlIndexerFieldsConfig |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ADNFileIndexingWriter()
public ADNFileIndexingWriter(boolean isDupDoc)
isDupDoc - False to force this to be processed as a non-dup| Method Detail |
|---|
protected void finalize()
throws Throwable
finalize in class ObjectThrowable - If errorpublic static long getNumInstances()
public void initItem(File source,
org.apache.lucene.document.Document existingDoc)
throws Exception
initItem in class ItemFileIndexingWritersource - The source file being indexed.existingDoc - A Document that previously existed in the index for this item, if present
Exception - Thrown if error reading the XML mapprotected void destroy()
destroy in class ItemFileIndexingWriter
public String[] getCollections()
throws Exception
getCollections in class XMLFileIndexingWriterException - If error
protected String getAccessionStatus()
throws Exception
getAccessionStatus in class ItemFileIndexingWriterException - This method should throw and Exception with appropriate error message if an error
occurs.
protected boolean getHasRelatedResource()
throws Exception
getHasRelatedResource in class ItemFileIndexingWriterException - This method should throw and Exception with appropriate error message if an error
occurs.
protected String[] getRelatedResourceIds()
throws Exception
getRelatedResourceIds in class ItemFileIndexingWriterException - This method should throw and Exception with appropriate error message if an error
occurs.
protected String[] getRelatedResourceUrls()
throws Exception
getRelatedResourceUrls in class ItemFileIndexingWriterException - This method should throw and Exception with appropriate error message if an error
occurs.
protected Date getAccessionDate()
throws Exception
getAccessionDate in class ItemFileIndexingWriterException - This method should throw and Exception with appropriate error message if an error
occurs.
protected Date getCreationDate()
throws Exception
getCreationDate in class ItemFileIndexingWriterException - This method should throw and Exception with appropriate error message if an error
occurs.public String getReaderClass()
DocReader class that is used to read
this type of Document, which is "ItemDocReader".
getReaderClass in interface DocWritergetReaderClass in class ItemFileIndexingWriterpublic boolean indexFullContentInDefaultAndStems()
indexFullContentInDefaultAndStems in class XMLFileIndexingWriterprotected MmdRec[] getAssociatedMmdRecs()
getAssociatedMmdRecs in class ItemFileIndexingWriterprotected MmdRec[] getAllMmdRecs()
getAllMmdRecs in class ItemFileIndexingWriterprotected MmdRec getMyMmdRec()
getMyMmdRec in class ItemFileIndexingWriter
protected String getValidationReport()
throws Exception
getValidationReport in class ItemFileIndexingWriterException - If error in performing the validation.public final String getDocType()
getDocType in interface DocWritergetDocType in class ItemFileIndexingWriter
protected String[] _getIds()
throws Exception
_getIds in class XMLFileIndexingWriterException - If an error occurs
public final String getTitle()
throws Exception
getTitle in class XMLFileIndexingWriterException - If an error occurs
public final String getDescription()
throws Exception
getDescription in class XMLFileIndexingWriterException - If an error occurs
public final String[] getUrls()
throws Exception
getUrls in class XMLFileIndexingWriterException - If an error occurs
protected String getKeywords()
throws Exception
getKeywords in class ItemFileIndexingWriterException - This method should throw and Exception with appropriate error message if an error
occurs.
protected String getCreatorLastName()
throws Exception
getCreatorLastName in class ItemFileIndexingWriterException - This method should throw and Exception with appropriate error message if an error
occurs.
protected String getCreator()
throws Exception
getCreator in class ItemFileIndexingWriterException - This method should throw and Exception with appropriate error message if an error
occurs.
protected String getCost()
throws Exception
Exception - This method should throw and Exception with appropriate error message if an error
occurs.
protected BoundingBox getBoundingBox()
throws Exception
getBoundingBox in class XMLFileIndexingWriterException - This method should throw and Exception with appropriate error message if an error
occurs.protected String getContent()
getContent in class ItemFileIndexingWriterprotected String getContentType()
getContentType in class ItemFileIndexingWriter
protected final void addFrameworkFields(org.apache.lucene.document.Document newDoc,
org.apache.lucene.document.Document existingDoc)
throws Exception
addFrameworkFields in class ItemFileIndexingWriternewDoc - The feature to be added to the FrameworkFields attributeexistingDoc - The feature to be added to the FrameworkFields attribute
Exception - If an error occurspublic void setIsSingleDoc(boolean isSingleDoc)
isSingleDoc - The new isSingleDoc valueprotected String[] getGradeRange()
protected String[] getResourceTypes()
protected String[] getContentStandards()
protected String[] getSubjects()
protected String getCreatorEmailPrimary()
throws Exception
Exception - This method should throw and Exception with appropriate error message if an error
occurs.
protected String getCreatorEmailAlt()
throws Exception
Exception - This method should throw and Exception with appropriate error message if an error
occurs.
protected String getOrganizationEmail()
throws Exception
Exception - This method should throw and Exception with appropriate error message if an error
occurs.
protected String getOrganizationInstName()
throws Exception
Exception - This method should throw and Exception with appropriate error message if an error
occurs.
protected String getOrganizationInstDepartment()
throws Exception
Exception - This method should throw and Exception with appropriate error message if an error
occurs.
protected String getPersonInstName()
throws Exception
Exception - This method should throw and Exception with appropriate error message if an error
occurs.
protected String getPersonInstDepartment()
throws Exception
Exception - This method should throw and Exception with appropriate error message if an error
occurs.
protected String getUrlMirrors()
throws Exception
Exception - This method should throw and Exception with appropriate error message if an error
occurs.
protected String getAudienceToolFor()
throws Exception
Exception - This method should throw and Exception with appropriate error message if an error
occurs.
protected String getAudienceBeneficiary()
throws Exception
Exception - This method should throw and Exception with appropriate error message if an error
occurs.
protected String getAudienceTypicalAgeRange()
throws Exception
Exception - This method should throw and Exception with appropriate error message if an error
occurs.
protected String getAudienceInstructionalGoal()
throws Exception
Exception - This method should throw and Exception with appropriate error message if an error
occurs.
protected String getAudienceTeachingMethod()
throws Exception
Exception - This method should throw and Exception with appropriate error message if an error
occurs.protected String getPlaceNames()
protected String getEventNames()
protected String getTemporalCoverageNames()
|
DLESE Tools v1.6.0 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||