Package oracle.pgx.api
Interface PgqlResultSet
-
- All Superinterfaces:
java.lang.AutoCloseable
,oracle.pgx.common.IdentifiableResultSet
,java.lang.Iterable<PgxResult>
,oracle.pgql.lang.ResultAccess
,oracle.pgql.lang.ResultSet<PgxResult>
,oracle.pgql.lang.spatial.STResultAccess
public interface PgqlResultSet extends oracle.pgql.lang.ResultSet<PgxResult>, oracle.pgql.lang.spatial.STResultAccess, oracle.pgx.common.IdentifiableResultSet
Result set of a pattern matching query. Note: retrieving results from the server is not thread-safe
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description void
close()
PgxEdge
getEdge(int elementIdx)
Gets the value of the designated element by element index as aPgxEdge
PgxEdge
getEdge(java.lang.String elementName)
Gets the value of the designated element by element name as aPgxEdge
PgxGraph
getGraph()
Gets the graph of this result set.java.lang.String
getId()
Gets the ID of this result set.long
getNumResults()
Gets the number of resultsjava.util.List<? extends PgqlResultElement>
getPgqlResultElements()
Gets the list of PGQL result elements information<ID extends java.lang.Comparable<ID>>
PgxVertex<ID>getVertex(int elementIdx)
Gets the value of the designated element by element index as aPgxVertex
<ID extends java.lang.Comparable<ID>>
PgxVertex<ID>getVertex(java.lang.String elementName)
Gets the value of the designated element by element name as aPgxVertex
PgqlResultSet
print()
Prints all results toSystem.out
.default PgqlResultSet
print(long numResults)
PrintsnumResults
results toSystem.out
.default PgqlResultSet
print(long numResults, int from)
PrintsnumResults
results fromfrom
th result toSystem.out
.PgqlResultSet
print(java.io.PrintStream printStream, long numResults, int from)
Same asprint(long, int)
except that this method prints content toprintStream
.default PgxFrame
toFrame()
Copies the content of this result set into a new PgxFrame.default PgxFuture<PgxFrame>
toFrameAsync()
Copies the content of this result set into a new PgxFrame.-
Methods inherited from interface oracle.pgql.lang.ResultAccess
getBoolean, getBoolean, getDate, getDate, getDouble, getDouble, getFloat, getFloat, getInteger, getInteger, getLegacyDate, getLegacyDate, getList, getList, getLong, getLong, getObject, getObject, getString, getString, getTime, getTime, getTimestamp, getTimestamp, getTimestampWithTimezone, getTimestampWithTimezone, getTimeWithTimezone, getTimeWithTimezone, getVertexLabels, getVertexLabels
-
-
-
-
Method Detail
-
getVertex
<ID extends java.lang.Comparable<ID>> PgxVertex<ID> getVertex(int elementIdx) throws oracle.pgql.lang.PgqlException
Gets the value of the designated element by element index as aPgxVertex
- Parameters:
elementIdx
- element index- Returns:
PgxVertex
- Throws:
oracle.pgql.lang.PgqlException
-
getVertex
<ID extends java.lang.Comparable<ID>> PgxVertex<ID> getVertex(java.lang.String elementName) throws oracle.pgql.lang.PgqlException
Gets the value of the designated element by element name as aPgxVertex
- Parameters:
elementName
- element name- Returns:
PgxVertex
- Throws:
oracle.pgql.lang.PgqlException
-
getEdge
PgxEdge getEdge(int elementIdx) throws oracle.pgql.lang.PgqlException
Gets the value of the designated element by element index as aPgxEdge
- Parameters:
elementIdx
- element index- Returns:
PgxEdge
- Throws:
oracle.pgql.lang.PgqlException
-
getEdge
PgxEdge getEdge(java.lang.String elementName) throws oracle.pgql.lang.PgqlException
Gets the value of the designated element by element name as aPgxEdge
- Parameters:
elementName
- element name- Returns:
PgxEdge
- Throws:
oracle.pgql.lang.PgqlException
-
getId
java.lang.String getId()
Gets the ID of this result set.- Specified by:
getId
in interfaceoracle.pgx.common.IdentifiableResultSet
- Returns:
- the ID
-
getGraph
PgxGraph getGraph()
Gets the graph of this result set.- Returns:
- the graph.
-
getPgqlResultElements
java.util.List<? extends PgqlResultElement> getPgqlResultElements()
Gets the list of PGQL result elements information- Returns:
- result element information
-
getNumResults
long getNumResults()
Gets the number of results- Returns:
- number of results
-
print
PgqlResultSet print()
Prints all results toSystem.out
.- Returns:
PgqlResultSet
-
print
default PgqlResultSet print(long numResults)
PrintsnumResults
results toSystem.out
. IfnumResults
is larger thangetNumResults()
, onlygetNumResults()
results are printed.- Parameters:
numResults
- number of result- Returns:
PgqlResultSet
-
print
default PgqlResultSet print(long numResults, int from)
PrintsnumResults
results fromfrom
th result toSystem.out
.- Parameters:
numResults
- number of resultfrom
- first result to be printed (start counting from 0)- Returns:
PgqlResultSet
-
print
PgqlResultSet print(java.io.PrintStream printStream, long numResults, int from)
Same asprint(long, int)
except that this method prints content toprintStream
.- Parameters:
printStream
- stream to which results are printednumResults
- number of resultsfrom
- first result to be printed (start counting from 0)- Returns:
PgqlResultSet
-
toFrameAsync
default PgxFuture<PgxFrame> toFrameAsync()
Copies the content of this result set into a new PgxFrame.- Returns:
- a new PgxFrame containing the content of the result set
-
toFrame
default PgxFrame toFrame() throws java.lang.InterruptedException, java.util.concurrent.ExecutionException
Copies the content of this result set into a new PgxFrame.- Returns:
- a new PgxFrame containing the content of the result set
- Throws:
java.lang.InterruptedException
java.util.concurrent.ExecutionException
-
close
void close()
- Specified by:
close
in interfacejava.lang.AutoCloseable
- Specified by:
close
in interfaceoracle.pgql.lang.ResultSet<PgxResult>
-
-