Class KpiAlert
java.lang.Object
com.gooddata.sdk.model.md.AbstractObj
com.gooddata.sdk.model.md.dashboard.KpiAlert
- All Implemented Interfaces:
Obj,Queryable,Updatable,Serializable
Represents KPI alert set for some KPI on analytical dashboard.
- See Also:
-
Field Summary
Fields inherited from class com.gooddata.sdk.model.md.AbstractObj
metaFields inherited from interface com.gooddata.sdk.model.md.Obj
CREATE_URI, CREATE_WITH_ID_URI, OBJ_URI, URI -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondoublebooleanwithTriggeredState(boolean wasTriggered) Creates new copy of KPI alert with a given triggered state changed.Methods inherited from class com.gooddata.sdk.model.md.AbstractObj
getAuthor, getCategory, getContributor, getCreated, getFlags, getId, getIdentifier, getSummary, getTags, getTitle, getUpdated, getUri, isDeprecated, isLocked, isProduction, isSharedWithSomeone, isUnlisted, setCategory, setDeprecated, setFlags, setIdentifier, setLocked, setProduction, setSharedWithSomeone, setSummary, setTags, setTitle, setUnlisted, toString, uris
-
Constructor Details
-
KpiAlert
public KpiAlert(String title, String kpiUri, String dashboardUri, double threshold, String triggerCondition, String filterContextUri) Constructor.- Parameters:
title- KPI alert titlekpiUri- URI of the KPI for which the alert is defineddashboardUri- URI of the KPI where the KPI alert is locatedthreshold- KPI alert thresholdtriggerCondition- condition for triggering KPI alertfilterContextUri- URI of filter context used for computation of KPI alert (optional)
-
-
Method Details
-
wasTriggered
public boolean wasTriggered()- Returns:
- if the KPI alert was already triggered
-
getThreshold
public double getThreshold()- Returns:
- KPI value threshold for triggering KPI alert
-
getFilterContextUri
- Returns:
- filters used for computation of KPI alert
-
getTriggerCondition
- Returns:
- condition for triggering KPI alert (e.g.
"above_threshold")
-
getDashboardUri
- Returns:
- URI of the analytical dashboard where the alert is located
-
getKpiUri
- Returns:
- URI of the KPI for which is the alert configured
-
withTriggeredState
Creates new copy of KPI alert with a given triggered state changed.- Parameters:
wasTriggered- triggered state- Returns:
- new KPI alert
-