public class HistoryTable extends Object
Modifier and Type | Field and Description |
---|---|
ICounter[] |
a
The selected counters.
|
PeriodEnum |
basePeriod
Identifies the history to be written for each of the selected
counters by its based reporting period.
|
IHistoryEntry[][] |
data
An array of the performance counter values.
|
long |
firstTimestamp
The earliest timestamp in the selected history units for any of the
specified counters.
|
long |
lastTimestamp
The most recent timestamp in the selected history units for any of
the specified counters.
|
protected static org.apache.log4j.Logger |
log |
int |
ncols
The #of columns in the table.
|
int |
nrows
The #of rows in the table.
|
long |
period
The #of milliseconds in each unit for
units . |
String |
units
The label for the units of the history.
|
Constructor and Description |
---|
HistoryTable(ICounter[] a,
PeriodEnum basePeriod) |
Modifier and Type | Method and Description |
---|---|
int |
getFirstRowIndex(int counterIndex)
The index of the row into which the first sample for a counter falls
is given by
|
long |
getTimestamp(int row)
Return the timestamp for the row, which is the timestamp of first
sample which would be allowed into the logical slot for that row.
|
protected static final org.apache.log4j.Logger log
public final ICounter[] a
public final PeriodEnum basePeriod
public final long firstTimestamp
public final long lastTimestamp
public final int nrows
public final int ncols
public final String units
public final long period
units
.public final IHistoryEntry[][] data
firstSampleTimeIndex
)
and then examining the other counters and deciding if they have a
value for the same reporting period. If a counter has a value for the
same reporting period then the value is incorporated into that row
and the row index for that counter is advanced. Otherwise the row
index for that counter IS NOT advanced. If there is no data for a
given counter in a given row then that cell will be null
.
It is necessary to align the samples in this manner as counters are
created and destroyed over the life of the system and thus some
counters may not have data for some reporting periods.public HistoryTable(ICounter[] a, PeriodEnum basePeriod)
a
- The selected counters.basePeriod
- Identifies the history to be written for each of the
selected counters by its based reporting period.public int getFirstRowIndex(int counterIndex)
(int) (firstLogicalSlot[counterIndex] - logicalSlotOffset)
counterIndex
- The index of the counter in the array specified to the
ctor.public long getTimestamp(int row)
row
- The row.Copyright © 2006–2019 SYSTAP, LLC DBA Blazegraph. All rights reserved.