ca.sqlpower.wabit.rs
Class ResultSetProducerEvent

java.lang.Object
  extended by ca.sqlpower.wabit.rs.ResultSetProducerEvent

@Immutable
public class ResultSetProducerEvent
extends java.lang.Object

Event object that describes the outcome of a result set producer execution.


Constructor Summary
ResultSetProducerEvent(ResultSetProducer source, ResultSetAndUpdateCountCollection results)
          Creates a new event with the given parameters.
 
Method Summary
 ResultSetAndUpdateCountCollection getResults()
          Returns a copy of the collection of result sets.
 ResultSetProducer getSource()
          Returns a reference to the object that produced the result set and fired this event.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ResultSetProducerEvent

public ResultSetProducerEvent(ResultSetProducer source,
                              ResultSetAndUpdateCountCollection results)
Creates a new event with the given parameters.

Parameters:
source - The result set producer that plans to fire this event.
results - The results themselves. Shared copies will be handed out to listeners.
Method Detail

getSource

@Nonnull
public ResultSetProducer getSource()
Returns a reference to the object that produced the result set and fired this event.


getResults

@Nullable
public ResultSetAndUpdateCountCollection getResults()
Returns a copy of the collection of result sets. The copy has a collection of independent row cursor and other state (such as wasNull()) but shares the actual underlying data with (at least) all other invokers of this method.

Returns:
A copy containing mostly-independent copies of the new result sets, or null if an execution was attempted while the result set producer was not in a state where it could produce a result set.
See Also:
CachedRowSet.createShared()


Copyright © 2009. All Rights Reserved.