Package org.onosproject.net.pi.runtime
Class PiCloneSessionEntry
- java.lang.Object
-
- org.onosproject.net.pi.runtime.PiCloneSessionEntry
-
- All Implemented Interfaces:
PiEntity,PiPreEntry
@Beta public final class PiCloneSessionEntry extends java.lang.Object implements PiPreEntry
Representation of a clone session entry of a protocol-independent packet replication engine (PRE).
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classPiCloneSessionEntry.BuilderBuilder of PI clone session entries.
-
Field Summary
Fields Modifier and Type Field Description static intDEFAULT_CLASS_OF_SERVICEstatic intDO_NOT_TRUNCATE
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static PiCloneSessionEntry.Builderbuilder()Returns a new builder of clone session entries.intclassOfService()Returns the class of service associated to the replicas produced by this clone session.booleanequals(java.lang.Object obj)PiCloneSessionEntryHandlehandle(DeviceId deviceId)Returns a handle for this PI entity and the given device ID.inthashCode()intmaxPacketLengthBytes()Returns the maximum length in bytes of cloned packets.PiEntityTypepiEntityType()Returns the type of this entity.PiPreEntryTypepreEntryType()Returns the type of this PRE entry.java.util.Set<PiPreReplica>replicas()Returns the packet replicas provided by this clone session.intsessionId()Returns the identifier of this clone session, unique in the scope of a PRE instance.java.lang.StringtoString()
-
-
-
Field Detail
-
DEFAULT_CLASS_OF_SERVICE
public static final int DEFAULT_CLASS_OF_SERVICE
- See Also:
- Constant Field Values
-
DO_NOT_TRUNCATE
public static final int DO_NOT_TRUNCATE
- See Also:
- Constant Field Values
-
-
Method Detail
-
sessionId
public int sessionId()
Returns the identifier of this clone session, unique in the scope of a PRE instance.- Returns:
- clone session ID
-
replicas
public java.util.Set<PiPreReplica> replicas()
Returns the packet replicas provided by this clone session.- Returns:
- packet replicas
-
classOfService
public int classOfService()
Returns the class of service associated to the replicas produced by this clone session.- Returns:
- class of service
-
maxPacketLengthBytes
public int maxPacketLengthBytes()
Returns the maximum length in bytes of cloned packets. If a larger packet is cloned, then the PRE is expected to truncate clones to the given size. 0 means that no truncation on the clone(s) will be performed.- Returns:
- maximum length in bytes of clones packets
-
piEntityType
public PiEntityType piEntityType()
Description copied from interface:PiEntityReturns the type of this entity.- Specified by:
piEntityTypein interfacePiEntity- Returns:
- entity type
-
preEntryType
public PiPreEntryType preEntryType()
Description copied from interface:PiPreEntryReturns the type of this PRE entry.- Specified by:
preEntryTypein interfacePiPreEntry- Returns:
- PRE entry type
-
handle
public PiCloneSessionEntryHandle handle(DeviceId deviceId)
Description copied from interface:PiEntityReturns a handle for this PI entity and the given device ID.
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
builder
public static PiCloneSessionEntry.Builder builder()
Returns a new builder of clone session entries.- Returns:
- builder
-
-