org.basex.data
Interface Result

All Known Implementing Classes:
Nodes, ValueBuilder

public interface Result

This is an interface for query results.

Author:
BaseX Team 2005-12, BSD License, Christian Gruen

Method Summary
 boolean sameAs(Result r)
          Compares results for equality.
 ArrayOutput serialize()
          Serializes the result, using the standard serializer, and returns the cached result.
 void serialize(Serializer ser)
          Serializes the complete result.
 void serialize(Serializer ser, int n)
          Serializes the specified result.
 long size()
          Number of values, stored in the result instance.
 

Method Detail

size

long size()
Number of values, stored in the result instance.

Returns:
number of values

sameAs

boolean sameAs(Result r)
Compares results for equality.

Parameters:
r - result to be compared
Returns:
true if results are equal

serialize

ArrayOutput serialize()
                      throws java.io.IOException
Serializes the result, using the standard serializer, and returns the cached result.

Returns:
serialized value
Throws:
java.io.IOException - I/O exception

serialize

void serialize(Serializer ser)
               throws java.io.IOException
Serializes the complete result.

Parameters:
ser - serializer
Throws:
java.io.IOException - I/O exception

serialize

void serialize(Serializer ser,
               int n)
               throws java.io.IOException
Serializes the specified result.

Parameters:
ser - serializer
n - offset of result to serialize
Throws:
java.io.IOException - I/O exception