|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--xbn.XBNObject | +--xbn.util.Range
Manages an int that must conform to a RangeConfig. See RangeConfig.
Source code: Range.java.
Fields inherited from class xbn.XBNObject |
bFALSE_IN_PRODUCTION, bTRUE_IN_PRODUCTION, sCNSTR, sES, sLINE_SEP |
Constructor Summary | |
Range(Range r_ange)
Create a copy of the provided Range. |
|
Range(RangeConfig range_config)
Create a Range. |
|
Range(RangeConfig range_config,
int i_value)
Create a Range. |
Method Summary | |
int |
get()
Get the current value. |
RangeConfig |
getRangeConfig()
Get the RangeConfig for direct manipulation. |
boolean |
isSet()
Has the value of this Range been set yet? |
void |
reset()
Initialize this object as if a value were never set into it. |
void |
set(int i_potential)
Set the value to the provided int. |
String |
toString()
Get some information about this Range. |
Methods inherited from class xbn.XBNObject |
getXMsgPrefix, sop, sopl, sopl, throwAX, throwAXIfBadStr, throwAXIfNull, throwAXSpoof |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Range(RangeConfig range_config)
Create a Range.
Note that isSet will return false, until you set a value.
range_config
- The RangeConfig. May not be null.public Range(RangeConfig range_config, int i_value)
Create a Range.
range_config
- The RangeConfig. May not be null.i_value
- The initial value. Passed directly to set.public Range(Range r_ange)
Create a copy of the provided Range. This is a deep copy.
r_ange
- The Range to copy. May not be null.Method Detail |
public int get()
Get the current value.
AssertException
- If no value has been set into this Range.public final void set(int i_potential)
Set the value to the provided int.
i_potential
- The potential value. Must be valid according to getRangeConfig().isValid.public final RangeConfig getRangeConfig()
Get the RangeConfig for direct manipulation.
public final void reset()
Initialize this object as if a value were never set into it. The RangeConfig object is unaffected by this.
public boolean isSet()
Has the value of this Range been set yet?
public String toString()
Get some information about this Range.
toString
in class Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright 1997-2003, Jeff Epstein, All Rights Reserved. See top of source code files for copyright notice.
http://sourceforge.net/projects/xbnjava