org.apache.solr.update
Class AddUpdateCommand

java.lang.Object
  extended by org.apache.solr.update.UpdateCommand
      extended by org.apache.solr.update.AddUpdateCommand
All Implemented Interfaces:
Cloneable

public class AddUpdateCommand
extends UpdateCommand


Field Summary
 int commitWithin
           
 boolean overwrite
           
 SolrInputDocument solrDoc
           
 Term updateTerm
           
 
Fields inherited from class org.apache.solr.update.UpdateCommand
BUFFERING, CLEAR_CACHES, flags, IGNORE_AUTOCOMMIT, PEER_SYNC, REPLAY, req, version
 
Constructor Summary
AddUpdateCommand(SolrQueryRequest req)
           
 
Method Summary
 void clear()
          Reset state to reuse this object with a different document in the same request
 String getHashableId()
           
 BytesRef getIndexedId()
          Returns the indexed ID for this document.
 Document getLuceneDocument()
          Creates and returns a lucene Document to index.
 String getPrintableId()
           
 SolrInputDocument getSolrInputDocument()
           
 String name()
           
 void setIndexedId(BytesRef indexedId)
           
 String toString()
           
 
Methods inherited from class org.apache.solr.update.UpdateCommand
clone, getFlags, getReq, getVersion, setFlags, setReq, setVersion
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

solrDoc

public SolrInputDocument solrDoc

overwrite

public boolean overwrite

updateTerm

public Term updateTerm

commitWithin

public int commitWithin
Constructor Detail

AddUpdateCommand

public AddUpdateCommand(SolrQueryRequest req)
Method Detail

name

public String name()
Specified by:
name in class UpdateCommand

clear

public void clear()
Reset state to reuse this object with a different document in the same request


getSolrInputDocument

public SolrInputDocument getSolrInputDocument()

getLuceneDocument

public Document getLuceneDocument()
Creates and returns a lucene Document to index. Any changes made to the returned Document will not be reflected in the SolrInputDocument, or future calls to this method.


getIndexedId

public BytesRef getIndexedId()
Returns the indexed ID for this document. The returned BytesRef is retained across multiple calls, and should not be modified.


setIndexedId

public void setIndexedId(BytesRef indexedId)

getPrintableId

public String getPrintableId()

getHashableId

public String getHashableId()
Returns:
String id to hash

toString

public String toString()
Overrides:
toString in class UpdateCommand


Copyright © 2000-2013 Apache Software Foundation. All Rights Reserved.