|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--xbn.XBNObject | +--xbn.util.XBNLocked | +--xbn.array.primitive.PrimitiveArray | +--xbn.array.primitive.PrimitiveArrayString | +--xbn.array.primitive.PASInt
As PrimitiveArrayString that wraps around an array of ints.
Source code: PASInt.java.
Field Summary | |
static String |
sPASI
To shorten code and Javadoc. |
Fields inherited from class xbn.XBNObject |
bFALSE_IN_PRODUCTION, bTRUE_IN_PRODUCTION, sCNSTR, sES, sLINE_SEP |
Constructor Summary | |
PASInt()
Create a PASInt with default values. |
|
PASInt(int[] a_int)
Create a PASInt. |
|
PASInt(int[] a_int,
boolean b_lock)
Create a PASInt. |
|
PASInt(int[] a_int,
PARString par_string)
Create a PASInt. |
|
PASInt(String s_fqExtendingClass,
int[] a_int)
Create a PASInt. |
|
PASInt(String s_fqExtendingClass,
int[] a_int,
boolean b_lock)
Create a PASInt. |
|
PASInt(String s_fqExtendingClass,
int[] a_int,
PARString par_string)
Create a PASInt. |
|
PASInt(String s_fqExtendingClass,
int[] a_int,
PARString par_string,
boolean b_lock)
Create an PASInt. |
Method Summary | |
int[] |
getAOInt()
Get the int array for direct manipulation. |
int |
getLength()
How many elements exist in this PASInt? |
PAIInt |
getPAIInt()
Get a new PAIInt from the internally held int array. |
String |
getString(int i_dx)
Get the (int translated to a) string at the requested array index. |
boolean |
isLocked()
Is the value locked? |
boolean |
isNull()
Is the array null? |
boolean |
isNull(int i_dx)
Is the int at the requested array index null? |
void |
lock()
Lock the value, forbidding further sets. |
Methods inherited from class xbn.array.primitive.PrimitiveArrayString |
areLmntsEqual, areLmntsEqual, getPARString, isValid |
Methods inherited from class xbn.array.primitive.PrimitiveArray |
areLmntsEqual, crashIfBad, crashIfBad, declareNoViolation, getFQClassName, getList, getList, getList, getList, getNewAOSOBString, getNewAOSOBStringBuffer, getNewAOString, getPAViolation, getPrimitiveArrayRule, getSOBString, getSOBStringBuffer, isValid, setPAViolation, throwAXIllegal, throwLmntsEqualAioobx, wasValidated |
Methods inherited from class xbn.util.XBNLocked |
throwLX, throwLX, throwLXIfLocked, throwLXIfLocked, throwLXIfLocked, throwLXIfUnlocked |
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, toString, wait, wait, wait |
Field Detail |
public static final String sPASI
To shorten code and Javadoc.
Equal to "xbn.array.primitive.PASInt"
Constructor Detail |
public PASInt()
Create a PASInt with default values.
Equal to PASInt(null)
public PASInt(int[] a_int)
public PASInt(String s_fqExtendingClass, int[] a_int)
public PASInt(int[] a_int, PARString par_string)
public PASInt(String s_fqExtendingClass, int[] a_int, PARString par_string)
Create a PASInt.
Equal to PASInt(s_fqExtendingClass, a_int, par_string, false)
public PASInt(int[] a_int, boolean b_lock)
public PASInt(String s_fqExtendingClass, int[] a_int, boolean b_lock)
public PASInt(String s_fqExtendingClass, int[] a_int, PARString par_string, boolean b_lock)
Create an PASInt.
The first line of this constructor calls PrimitiveArrayInt(s_fqExtendingClass, par_string)
a_int
- The array of ints to analyze.b_lock
- Should a_int be directly accessible via getAOInt? If true, yes. If false, no.Method Detail |
public final int[] getAOInt()
Get the int array for direct manipulation.
LockedException
- If isLocked equals true.public final String getString(int i_dx)
Get the (int translated to a) string at the requested array index.
getString
in class PrimitiveArray
i_dx
- The array index. Must range 0..[getLength() - 1]
, inclusivepublic final int getLength()
How many elements exist in this PASInt?
getLength
in class PrimitiveArray
a_int.length
Where a_int is exactly as provided to the constructor.AssertException
- If isNull equals true.public final boolean isNull()
Is the array null?
isNull
in class PrimitiveArray
(a_int == null)
Where a_int is exactly as provided to the constructor.public final boolean isNull(int i_dx)
Is the int at the requested array index null?
isNull
in class PrimitiveArray
public final PAIInt getPAIInt()
Get a new PAIInt from the internally held int array.
(new PAIInt(getFQClassName(),aInt, isLocked()))
public final void lock()
LockOneWay
Lock the value, forbidding further sets. There is no way to unlock the value, so consider this function a "one way ticket".
It is recommended to crash if the value is already locked (isLocked is true). You must crash in your class' "set" functions when isLocked is true.
lock
in interface LockOneWay
xbn.util.LockOneWay
AssertException
- If isLocked is true.public final boolean isLocked()
LockOneWay
Is the value locked?
isLocked
in interface LockOneWay
xbn.util.LockOneWay
|
|||||||||
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