Class DADashboard
java.lang.Object
overit.geocall.da.DABase
overit.geocallapp.wfm.notifications.dashboard.DADashboard
- All Implemented Interfaces:
Serializable,DataAttributesHolder,EDMConfigurableBean,overit.geocall.marks.FieldExposer,overit.geocall.marks.NameExposer,DBFieldMapper,DBObjectMapper,Identified,Tool
- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final StringFields inherited from class overit.geocall.da.DABase
DA_BASE_FILTER_PREFIX, DELETE_FILTER, DELETE_PK, INSATE, INSERT, REPLACE_DBVIEW, SAVE_DBVIEW, SELECT_FILTER, SELECT_NONE, SELECT_PK, UPDATE_FILTER, UPDATE_PK, UPSERT -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddBranchFilter(int i, DBStatement stmt, HashGetter filter, PooledConnection conn) protected voidaddCustomJoin(int i, DBStatement stmt, HashGetter filter) protected voidaddNotificationFilters(int i, DBStatement stmt, HashGetter filter, PooledConnection conn) protected voidaddRightJoinGrouping(int i, PooledConnection conn, DBStatement stmt, HashGetter filter, String field) protected voidaddWOFilters(int i, DBStatement stmt, HashGetter filter, PooledConnection conn) Returns the field of the table in which is stored the "branch id" valueprotected intgiveCommands(int i, PooledConnection conn, DBStatement stmt, HashGetter filter, HashGetter values) Implements new specific commands that are different from the standard ones.Must returns aDBFieldMapif you want to implement an object mapping mechanism for queries and standard commands.Must returns aDBObjectMapif you want to implement an object mapping mechanism for queries and standard commands.Returns the field of the table in which is stored the "factory id" valueString[]Returns the array that contains the names of the columns on which we made the sorting of the result.Returns the name of the pool from which the specific DA extracts the connections when they are not explicitly passed to methods.String[]Must be implemented and returns the array that contains the primary keys of the specific table on which the DA acts.protected DBViewgiveQueries(int i, PooledConnection conn, DBStatement stmt, HashGetter filter, int maxrows, int skiprows) Implements new specific queries that are different from the standard ones.Must be implemented and returns a string that represent the name of the field used as sequence for the insert commands on the table.Returns the name of the table on which the specific DA acts.Methods inherited from class overit.geocall.da.DABase
command, command, command, getAutoIncrementVal, getDataAttributes, getDBFieldMap, getDBFields, getDBObjectMap, getFieldMap, getIdentity, getQueryId, getQueryId, getReadOnlyCols, getSequenceNextVal, getTeacher, giveIsDistinct, giveIsService, giveMinLevel, giveStar, hasNotBeenDecorated, haveDBFieldMap, haveDBObjectMap, markAsDecorated, postDelete, postInsert, postUpdate, preDelete, preInsert, preQuery, preUpdate, query, query, query, query, query, release, removeReadOnlyCols, replace, replace, save, save, setDataAttributes, setDBFieldMap, setDBObjectMap, setIdentity, setReadOnlyCols, useConnectionMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface overit.geocall.edm.model.DataAttributesHolder
getEntitiesMethods inherited from interface overit.geocall.edm.model.EDMConfigurableBean
getEntity, hasEntity
-
Field Details
-
POOL
- See Also:
-
TABLE
- See Also:
-
PK
- See Also:
-
FACTORY
- See Also:
-
ORD
- See Also:
-
SELECT_NOTIFICATIONS_FOR_CHART
public static final int SELECT_NOTIFICATIONS_FOR_CHART- See Also:
-
SELECT_NOTIFICATION_FOR_AVERAGE_TIME
public static final int SELECT_NOTIFICATION_FOR_AVERAGE_TIME- See Also:
-
SELECT_NOTIFICATION_FOR_AVERAGE_TIME_BEFORE
public static final int SELECT_NOTIFICATION_FOR_AVERAGE_TIME_BEFORE- See Also:
-
SELECT_NOTIFICATION_FOR_AVERAGE_TIME_MTTR
public static final int SELECT_NOTIFICATION_FOR_AVERAGE_TIME_MTTR- See Also:
-
SELECT_NOTIFICATIONS_FOR_SEARCH
public static final int SELECT_NOTIFICATIONS_FOR_SEARCH- See Also:
-
SELECT_WO_FOR_SEARCH
public static final int SELECT_WO_FOR_SEARCH- See Also:
-
SELECT_CHART_FAILURES_DEEPDIVE
public static final int SELECT_CHART_FAILURES_DEEPDIVE- See Also:
-
SELECT_CHART_FAILURE_INVESTIGATION
public static final int SELECT_CHART_FAILURE_INVESTIGATION- See Also:
-
SELECT_NOTIFICATION_WO
public static final int SELECT_NOTIFICATION_WO- See Also:
-
SELECT_CHART_ANALIZED_FAILURES
public static final int SELECT_CHART_ANALIZED_FAILURES- See Also:
-
SELECT_CHART_CMIDENTIFIED
public static final int SELECT_CHART_CMIDENTIFIED- See Also:
-
SELECT_CHART_CMCARRIEDOUT
public static final int SELECT_CHART_CMCARRIEDOUT- See Also:
-
SELECT_CHART_NOT_ANALIZED_FAILURES
public static final int SELECT_CHART_NOT_ANALIZED_FAILURES- See Also:
-
SELECT_EWO_FOR_SEARCH
public static final int SELECT_EWO_FOR_SEARCH- See Also:
-
-
Constructor Details
-
DADashboard
public DADashboard()
-
-
Method Details
-
giveTableName
Description copied from class:DABaseReturns the name of the table on which the specific DA acts. It must be implemented making it return a string that represents the name of the table on which you want to access and operate.- Specified by:
giveTableNamein classDABase- Returns:
- The name of the table on which the specific DA acts
-
givePoolName
Description copied from class:DABaseReturns the name of the pool from which the specific DA extracts the connections when they are not explicitly passed to methods. It must be implemented making it return a string that represents the name of the pool.- Specified by:
givePoolNamein classDABase- Returns:
- The name of the pool from which the specific DA extracts the connections. It must return a not-null value
-
giveSequenceField
Description copied from class:DABaseMust be implemented and returns a string that represent the name of the field used as sequence for the insert commands on the table.- Specified by:
giveSequenceFieldin classDABase- Returns:
- The name of the sequence field or null if there isn't a defined sequence
-
givePrimaryKeys
Description copied from class:DABaseMust be implemented and returns the array that contains the primary keys of the specific table on which the DA acts.- Specified by:
givePrimaryKeysin classDABase- Returns:
- Array that contains the name of the fields that are primary keys of the specific table
-
giveFactoryField
Description copied from class:DABaseReturns the field of the table in which is stored the "factory id" value- Specified by:
giveFactoryFieldin classDABase- Returns:
- The field containing the "factory id" value
-
giveOrderCols
Description copied from class:DABaseReturns the array that contains the names of the columns on which we made the sorting of the result.- Specified by:
giveOrderColsin classDABase- Returns:
- Array that contains the name of the fields of the specific table
-
giveBranchField
Description copied from class:DABaseReturns the field of the table in which is stored the "branch id" value- Specified by:
giveBranchFieldin classDABase- Returns:
- The name of the table field in which we store the "branch id" value; it must retrun null if we don't want to store this information
-
giveDBObjectMap
Description copied from class:DABaseMust returns aDBObjectMapif you want to implement an object mapping mechanism for queries and standard commands. If you do not want to define any mapping just make sure that the method returns null.- Specified by:
giveDBObjectMapin classDABase- Returns:
- the DBObjectMapper that defines the object mapping, or null
-
giveDBFieldMap
Description copied from class:DABaseMust returns aDBFieldMapif you want to implement an object mapping mechanism for queries and standard commands. If you do not want to define any mapping just make sure that the method returns null.- Specified by:
giveDBFieldMapin classDABase- Returns:
- the DBFieldMapper that defines the object mapping, or null
-
giveQueries
protected DBView giveQueries(int i, PooledConnection conn, DBStatement stmt, HashGetter filter, int maxrows, int skiprows) throws SQLException Description copied from class:DABaseImplements new specific queries that are different from the standard ones.
For all the queries implemented with this method we must set, in theDBStatement, the SQL (setSql()), the parameters (available as filters and settable usingset()) and any map (setDBObjectMap(),setDBFieldMap()) to use on the DBStatement.
The execution is done when we call one of thequery()methods, so we can do here only the statement setup.
It is fundamental that the method return null if the query id is not recognized.- Specified by:
giveQueriesin classDABase- Parameters:
i- The id of the queryconn- Connection from which we have extracted the DBStatement; it can be used to extract other DBStatementstmt- DBStatement used to set the SQL code and the parametersfilter- Parameters to set in the DBStatementmaxrows- Maximum rows number extracted with the queryskiprows- Number of initial lines that you do not want to be returned. Even these lines, although skipped, are counted in the maxrows parameter.- Returns:
- If the query id is valid we must return the DBStatement passed as parameter; if the is is not valid, or we don't want to add specific queries to the standard ones we must return null
- Throws:
SQLException- If there is an error in the SQL SQLException is thrown
-
addRightJoinGrouping
protected void addRightJoinGrouping(int i, PooledConnection conn, DBStatement stmt, HashGetter filter, String field) -
giveCommands
protected int giveCommands(int i, PooledConnection conn, DBStatement stmt, HashGetter filter, HashGetter values) throws SQLException Description copied from class:DABaseImplements new specific commands that are different from the standard ones.
For all the commands implemented with this method we must set, in theDBStatement, the SQL (setSql()), (setDBObjectMap(),setDBFieldMap()) to use on the DBStatement.
The execution is done when we call one of thecommand()methods, so we can do here only the statement setup.
It is fundamental that the method return null if the command id is not recognized.- Specified by:
giveCommandsin classDABase- Parameters:
i- The id of the commandconn- Connection from which we have extracted the DBStatement; it can be used to extract other DBStatementstmt- DBStatement used to set the SQL code and the parametersfilter- Values used as filters to set for the update commandsvalues- Values to set as parameters in the DBStatement- Returns:
- If the command id is valid we must return the DBStatement passed as parameter; if the id is not valid, or we don't want to add specific commands to the standard ones we must return null
- Throws:
SQLException- If there is an error in the SQL SQLException is thrown
-
addCustomJoin
-
addNotificationFilters
protected void addNotificationFilters(int i, DBStatement stmt, HashGetter filter, PooledConnection conn) -
addWOFilters
-
addBranchFilter
-