Parameter

public final class Parameter extends Object

Represents a Remote Config parameter that can be included in a Template. At minimum, a default value or a conditional value must be present for the parameter to have any effect.

Public Constructor Summary

Parameter()
Creates a new Parameter.

Public Method Summary

boolean
equals(Object o)
Map<String, ParameterValue>
getConditionalValues()
Gets the conditional values of the parameter.
ParameterValue
getDefaultValue()
Gets the default value of the parameter.
String
getDescription()
Gets the description of the parameter.
ParameterValueType
getValueType()
Gets the data type of the parameter value.
int
Parameter
setConditionalValues(Map<String, ParameterValue> conditionalValues)
Sets the conditional values of the parameter.
Parameter
setDefaultValue(ParameterValue value)
Sets the default value of the parameter.
Parameter
setDescription(String description)
Sets the description of the parameter.
Parameter
setValueType(ParameterValueType valueType)
Sets the data type of the parameter value.

Inherited Method Summary

Public Constructors

public Parameter ()

Creates a new Parameter.

Public Methods

public boolean equals (Object o)

public Map<String, ParameterValue> getConditionalValues ()

Gets the conditional values of the parameter. The condition name of the highest priority (the one listed first in the Template's conditions list) determines the value of this parameter.

Returns
  • A non-null map of conditional values.

public ParameterValue getDefaultValue ()

Gets the default value of the parameter.

Returns

public String getDescription ()

Gets the description of the parameter.

Returns
  • The description of the parameter or null.

public ParameterValueType getValueType ()

Gets the data type of the parameter value.

Returns
  • The data type of the parameter value or null.

public int hashCode ()

public Parameter setConditionalValues (Map<String, ParameterValue> conditionalValues)

Sets the conditional values of the parameter. The condition name of the highest priority (the one listed first in the Template's conditions list) determines the value of this parameter.

Parameters
conditionalValues A non-null map of conditional values.
Returns

public Parameter setDefaultValue (ParameterValue value)

Sets the default value of the parameter. This is the value to set the parameter to, when none of the named conditions evaluate to true.

Parameters
value An ParameterValue instance.
Returns

public Parameter setDescription (String description)

Sets the description of the parameter. Should not be over 100 characters and may contain any Unicode characters.

Parameters
description The description of the parameter.
Returns

public Parameter setValueType (ParameterValueType valueType)

Sets the data type of the parameter value. Defaults to `ParameterValueType.STRING` if unspecified.

Parameters
valueType The data type of the parameter value.
Returns