Class PersistentQueryConfigTableUtils
java.lang.Object
com.illumon.iris.controller.utils.PersistentQueryConfigTableUtils
public class PersistentQueryConfigTableUtils extends Object
Utility class for creating a Persistent Query Config Table and supports Swing Panel Rendering.
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classPersistentQueryConfigTableUtils.ProgressInfostatic classPersistentQueryConfigTableUtils.SelectedQueryStatesHelper class to analyze and hold selected query states and permissions. -
Field Summary
Fields Modifier and Type Field Description static StringQUERY_TYPE_TO_NAME_KEY -
Constructor Summary
Constructors Constructor Description PersistentQueryConfigTableUtils() -
Method Summary
Modifier and Type Method Description static Map<String,String>getQueryTypeNames(PersistentQueryControllerConfiguration serverConfiguration)Gets a map of from Query Type to Display Name.static PersistentQueryConfigTableUtils.SelectedQueryStatesgetSelectedQueryState(IrisUserContext irisUserContext, PersistentQueryInfo[] selectedQueries, PersistentQueryControllerConfiguration serverConfiguration)Gets the states for selected queries and permissions for those queries based on user context.static booleanisStateColumn(int columnIndex)static booleanisStateColumn(String columnName)static FunctionalInterfaces.TriFunction<PersistentQueryInfo,Map<Long,PersistentQueryInfo>,Map<String,Map<String,String>>,Object>lookupGetValueProcedure(String columnName)Creates a function that will lookup the value of column based on its name.
-
Field Details
-
QUERY_TYPE_TO_NAME_KEY
- See Also:
- Constant Field Values
-
-
Constructor Details
-
PersistentQueryConfigTableUtils
public PersistentQueryConfigTableUtils()
-
-
Method Details
-
getQueryTypeNames
public static Map<String,String> getQueryTypeNames(PersistentQueryControllerConfiguration serverConfiguration)Gets a map of from Query Type to Display Name.- Parameters:
serverConfiguration- the server configuration- Returns:
- the query type name map
-
lookupGetValueProcedure
public static FunctionalInterfaces.TriFunction<PersistentQueryInfo,Map<Long,PersistentQueryInfo>,Map<String,Map<String,String>>,Object> lookupGetValueProcedure(String columnName)Creates a function that will lookup the value of column based on its name.- Parameters:
columnName- the name of the column- Returns:
- a function that will lookup the value
-
isStateColumn
-
isStateColumn
public static boolean isStateColumn(int columnIndex) -
getSelectedQueryState
public static PersistentQueryConfigTableUtils.SelectedQueryStates getSelectedQueryState(IrisUserContext irisUserContext, PersistentQueryInfo[] selectedQueries, PersistentQueryControllerConfiguration serverConfiguration)Gets the states for selected queries and permissions for those queries based on user context.- Parameters:
irisUserContext- the user contextselectedQueries- the selected queriesserverConfiguration- the server configuration- Returns:
- a data object containing the states and permissions
-