|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.droids.handle.Solr
public class Solr
Handler specialized for the communication with Apache Solr. Offers methods to
generate the different commands for solr as e.g.
createUpdateDocument(URL url, Parse parse)
}
Make sure you have set the update url of your local solr server instance you want to use as destination.
Constructor Summary | |
---|---|
Solr()
|
Method Summary | |
---|---|
ByteArrayOutputStream |
createCommitDocument()
Creates a commit command. |
ByteArrayOutputStream |
createOptimizeDocument()
Creates a optimize command. |
ByteArrayOutputStream |
createUpdateDocument(URL url,
Parse parse)
Creates an add command (and returns it as OutputStream) out of the parse result. |
String |
getUpdateUrl()
Get the update url of the Apache Solr server in use |
void |
handle(InputStream openStream,
URL url,
Parse parse)
|
void |
setUpdateUrl(String updateUrl)
Set the update url of the Apache Solr server in use |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Solr()
Method Detail |
---|
public void handle(InputStream openStream, URL url, Parse parse) throws Exception
handle
in interface Handler
openStream
- the underlying streamurl
- the url we are currently processingparse
- the parse object from a former processing step
Exception
public ByteArrayOutputStream createUpdateDocument(URL url, Parse parse) throws javax.xml.stream.XMLStreamException
Parse
url
- the identifier for the document in Apache Solrparse
- the object that contains the textual representation of the
document
javax.xml.stream.XMLStreamException
public ByteArrayOutputStream createCommitDocument() throws javax.xml.stream.XMLStreamException
javax.xml.stream.XMLStreamException
public ByteArrayOutputStream createOptimizeDocument() throws javax.xml.stream.XMLStreamException
javax.xml.stream.XMLStreamException
public String getUpdateUrl()
public void setUpdateUrl(String updateUrl)
updateUrl
- the update url of the Apache Solr server in use
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |