public class ResultDocument extends AbstractSdxObject implements org.apache.avalon.framework.logger.LogEnabled
SdxObject.ConfigurationNode
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CLASS_NAME_SUFFIX |
_configuration, _context, _description, _encoding, _id, _locale, _logger, _manager, _xmlizable_objects, _xmlLang, isToSaxInitialized
DEFAULT_ENCODING
Constructor and Description |
---|
ResultDocument()
Creates a ResultDocument object
A super.getLog() must be set and then this object must be setUp.
|
Modifier and Type | Method and Description |
---|---|
protected java.lang.String |
getClassNameSuffix()
Sub classes should element this method to return their class name suffix for SAX output
|
org.apache.lucene.document.Document |
getDocument()
Returns the Lucene document associated with this result.
|
java.lang.String |
getFieldValue(java.lang.String field)
Returns the value of a field within this document.
|
float |
getScore()
Returns the relavance ranking for this document.
|
protected boolean |
initToSax()
Init the LinkedHashMap _xmlizable_objects with the objects in order to describ them in XML
|
protected void |
initVolatileObjectsToSax()
Init the LinkedHashMap _xmlizable_volatile_objects with the objects in order to describ them in XML
Some objects need to be refresh each time a toSAX is called
|
void |
setUp(org.apache.lucene.document.Document doc,
float score)
Builds a ResultDocument with a Lucene document and a relavance ranking.
|
configure, configureDescription, contextualize, enableLogging, getBaseAttributes, getConfiguration, getContext, getDescription, getEncoding, getId, getLocale, getLog, getServiceManager, getXmlLang, service, setDescription, setEncoding, setId, setLocale, setUpSdxObject, setUpSdxObject, setXmlLang, toSAX, verifyConfigurationResources
public static final java.lang.String CLASS_NAME_SUFFIX
public ResultDocument()
A super.getLog() must be set and then this object must be setUp.
public void setUp(org.apache.lucene.document.Document doc, float score) throws SDXException
doc
- The Lucene documentscore
- The relavance rankingSDXException
public java.lang.String getFieldValue(java.lang.String field)
null
,
it will turn over a null
String
if the field does not exist.field
- The name of the field.public float getScore()
public org.apache.lucene.document.Document getDocument()
protected java.lang.String getClassNameSuffix()
AbstractSdxObject
getClassNameSuffix
in class AbstractSdxObject
protected boolean initToSax()
AbstractSdxObject
initToSax
in class AbstractSdxObject
protected void initVolatileObjectsToSax()
initVolatileObjectsToSax
in class AbstractSdxObject
Copyright © 2000-2010 Ministere de la culture et de la communication / AJLSM. All Rights Reserved.