public class BufferList extends Object implements DetailData
It uses a bufferHolder to determine whether a value should be added and another one removed when the buffer is full. For example the value could only be added if the new value is greater than the smallest member of the BufferList. Simply implement the BufferHolder interface to implement your desired rules.
Constructor and Description |
---|
BufferList(String[] header)
Constructor that takes the header of the structure of the rows that are stored.
|
BufferList(String[] header,
BufferHolder bufferHolder)
Pass in the header and bufferHolder to be used
|
BufferList(String[] header,
int bufferSize)
Use a FIFOBuffer and specify its header and size
|
BufferList(String[] header,
int bufferSize,
BufferHolder bufferHolder)
Specify the header, bufferSize and BufferHolder to be used in the BufferList
|
Modifier and Type | Method and Description |
---|---|
void |
addRow(Object obj) |
void |
addRow(Object[] row)
Add a row to be held in the buffer.
|
BufferList |
copy() |
void |
disable()
Disable monitoring
|
void |
enable()
Enable monitoring
|
int |
getBufferSize()
Get the number of Exceptions that can be stored in the buffer before the oldest entries must
be removed.
|
List |
getCollection()
Return the underlying Collection that holds the BufferList
|
Object[][] |
getData()
Deprecated.
|
DetailData |
getDetailData() |
String[] |
getHeader()
Get the header that can be used to display the buffer.
|
int |
getRowCount()
Return the rows in the BufferList
|
boolean |
hasData()
Return true if the bufferList has data
|
boolean |
isEmpty()
Return true if the bufferList is empty
|
boolean |
isEnabled()
Returns true if MonProxy is enabled.
|
void |
reset()
Reset BufferList.
|
void |
resetBuffer()
Remove all Exceptions from the buffer.
|
void |
setBufferHolder(BufferHolder bufferHolder) |
void |
setBufferSize(int newBufferSize)
Set the number of Exceptions that can be stored in the buffer before the oldest entries must
be removed.
|
public BufferList(String[] header)
header
- public BufferList(String[] header, BufferHolder bufferHolder)
public BufferList(String[] header, int bufferSize)
public BufferList(String[] header, int bufferSize, BufferHolder bufferHolder)
public int getBufferSize()
public void setBufferHolder(BufferHolder bufferHolder)
public void setBufferSize(int newBufferSize)
public void resetBuffer()
public boolean isEmpty()
public boolean hasData()
public int getRowCount()
public List getCollection()
public boolean isEnabled()
public void enable()
public void disable()
public void reset()
public String[] getHeader()
getHeader
in interface DetailData
@Deprecated public Object[][] getData()
getData
in interface DetailData
public DetailData getDetailData()
public void addRow(Object[] row)
public void addRow(Object obj)
public BufferList copy()
Copyright © 2015. All rights reserved.