|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.solr.response.TextResponseWriter
public abstract class TextResponseWriter
Base class for text-oriented response writers.
Field Summary | |
---|---|
protected Calendar |
cal
|
protected boolean |
doIndent
|
protected int |
level
|
protected SolrQueryRequest |
req
|
protected ReturnFields |
returnFields
|
protected SolrQueryResponse |
rsp
|
protected IndexSchema |
schema
|
protected FastWriter |
writer
|
Constructor Summary | |
---|---|
TextResponseWriter(Writer writer,
SolrQueryRequest req,
SolrQueryResponse rsp)
|
Method Summary | |
---|---|
void |
close()
done with this ResponseWriter... |
int |
decLevel()
|
Writer |
getWriter()
returns the Writer that the response is being written to |
int |
incLevel()
|
void |
indent()
|
void |
indent(int lev)
|
int |
level()
|
void |
setIndent(boolean doIndent)
|
void |
setLevel(int level)
|
SolrDocument |
toSolrDocument(Document doc)
|
abstract void |
writeArray(String name,
Iterator val)
|
void |
writeArray(String name,
Object[] val)
|
void |
writeBool(String name,
boolean val)
|
abstract void |
writeBool(String name,
String val)
if this form of the method is called, val is the Java string form of a boolean |
void |
writeByteArr(String name,
byte[] buf,
int offset,
int len)
|
void |
writeDate(String name,
Date val)
|
abstract void |
writeDate(String name,
String val)
if this form of the method is called, val is the Solr ISO8601 based date format |
void |
writeDocuments(String name,
ResultContext res,
ReturnFields fields)
|
void |
writeDouble(String name,
double val)
|
abstract void |
writeDouble(String name,
String val)
if this form of the method is called, val is the Java string form of a double |
abstract void |
writeEndDocumentList()
|
void |
writeFloat(String name,
float val)
|
abstract void |
writeFloat(String name,
String val)
if this form of the method is called, val is the Java string form of a float |
void |
writeInt(String name,
int val)
|
abstract void |
writeInt(String name,
String val)
if this form of the method is called, val is the Java string form of an int |
void |
writeLong(String name,
long val)
|
abstract void |
writeLong(String name,
String val)
if this form of the method is called, val is the Java string form of a long |
abstract void |
writeMap(String name,
Map val,
boolean excludeOuter,
boolean isFirstVal)
|
abstract void |
writeNamedList(String name,
NamedList val)
|
abstract void |
writeNull(String name)
|
abstract void |
writeSolrDocument(String name,
SolrDocument doc,
ReturnFields returnFields,
int idx)
|
void |
writeSolrDocumentList(String name,
SolrDocumentList docs,
ReturnFields returnFields)
|
abstract void |
writeStartDocumentList(String name,
long start,
int size,
long numFound,
Float maxScore)
|
abstract void |
writeStr(String name,
String val,
boolean needsEscaping)
|
void |
writeVal(String name,
Object val)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final FastWriter writer
protected final IndexSchema schema
protected final SolrQueryRequest req
protected final SolrQueryResponse rsp
protected ReturnFields returnFields
protected int level
protected boolean doIndent
protected Calendar cal
Constructor Detail |
---|
public TextResponseWriter(Writer writer, SolrQueryRequest req, SolrQueryResponse rsp)
Method Detail |
---|
public void close() throws IOException
IOException
public Writer getWriter()
public void indent() throws IOException
IOException
public void indent(int lev) throws IOException
IOException
public void setLevel(int level)
public int level()
public int incLevel()
public int decLevel()
public void setIndent(boolean doIndent)
public abstract void writeNamedList(String name, NamedList val) throws IOException
IOException
public final void writeVal(String name, Object val) throws IOException
IOException
public abstract void writeStartDocumentList(String name, long start, int size, long numFound, Float maxScore) throws IOException
IOException
public abstract void writeSolrDocument(String name, SolrDocument doc, ReturnFields returnFields, int idx) throws IOException
IOException
public abstract void writeEndDocumentList() throws IOException
IOException
public final void writeSolrDocumentList(String name, SolrDocumentList docs, ReturnFields returnFields) throws IOException
IOException
public final SolrDocument toSolrDocument(Document doc)
public final void writeDocuments(String name, ResultContext res, ReturnFields fields) throws IOException
IOException
public abstract void writeStr(String name, String val, boolean needsEscaping) throws IOException
IOException
public abstract void writeMap(String name, Map val, boolean excludeOuter, boolean isFirstVal) throws IOException
IOException
public void writeArray(String name, Object[] val) throws IOException
IOException
public abstract void writeArray(String name, Iterator val) throws IOException
IOException
public abstract void writeNull(String name) throws IOException
IOException
public abstract void writeInt(String name, String val) throws IOException
IOException
public void writeInt(String name, int val) throws IOException
IOException
public abstract void writeLong(String name, String val) throws IOException
IOException
public void writeLong(String name, long val) throws IOException
IOException
public abstract void writeBool(String name, String val) throws IOException
IOException
public void writeBool(String name, boolean val) throws IOException
IOException
public abstract void writeFloat(String name, String val) throws IOException
IOException
public void writeFloat(String name, float val) throws IOException
IOException
public abstract void writeDouble(String name, String val) throws IOException
IOException
public void writeDouble(String name, double val) throws IOException
IOException
public void writeDate(String name, Date val) throws IOException
IOException
public abstract void writeDate(String name, String val) throws IOException
IOException
public void writeByteArr(String name, byte[] buf, int offset, int len) throws IOException
IOException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |