Package org.postgresql.jdbc
Class ResultWrapper
- java.lang.Object
-
- org.postgresql.jdbc.ResultWrapper
-
public class ResultWrapper extends java.lang.ObjectHelper class that storing result info. This handles both the ResultSet and no-ResultSet result cases with a single interface for inspecting and stepping through them.- Author:
- Oliver Jowett (oliver@opencloud.com)
-
-
Constructor Summary
Constructors Constructor Description ResultWrapper(long updateCount, long insertOID, SqlCommandType commandType)ResultWrapper(java.sql.ResultSet rs, SqlCommandType commandType)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ResultWrapperappend(ResultWrapper newResult)Append a result to its internal chain of results.longgetInsertOID()ResultWrappergetNext()java.sql.ResultSetgetResultSet()longgetUpdateCount()
-
-
-
Constructor Detail
-
ResultWrapper
public ResultWrapper(java.sql.ResultSet rs, SqlCommandType commandType)
-
ResultWrapper
public ResultWrapper(long updateCount, long insertOID, SqlCommandType commandType)
-
-
Method Detail
-
getResultSet
public java.sql.ResultSet getResultSet()
-
getUpdateCount
public long getUpdateCount()
-
getInsertOID
public long getInsertOID()
-
getNext
public ResultWrapper getNext()
-
append
public ResultWrapper append(ResultWrapper newResult)
Append a result to its internal chain of results. It has a special behavior forSETcommands asSETis discarded if there are other results in the chain. If this is aSETcommand, thenewResultis returned has the new head of the chain. If the newResult is aSETcommand, it's not appended and this is returned.- Parameters:
newResult- the result to append- Returns:
- the head of the chain
-
-