Class VariableValue
- java.lang.Object
-
- software.amazon.awssdk.services.evidently.model.VariableValue
-
- All Implemented Interfaces:
Serializable,SdkPojo,ToCopyableBuilder<VariableValue.Builder,VariableValue>
@Generated("software.amazon.awssdk:codegen") public final class VariableValue extends Object implements SdkPojo, Serializable, ToCopyableBuilder<VariableValue.Builder,VariableValue>
The value assigned to a feature variation. This structure must contain exactly one field. It can be
boolValue,doubleValue,longValue, orstringValue.- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceVariableValue.Builderstatic classVariableValue.Type
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description BooleanboolValue()If this feature uses the Boolean variation type, this field contains the Boolean value of this variation.static VariableValue.Builderbuilder()DoubledoubleValue()If this feature uses the double integer variation type, this field contains the double integer value of this variation.booleanequals(Object obj)booleanequalsBySdkFields(Object obj)static VariableValuefromBoolValue(Boolean boolValue)Create an instance of this class withboolValue()initialized to the given value.static VariableValuefromDoubleValue(Double doubleValue)Create an instance of this class withdoubleValue()initialized to the given value.static VariableValuefromLongValue(Long longValue)Create an instance of this class withlongValue()initialized to the given value.static VariableValuefromStringValue(String stringValue)Create an instance of this class withstringValue()initialized to the given value.<T> Optional<T>getValueForField(String fieldName, Class<T> clazz)inthashCode()LonglongValue()If this feature uses the long variation type, this field contains the long value of this variation.Map<String,SdkField<?>>sdkFieldNameToField()List<SdkField<?>>sdkFields()static Class<? extends VariableValue.Builder>serializableBuilderClass()StringstringValue()If this feature uses the string variation type, this field contains the string value of this variation.VariableValue.BuildertoBuilder()StringtoString()Returns a string representation of this object.VariableValue.Typetype()Retrieve an enum value representing which member of this object is populated.-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface software.amazon.awssdk.utils.builder.ToCopyableBuilder
copy
-
-
-
-
Method Detail
-
boolValue
public final Boolean boolValue()
If this feature uses the Boolean variation type, this field contains the Boolean value of this variation.
- Returns:
- If this feature uses the Boolean variation type, this field contains the Boolean value of this variation.
-
doubleValue
public final Double doubleValue()
If this feature uses the double integer variation type, this field contains the double integer value of this variation.
- Returns:
- If this feature uses the double integer variation type, this field contains the double integer value of this variation.
-
longValue
public final Long longValue()
If this feature uses the long variation type, this field contains the long value of this variation.
- Returns:
- If this feature uses the long variation type, this field contains the long value of this variation.
-
stringValue
public final String stringValue()
If this feature uses the string variation type, this field contains the string value of this variation.
- Returns:
- If this feature uses the string variation type, this field contains the string value of this variation.
-
toBuilder
public VariableValue.Builder toBuilder()
- Specified by:
toBuilderin interfaceToCopyableBuilder<VariableValue.Builder,VariableValue>
-
builder
public static VariableValue.Builder builder()
-
serializableBuilderClass
public static Class<? extends VariableValue.Builder> serializableBuilderClass()
-
equalsBySdkFields
public final boolean equalsBySdkFields(Object obj)
- Specified by:
equalsBySdkFieldsin interfaceSdkPojo
-
toString
public final String toString()
Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
-
fromBoolValue
public static VariableValue fromBoolValue(Boolean boolValue)
Create an instance of this class withboolValue()initialized to the given value.If this feature uses the Boolean variation type, this field contains the Boolean value of this variation.
- Parameters:
boolValue- If this feature uses the Boolean variation type, this field contains the Boolean value of this variation.
-
fromDoubleValue
public static VariableValue fromDoubleValue(Double doubleValue)
Create an instance of this class withdoubleValue()initialized to the given value.If this feature uses the double integer variation type, this field contains the double integer value of this variation.
- Parameters:
doubleValue- If this feature uses the double integer variation type, this field contains the double integer value of this variation.
-
fromLongValue
public static VariableValue fromLongValue(Long longValue)
Create an instance of this class withlongValue()initialized to the given value.If this feature uses the long variation type, this field contains the long value of this variation.
- Parameters:
longValue- If this feature uses the long variation type, this field contains the long value of this variation.
-
fromStringValue
public static VariableValue fromStringValue(String stringValue)
Create an instance of this class withstringValue()initialized to the given value.If this feature uses the string variation type, this field contains the string value of this variation.
- Parameters:
stringValue- If this feature uses the string variation type, this field contains the string value of this variation.
-
type
public VariableValue.Type type()
Retrieve an enum value representing which member of this object is populated. When this class is returned in a service response, this will beVariableValue.Type.UNKNOWN_TO_SDK_VERSIONif the service returned a member that is only known to a newer SDK version. When this class is created directly in your code, this will beVariableValue.Type.UNKNOWN_TO_SDK_VERSIONif zero members are set, andnullif more than one member is set.
-
sdkFieldNameToField
public final Map<String,SdkField<?>> sdkFieldNameToField()
- Specified by:
sdkFieldNameToFieldin interfaceSdkPojo
-
-