Package org.opennms.netmgt.flows.api
Class TrafficSummary<T>
- java.lang.Object
-
- org.opennms.netmgt.flows.api.TrafficSummary<T>
-
public class TrafficSummary<T> extends Object
Total bytes in/out related to some entity.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
TrafficSummary.Builder<T>
-
Constructor Summary
Constructors Constructor Description TrafficSummary(TrafficSummary.Builder<T> builder)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static <T> TrafficSummary.Builder<T>
builder()
int
ecnInfo()
Combines the two booleansisCongestionEncountered()
andisNonEcnCapableTransport()
that capture information about encountered ecn values into a single integer.boolean
equals(Object o)
static <T> TrafficSummary.Builder<T>
from(T entity)
long
getBytesIn()
BytesInOut
getBytesInOut()
long
getBytesOut()
T
getEntity()
int
hashCode()
boolean
isCongestionEncountered()
boolean
isNonEcnCapableTransport()
String
toString()
-
-
-
Constructor Detail
-
TrafficSummary
public TrafficSummary(TrafficSummary.Builder<T> builder)
-
-
Method Detail
-
getEntity
public T getEntity()
-
getBytesIn
public long getBytesIn()
-
getBytesOut
public long getBytesOut()
-
getBytesInOut
public BytesInOut getBytesInOut()
-
isCongestionEncountered
public boolean isCongestionEncountered()
-
isNonEcnCapableTransport
public boolean isNonEcnCapableTransport()
-
ecnInfo
public int ecnInfo()
Combines the two booleansisCongestionEncountered()
andisNonEcnCapableTransport()
that capture information about encountered ecn values into a single integer. The resulting integers are:- 0: !nonEcnCapableTransport && !congestionEncountered
- 1: nonEcnCapableTransport && !congestionEncountered
- 2: !nonEcnCapableTransport && congestionEncountered
- 3: nonEcnCapableTransport && congestionEncountered
-
builder
public static <T> TrafficSummary.Builder<T> builder()
-
from
public static <T> TrafficSummary.Builder<T> from(T entity)
-
-