Modifier and Type | Class and Description |
---|---|
static class |
CustomVariable.Builder
Mutable for builder for setting up unnecessary properties of
class CustomVariable . |
static class |
CustomVariable.Companion |
Variable.DefaultImpls
Modifier and Type | Field and Description |
---|---|
static CustomVariable.Companion |
Companion |
Constructor and Description |
---|
CustomVariable(java.lang.String name,
java.lang.String displayName,
HidingMode hidingMode,
boolean multiValuesAllowed,
boolean includeAllValue,
java.lang.String allValue,
java.lang.String[] values)
Public constructor for custom variable.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
asVariable()
Returns string representation of this variable.
|
java.lang.String |
getName()
Variable name.
|
org.json.JSONObject |
toJson()
returns object as JSON.
|
asVariable, getName
public static CustomVariable.Companion Companion
public CustomVariable(java.lang.String name, java.lang.String displayName, HidingMode hidingMode, boolean multiValuesAllowed, boolean includeAllValue, java.lang.String allValue, java.lang.String[] values)
Public constructor for custom variable.
name
- see BaseVariable.namedisplayName
- see BaseVariable.displayNamehidingMode
- see BaseVariable.hidingModemultiValuesAllowed
- enables multiple values selected at the same timeincludeAllValue
- when true the All option is available to selectallValue
- optional value that will be used when All option is selected. Ignored by Grafana
when includeAllValue is falsevalues
- array of options for this variable. This array will be serialized as a CSV string.