|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.solr.update.DocumentBuilder
public class DocumentBuilder
Constructor Summary | |
---|---|
DocumentBuilder(IndexSchema schema)
|
Method Summary | |
---|---|
void |
addField(SchemaField sfield,
String val,
float boost)
Add the specified SchemaField to the document. |
void |
addField(String name,
String val)
Add the Field and value to the document, invoking the copyField mechanism |
void |
addField(String name,
String val,
float boost)
Add the Field and value to the document with the specified boost, invoking the copyField mechanism |
protected void |
addSingleField(SchemaField sfield,
String val,
float boost)
|
void |
endDoc()
|
Document |
getDoc()
|
void |
startDoc()
|
static Document |
toDocument(SolrInputDocument doc,
IndexSchema schema)
Convert a SolrInputDocument to a lucene Document. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DocumentBuilder(IndexSchema schema)
Method Detail |
---|
public void startDoc()
protected void addSingleField(SchemaField sfield, String val, float boost)
public void addField(SchemaField sfield, String val, float boost)
SchemaField
to the document. Does not invoke the copyField mechanism.
sfield
- The SchemaField
to addval
- The value to addboost
- The boost factoraddField(String, String)
,
addField(String, String, float)
,
addSingleField(org.apache.solr.schema.SchemaField, String, float)
public void addField(String name, String val)
name
- The name of the fieldval
- The value to addaddField(String, String, float)
,
addField(org.apache.solr.schema.SchemaField, String, float)
,
addSingleField(org.apache.solr.schema.SchemaField, String, float)
public void addField(String name, String val, float boost)
name
- The name of the field.val
- The value to addboost
- The boostaddField(String, String)
,
addField(org.apache.solr.schema.SchemaField, String, float)
,
addSingleField(org.apache.solr.schema.SchemaField, String, float)
public void endDoc()
public Document getDoc() throws IllegalArgumentException
IllegalArgumentException
public static Document toDocument(SolrInputDocument doc, IndexSchema schema)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |