|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.basex.data.Serializer
public abstract class Serializer
This is an interface for serializing different kinds of query results.
Field Summary | |
---|---|
byte[] |
dn
Current default namespace. |
Atts |
ns
Namespaces. |
Constructor Summary | |
---|---|
Serializer()
|
Method Summary | |
---|---|
abstract void |
attribute(byte[] n,
byte[] v)
Serializes an attribute. |
void |
close()
Closes the serializer. |
void |
closeElement()
Closes an element. |
abstract void |
closeResult()
Closes a result. |
abstract void |
comment(byte[] b)
Serializes a comment. |
void |
emptyElement(byte[] t,
byte[]... a)
Opens and closes an empty element. |
void |
emptyElement(Expr expr,
byte[]... a)
Opens and closes an empty element. |
boolean |
finished()
Tests if the serialization was interrupted. |
abstract void |
item(byte[] b)
Serializes an item. |
int |
level()
Returns the current level. |
void |
namespace(byte[] n,
byte[] v)
Serializes a namespace. |
int |
node(Data data,
int pre)
Serializes a node of the specified data reference. |
int |
node(Data data,
int pre,
FTPosData ft)
Serializes a node of the specified data reference. |
void |
openElement(byte[] t,
byte[]... a)
Opens an element. |
void |
openElement(ExprInfo expr,
byte[]... a)
Opens an element. |
abstract void |
openResult()
Starts a result. |
abstract void |
pi(byte[] n,
byte[] v)
Serializes a processing instruction. |
abstract void |
text(byte[] b)
Serializes a text. |
abstract void |
text(byte[] b,
FTPos ftp)
Serializes a text. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public final Atts ns
public byte[] dn
Constructor Detail |
---|
public Serializer()
Method Detail |
---|
public abstract void openResult() throws IOException
IOException
- I/O exceptionpublic abstract void closeResult() throws IOException
IOException
- I/O exceptionpublic abstract void attribute(byte[] n, byte[] v) throws IOException
n
- namev
- value
IOException
- I/O exceptionpublic abstract void text(byte[] b) throws IOException
b
- text bytes
IOException
- I/O exceptionpublic abstract void text(byte[] b, FTPos ftp) throws IOException
b
- text bytesftp
- full-text positions
IOException
- I/O exceptionpublic abstract void comment(byte[] b) throws IOException
b
- comment
IOException
- I/O exceptionpublic abstract void pi(byte[] n, byte[] v) throws IOException
n
- namev
- value
IOException
- I/O exceptionpublic abstract void item(byte[] b) throws IOException
b
- text bytes
IOException
- I/O exceptionpublic final void openElement(ExprInfo expr, byte[]... a) throws IOException
expr
- expression infoa
- attributes
IOException
- I/O exceptionpublic final void openElement(byte[] t, byte[]... a) throws IOException
t
- taga
- attributes
IOException
- I/O exceptionpublic final void namespace(byte[] n, byte[] v) throws IOException
n
- namev
- value
IOException
- I/O exceptionpublic final void emptyElement(byte[] t, byte[]... a) throws IOException
t
- taga
- attributes
IOException
- I/O exceptionpublic final void emptyElement(Expr expr, byte[]... a) throws IOException
expr
- expression infoa
- attributes
IOException
- I/O exceptionpublic final void closeElement() throws IOException
IOException
- I/O exceptionpublic final void close() throws IOException
IOException
- I/O exceptionpublic boolean finished()
public final int level()
public final int node(Data data, int pre) throws IOException
data
- data referencepre
- pre value to start from
IOException
- I/O exceptionpublic final int node(Data data, int pre, FTPosData ft) throws IOException
data
- data referencepre
- pre value to start fromft
- full-text data
IOException
- I/O exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |