kinetic.util
Class EffectParameter.EnumeratedString

java.lang.Object
  |
  +--kinetic.util.EffectParameter
        |
        +--kinetic.util.EffectParameter.EnumeratedString
Enclosing class:
EffectParameter

public static class EffectParameter.EnumeratedString
extends EffectParameter

Enumerated String Parameter Class


Nested Class Summary
 
Nested classes inherited from class kinetic.util.EffectParameter
EffectParameter.Boolean, EffectParameter.BoundedDouble, EffectParameter.BoundedInteger, EffectParameter.Double, EffectParameter.EnumeratedString, EffectParameter.Integer, EffectParameter.Percentage, EffectParameter.String, EffectParameter.ZeroToOne
 
Field Summary
 
Fields inherited from class kinetic.util.EffectParameter
currentValue, defaultValue, name, type, TYPE_BOOLEAN, TYPE_BOUNDED_DOUBLE, TYPE_BOUNDED_INTEGER, TYPE_DOUBLE, TYPE_ENUMERATED_STRING, TYPE_INTEGER, TYPE_PERCENTAGE, TYPE_STRING, TYPE_UNKNOWN, TYPE_ZERO_TO_ONE
 
Constructor Summary
EffectParameter.EnumeratedString(java.lang.String n, java.lang.String v)
          creates a new instance of the type parameter
 
Method Summary
 void addChoice(java.lang.String v)
          adds a choice to the choice list
 void addChoices(java.lang.String[] array)
          adds an array of choices to the choice list
 java.lang.String[] getChoices()
          return the choice list as an array
 int getSize()
          gets the number of available choices
 java.lang.String getValue()
          gets the type casted version of the current value object
 void setValue(java.lang.String v)
          sets the current value object with a type casted variable
 
Methods inherited from class kinetic.util.EffectParameter
getCurrentObject, getDefaultObject, getName, getType, setCurrentObject, setDefaultObject, setName, setType
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EffectParameter.EnumeratedString

public EffectParameter.EnumeratedString(java.lang.String n,
                                        java.lang.String v)
creates a new instance of the type parameter

Parameters:
n - name of the parameter
v - the default and initial value for the parameter
Method Detail

getValue

public java.lang.String getValue()
gets the type casted version of the current value object

Returns:
value of the parameter

setValue

public void setValue(java.lang.String v)
sets the current value object with a type casted variable

Parameters:
v - new value for the parameter

getSize

public int getSize()
gets the number of available choices

Returns:
size of the choice list

addChoice

public void addChoice(java.lang.String v)
adds a choice to the choice list

Parameters:
v - a new choice

addChoices

public void addChoices(java.lang.String[] array)
adds an array of choices to the choice list

Parameters:
array - and array of new choices

getChoices

public java.lang.String[] getChoices()
return the choice list as an array

Returns:
an array of the available choices