Class QueryListenerWrapper

java.lang.Object
com.streambase.liveview.client.QueryListenerWrapper
All Implemented Interfaces:
Query, QueryListener, Closeable, AutoCloseable, EventListener

public class QueryListenerWrapper extends Object implements QueryListener, Query
This class is used by LiveViewMultiConnectionImpl to wrap BOTH the queryListener that the user passes in to an execQuery, AND the Query that is passed back to him. We need the former so that we can intercept the close command that comes from the server going down -- we don't actually close the query, we just save it so that it can be failed over to a new server. We need to wrap the Query so that we can intercept with the client calls close on his own. In that case, we want to actually close the query, plus we want to remove this query from our list of ones that need to be reconnected to any new server.