it.eng.spagobi.kpi.config.dao
Interface IKpiDAO

All Superinterfaces:
ISpagoBIDao
All Known Implementing Classes:
KpiDAOImpl

public interface IKpiDAO
extends ISpagoBIDao


Method Summary
 java.lang.Integer countKpis()
           
 boolean deleteKpi(java.lang.Integer kpiId)
           
 boolean deleteKpiRel(java.lang.Integer kpiRelId)
           
 void deleteKpiValueFromInterval(java.lang.Integer kpiInstanceId, java.util.Date from, java.util.Date to, Resource r, OrganizationalUnitGrantNode grantNode)
          KpiValue valid for the the KpiInstance selected, ou selected for the resource selected, in the date selected
 KpiValue getDisplayKpiValue(java.lang.Integer kpiInstanceId, java.util.Date d, Resource r, OrganizationalUnitGrantNode grantNode)
          The last KpiValue for the the KpiInstance selected, for the resource selected, ou and hiererchy selected in the date selected or before
 it.eng.spagobi.tools.dataset.bo.IDataSet getDsFromKpiId(java.lang.Integer kpiId)
           
 java.lang.String getKpiTrendXmlResult(java.lang.Integer resId, java.lang.Integer kpiInstId, java.util.Date endDate)
          Returns a List of all the the Threshols of the KpiInstance
 java.lang.String getKpiTrendXmlResult(java.lang.Integer resId, java.lang.Integer kpiInstId, java.util.Date beginDate, java.util.Date endDate)
          Returns a List of all the the Threshols of the KpiInstance
 KpiValue getKpiValue(java.lang.Integer kpiInstanceId, java.util.Date d, Resource r, OrganizationalUnitGrantNode grantNode)
          KpiValue valid for the the KpiInstance selected, for the resource selected, ant the selected grant node associated
 KpiValue getKpiValueFromInterval(java.lang.Integer kpiInstanceId, java.util.Date from, java.util.Date to, Resource r, OrganizationalUnitGrantNode grantNode)
          KpiValue valid for the the KpiInstance selected, for the resource selected,ou selected in the date selected
 java.lang.Integer insertKpi(Kpi toCreate)
           
 java.lang.Integer insertKpiValue(KpiValue value)
          Inserts a new KPI Value with its date, value period and thresholds
 Kpi loadKpiById(java.lang.Integer id)
          Returns the Kpi of the referred id
 Kpi loadKpiDefinitionById(java.lang.Integer id)
          Returns the Kpi Definition of the referred id
 KpiDocuments loadKpiDocByKpiIdAndDocId(java.lang.Integer kpiId, java.lang.Integer docId)
           
 java.util.List loadKpiList()
          Returns the list of Kpi.
 java.util.List loadKpiList(java.lang.String fieldOrder, java.lang.String typeOrder)
           
 java.util.List loadKpiListFiltered(java.lang.String hsql, java.lang.Integer offset, java.lang.Integer fetchSize)
          Returns the list of Kpi filtered by hsql query string.
 java.util.List loadKpiRelListByParentId(java.lang.Integer kpiParentId)
           
 java.lang.String loadKPIValueXml(java.lang.Integer kpiValueId)
           
 java.util.List loadPagedKpiList(java.lang.Integer offset, java.lang.Integer fetchSize)
           
 void modifyKpi(Kpi kpi)
           
 java.lang.Integer setKpiRel(java.lang.Integer kpiParentId, java.lang.Integer kpiChildId, java.lang.String parameter)
           
 
Methods inherited from interface it.eng.spagobi.commons.dao.ISpagoBIDao
getUserProfile, setUserID, setUserProfile
 

Method Detail

loadKPIValueXml

java.lang.String loadKPIValueXml(java.lang.Integer kpiValueId)
                                 throws it.eng.spago.error.EMFUserError
Throws:
it.eng.spago.error.EMFUserError

insertKpiValue

java.lang.Integer insertKpiValue(KpiValue value)
                                 throws it.eng.spago.error.EMFUserError
Inserts a new KPI Value with its date, value period and thresholds

Parameters:
KpiValue - to insert
Throws:
it.eng.spago.error.EMFUserError - If an Exception occurred

loadKpiDocByKpiIdAndDocId

KpiDocuments loadKpiDocByKpiIdAndDocId(java.lang.Integer kpiId,
                                       java.lang.Integer docId)
                                       throws it.eng.spago.error.EMFUserError
Throws:
it.eng.spago.error.EMFUserError

getKpiTrendXmlResult

java.lang.String getKpiTrendXmlResult(java.lang.Integer resId,
                                      java.lang.Integer kpiInstId,
                                      java.util.Date endDate)
                                      throws it.eng.spago.base.SourceBeanException
Returns a List of all the the Threshols of the KpiInstance

Parameters:
Integer - resId, Integer kpiInstId, String endDate
Returns:
List of all the the Threshols of the KpiInstance
Throws:
it.eng.spago.error.EMFUserError - If an Exception occurred
it.eng.spago.base.SourceBeanException

getDsFromKpiId

it.eng.spagobi.tools.dataset.bo.IDataSet getDsFromKpiId(java.lang.Integer kpiId)
                                                        throws it.eng.spago.error.EMFUserError
Throws:
it.eng.spago.error.EMFUserError

getKpiTrendXmlResult

java.lang.String getKpiTrendXmlResult(java.lang.Integer resId,
                                      java.lang.Integer kpiInstId,
                                      java.util.Date beginDate,
                                      java.util.Date endDate)
                                      throws it.eng.spago.base.SourceBeanException
Returns a List of all the the Threshols of the KpiInstance

Parameters:
Integer - resId, Integer kpiInstId, String endDate
Returns:
List of all the the Threshols of the KpiInstance
Throws:
it.eng.spago.error.EMFUserError - If an Exception occurred
it.eng.spago.base.SourceBeanException

loadKpiById

Kpi loadKpiById(java.lang.Integer id)
                throws it.eng.spago.error.EMFUserError
Returns the Kpi of the referred id

Parameters:
id - of the Kpi
Returns:
Kpi of the referred id
Throws:
it.eng.spago.error.EMFUserError - If an Exception occurred

loadKpiDefinitionById

Kpi loadKpiDefinitionById(java.lang.Integer id)
                          throws it.eng.spago.error.EMFUserError
Returns the Kpi Definition of the referred id

Parameters:
id - of the Kpi
Returns:
Kpi of the referred id
Throws:
it.eng.spago.error.EMFUserError - If an Exception occurred

getKpiValue

KpiValue getKpiValue(java.lang.Integer kpiInstanceId,
                     java.util.Date d,
                     Resource r,
                     OrganizationalUnitGrantNode grantNode)
                     throws it.eng.spago.error.EMFUserError
KpiValue valid for the the KpiInstance selected, for the resource selected, ant the selected grant node associated

Parameters:
KpiValue -
Returns:
KpiValue valid for the the KpiInstance selected, for the resource selected,ou selected in the date selected
Throws:
it.eng.spago.error.EMFUserError - if an Exception occurs

getKpiValueFromInterval

KpiValue getKpiValueFromInterval(java.lang.Integer kpiInstanceId,
                                 java.util.Date from,
                                 java.util.Date to,
                                 Resource r,
                                 OrganizationalUnitGrantNode grantNode)
                                 throws it.eng.spago.error.EMFUserError
KpiValue valid for the the KpiInstance selected, for the resource selected,ou selected in the date selected

Parameters:
KpiValue -
Returns:
KpiValue valid for the the KpiInstance selected, ou/hierarchy company selected for the resource selected, in the date selected
Throws:
it.eng.spago.error.EMFUserError - if an Exception occurs

deleteKpiValueFromInterval

void deleteKpiValueFromInterval(java.lang.Integer kpiInstanceId,
                                java.util.Date from,
                                java.util.Date to,
                                Resource r,
                                OrganizationalUnitGrantNode grantNode)
                                throws it.eng.spago.error.EMFUserError
KpiValue valid for the the KpiInstance selected, ou selected for the resource selected, in the date selected

Parameters:
KpiValue -
Throws:
it.eng.spago.error.EMFUserError - if an Exception occurs

getDisplayKpiValue

KpiValue getDisplayKpiValue(java.lang.Integer kpiInstanceId,
                            java.util.Date d,
                            Resource r,
                            OrganizationalUnitGrantNode grantNode)
                            throws it.eng.spago.error.EMFUserError
The last KpiValue for the the KpiInstance selected, for the resource selected, ou and hiererchy selected in the date selected or before

Parameters:
kpiInstanceId -
d -
r -
grantNode -
Returns:
Throws:
it.eng.spago.error.EMFUserError

loadKpiList

java.util.List loadKpiList()
                           throws it.eng.spago.error.EMFUserError
Returns the list of Kpi.

Returns:
the list of all Kpi.
Throws:
it.eng.spago.error.EMFUserError - if an Exception occurs

loadKpiList

java.util.List loadKpiList(java.lang.String fieldOrder,
                           java.lang.String typeOrder)
                           throws it.eng.spago.error.EMFUserError
Throws:
it.eng.spago.error.EMFUserError

loadPagedKpiList

java.util.List loadPagedKpiList(java.lang.Integer offset,
                                java.lang.Integer fetchSize)
                                throws it.eng.spago.error.EMFUserError
Throws:
it.eng.spago.error.EMFUserError

countKpis

java.lang.Integer countKpis()
                            throws it.eng.spago.error.EMFUserError
Throws:
it.eng.spago.error.EMFUserError

modifyKpi

void modifyKpi(Kpi kpi)
               throws it.eng.spago.error.EMFUserError
Throws:
it.eng.spago.error.EMFUserError

insertKpi

java.lang.Integer insertKpi(Kpi toCreate)
                            throws it.eng.spago.error.EMFUserError
Throws:
it.eng.spago.error.EMFUserError

deleteKpi

boolean deleteKpi(java.lang.Integer kpiId)
                  throws it.eng.spago.error.EMFUserError
Throws:
it.eng.spago.error.EMFUserError

setKpiRel

java.lang.Integer setKpiRel(java.lang.Integer kpiParentId,
                            java.lang.Integer kpiChildId,
                            java.lang.String parameter)
                            throws it.eng.spago.error.EMFUserError
Throws:
it.eng.spago.error.EMFUserError

loadKpiRelListByParentId

java.util.List loadKpiRelListByParentId(java.lang.Integer kpiParentId)
                                        throws it.eng.spago.error.EMFUserError
Throws:
it.eng.spago.error.EMFUserError

deleteKpiRel

boolean deleteKpiRel(java.lang.Integer kpiRelId)
                     throws it.eng.spago.error.EMFUserError
Throws:
it.eng.spago.error.EMFUserError

loadKpiListFiltered

java.util.List loadKpiListFiltered(java.lang.String hsql,
                                   java.lang.Integer offset,
                                   java.lang.Integer fetchSize)
                                   throws it.eng.spago.error.EMFUserError
Returns the list of Kpi filtered by hsql query string.

Parameters:
hsql - query string
Returns:
the list of filtered Kpi.
Throws:
it.eng.spago.error.EMFUserError - if an Exception occurs