Package org.opennms.netmgt.rrd.model
Class AbstractRRA
- java.lang.Object
-
- org.opennms.netmgt.rrd.model.AbstractRRA
-
-
Constructor Summary
Constructors Constructor Description AbstractRRA()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract AbstractRRA
createSingleRRA(int dsIndex)
Creates a RRA with a single data source.boolean
formatEquals(AbstractRRA rra)
Format equals.abstract boolean
formatMergeable(AbstractRRA sourceRra)
Format mergeable.java.lang.Long
getPdpPerRow()
Gets the PDP (Primary Data Points) per row.java.util.List<Row>
getRows()
Gets the rows.abstract boolean
hasAverageAsCF()
Checks for average as consolidation function.void
setPdpPerRow(java.lang.Long pdpPerRow)
Sets the PDP (Primary Data Points) per row.void
setRows(java.util.List<Row> rows)
Sets the rows.
-
-
-
Method Detail
-
createSingleRRA
protected abstract AbstractRRA createSingleRRA(int dsIndex) throws java.lang.IllegalArgumentException
Creates a RRA with a single data source.- Parameters:
dsIndex
- the RRA-DS index- Returns:
- the abstract RRA
- Throws:
java.lang.IllegalArgumentException
- the illegal argument exception
-
getPdpPerRow
public java.lang.Long getPdpPerRow()
Gets the PDP (Primary Data Points) per row.- Returns:
- the PDP (Primary Data Points) per row
-
setPdpPerRow
public void setPdpPerRow(java.lang.Long pdpPerRow)
Sets the PDP (Primary Data Points) per row.- Parameters:
pdpPerRow
- the new PDP (Primary Data Points) per row
-
getRows
public java.util.List<Row> getRows()
Gets the rows.- Returns:
- the rows
-
setRows
public void setRows(java.util.List<Row> rows)
Sets the rows.- Parameters:
rows
- the new rows
-
formatEquals
public boolean formatEquals(AbstractRRA rra)
Format equals.- Parameters:
rra
- the RRA object- Returns:
- true, if the format is equal
-
formatMergeable
public abstract boolean formatMergeable(AbstractRRA sourceRra)
Format mergeable.Two RRA can be merged if and only if the Consolidation Function and the PDP per row are the same.
The amount of rows is not strict for a merge operation.
- If the sourceRra has more rows than the current RRA, the result will be truncated by the number of rows on the current RRA.
- If the sourceRra has less rows than the current RRA, the result will have a NaN window as big as the different between the number of rows.
- Parameters:
sourceRra
- the source RRA object- Returns:
- true, if the format is mergeable
-
hasAverageAsCF
public abstract boolean hasAverageAsCF()
Checks for average as consolidation function.- Returns:
- true, if the consolidation function is AVERAGE
-
-