|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jamonapi.utils.NExtremeBufferHolder
com.jamonapi.NExtremeArrayBufferHolder
public class NExtremeArrayBufferHolder
Buffer used to keep the last N recent array values based on the comparator. Note the Comparator must be thread safe. It can also stored the last n recent values of ToArray objects. By using various Comparators you can determine what should stay in the buffer and what should be removed. JAMon comes with a number of buffers based on this class.
Constructor Summary | |
---|---|
NExtremeArrayBufferHolder(boolean naturalOrder,
int colToCompare)
Pass true for natural order, and false for reverse order and column number in Object[] to compare starting at 0 |
|
NExtremeArrayBufferHolder(JAMonArrayComparator comparator)
Constructor that takes a JAMonArrayComparator that can be used to determine when values should be removed from and added to the array. |
Method Summary | |
---|---|
BufferHolder |
copy()
Factory method that returns a usable copy of this object |
void |
setComparator(java.util.Comparator comparator)
Note the only valid Comparator to be passed is JAMonArrayComparator |
Methods inherited from class com.jamonapi.utils.NExtremeBufferHolder |
---|
add, compare, getCollection, getComparator, getOrderedCollection, remove, setCollection, shouldReplaceWith |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface java.util.Comparator |
---|
equals |
Constructor Detail |
---|
public NExtremeArrayBufferHolder(JAMonArrayComparator comparator)
comparator
- public NExtremeArrayBufferHolder(boolean naturalOrder, int colToCompare)
Method Detail |
---|
public void setComparator(java.util.Comparator comparator)
setComparator
in class NExtremeBufferHolder
public BufferHolder copy()
copy
in interface BufferHolder
copy
in class NExtremeBufferHolder
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |