Package com.im.df.impl.db.resultset
Class ResultSetRegistry
- java.lang.Object
-
- com.im.df.impl.db.resultset.ResultSetRegistry
-
public final class ResultSetRegistry extends Object
Registry for currently activated result sets. Contains currently activated result sets for data trees. The selected (activated) result set from UI is propagated viaLookup
.- Since:
- 14.10.20
- Author:
- Peter Szepe
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
containsDataTree(com.im.df.api.ddl.DFDataTree dataTree)
Returns whether the registry contains result set for the data tree.ResultSetImpl
getActiveResultSet(com.im.df.api.ddl.DFDataTree dataTree, com.im.commons.progress.DFEnvironmentRO env)
Returns the currently active result set for the data tree.ResultSetImpl
getActiveResultSetIfExists(com.im.df.api.ddl.DFDataTree dataTree)
Returns the currently active result set for data tree.static ResultSetRegistry
getInstance()
Returns a singleton instance of registry.
-
-
-
Method Detail
-
getInstance
public static ResultSetRegistry getInstance()
Returns a singleton instance of registry.- Returns:
- singleton instance.
-
getActiveResultSet
public ResultSetImpl getActiveResultSet(com.im.df.api.ddl.DFDataTree dataTree, com.im.commons.progress.DFEnvironmentRO env)
Returns the currently active result set for the data tree. If there is no result set for the data tree creates one and activates it.- Parameters:
dataTree
- over which this result set operatesenv
- environment used during data loading- Returns:
- Active result set, never null.
-
getActiveResultSetIfExists
public ResultSetImpl getActiveResultSetIfExists(com.im.df.api.ddl.DFDataTree dataTree)
Returns the currently active result set for data tree. The last used result set is the active one. Activation is done by clicking in UI, e.g. by opening a view the active result set become the one bound with the opened view. Can return null if no active result set is present for the data tree.- Parameters:
dataTree
- The data tree.- Returns:
- The active result set or null if no active result set exists for data tree.
-
containsDataTree
public boolean containsDataTree(com.im.df.api.ddl.DFDataTree dataTree)
Returns whether the registry contains result set for the data tree.- Parameters:
dataTree
- The data tree.- Returns:
- True when the registry contains result set for the data tree.
-
-