net.sourceforge.rpgee.dice
Class AbstractRandomValue
java.lang.Object
net.sourceforge.rpgee.dice.AbstractRandomValue
- All Implemented Interfaces:
- Describable, RandomValue
public abstract class AbstractRandomValue
- extends java.lang.Object
- implements RandomValue
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AbstractRandomValue
public AbstractRandomValue(java.lang.Integer _sides,
RandomValueResultMapper _mapper)
AbstractRandomValue
public AbstractRandomValue(java.lang.Integer _sides,
RandomValueResultMapper _mapper,
RandomValue _original)
getValue
public int getValue()
- Description copied from interface:
RandomValue
- List of values rolled. This is the "result" of the roll, and can be either an Integer or a List. Depending on the
type of randomizer something is, a List might be added together to produce the "valueAsString()" result before
mapping, or it might be the case that each value in the List gets mapped.
- Specified by:
getValue
in interface RandomValue
getValueAsString
public java.lang.String getValueAsString()
- Description copied from interface:
RandomValue
- Shows the "rolled" values for random elements The mapped value is presented if this die has a value mapper
- Specified by:
getValueAsString
in interface RandomValue
- Returns:
- String of the produced value (generally a number)
getSides
public int getSides()
- Specified by:
getSides
in interface RandomValue
setValue
public void setValue(int _value)
throws InvalidParameterException
- Specified by:
setValue
in interface RandomValue
- Throws:
InvalidParameterException
getHTMLDescription
public java.lang.String getHTMLDescription()
- Specified by:
getHTMLDescription
in interface Describable
getMapper
public RandomValueResultMapper getMapper()
- Specified by:
getMapper
in interface RandomValue
getOriginalValue
public RandomValue getOriginalValue()
- Specified by:
getOriginalValue
in interface RandomValue
isOriginalValue
public boolean isOriginalValue()
- Specified by:
isOriginalValue
in interface RandomValue
Copyright © 2006 An Infinite Number of Monkeys. All Rights Reserved.