org.abora.white.aspire
Class PtrArrayAccumulator
java.lang.Object
|
+--org.abora.white.xpp.basic.Heaper
|
+--org.abora.white.collection.steppers.Accumulator
|
+--org.abora.white.aspire.PtrArrayAccumulator
- public class PtrArrayAccumulator
- extends Accumulator
To save array copies, this class will hand out its internal array if the size is right.
If it does so it remembers so that if new elements are introduced, a copy can be made for
further use.
|
Method Summary |
Accumulator |
copy()
Return a new Accumulator just like the current one, except that
from now on they accumulate separately |
void |
step(Heaper x)
Accumulate a new object into the Accumulator |
Heaper |
value()
Return the object that results from accumulating all those objects |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
myValues
protected PtrArray myValues
myN
protected int myN
myValuesGiven
protected boolean myValuesGiven
PtrArrayAccumulator
public PtrArrayAccumulator()
PtrArrayAccumulator
public PtrArrayAccumulator(int count)
PtrArrayAccumulator
public PtrArrayAccumulator(PtrArray values,
int n)
copy
public Accumulator copy()
- Description copied from class:
Accumulator
- Return a new Accumulator just like the current one, except that
from now on they accumulate separately
- Specified by:
copy in class Accumulator
step
public void step(Heaper x)
- Description copied from class:
Accumulator
- Accumulate a new object into the Accumulator
- Specified by:
step in class Accumulator
value
public Heaper value()
- Description copied from class:
Accumulator
- Return the object that results from accumulating all those objects
- Specified by:
value in class Accumulator
Copyright © 2003 David G Jones. All Rights Reserved.
Original Udanax-Gold - Copyright © 1979-1999 Udanax.com. All rights reserved.