Package org.onlab.packet
Class IGMPMembership
- java.lang.Object
-
- org.onlab.packet.IGMPGroup
-
- org.onlab.packet.IGMPMembership
-
public class IGMPMembership extends IGMPGroup
-
-
Field Summary
Fields Modifier and Type Field Description static byteALLOW_NEW_SOURCESprotected byte[]auxDataprotected byteauxDataLengthstatic byteBLOCK_OLD_SOURCESstatic byteCHANGE_TO_EXCLUDE_MODEstatic byteCHANGE_TO_INCLUDE_MODEstatic byteMODE_IS_EXCLUDEstatic byteMODE_IS_INCLUDEprotected byterecordType
-
Constructor Summary
Constructors Constructor Description IGMPMembership()Default constructor.IGMPMembership(Ip4Address gaddr)Constructor initialized with a multicast group address.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IGMPGroupdeserialize(java.nio.ByteBuffer bb)Deserialize the IGMP Membership report packet.booleanequals(java.lang.Object obj)bytegetRecordType()Gets the IGMP record type.inthashCode()byte[]serialize(java.nio.ByteBuffer bb)Serialize this Membership Report.voidsetRecordType(byte type)Sets the IGMP record type.-
Methods inherited from class org.onlab.packet.IGMPGroup
addSource, getAuxInfo, getGaddr, getSources, toString
-
-
-
-
Field Detail
-
MODE_IS_INCLUDE
public static final byte MODE_IS_INCLUDE
- See Also:
- Constant Field Values
-
MODE_IS_EXCLUDE
public static final byte MODE_IS_EXCLUDE
- See Also:
- Constant Field Values
-
CHANGE_TO_INCLUDE_MODE
public static final byte CHANGE_TO_INCLUDE_MODE
- See Also:
- Constant Field Values
-
CHANGE_TO_EXCLUDE_MODE
public static final byte CHANGE_TO_EXCLUDE_MODE
- See Also:
- Constant Field Values
-
ALLOW_NEW_SOURCES
public static final byte ALLOW_NEW_SOURCES
- See Also:
- Constant Field Values
-
BLOCK_OLD_SOURCES
public static final byte BLOCK_OLD_SOURCES
- See Also:
- Constant Field Values
-
recordType
protected byte recordType
-
auxDataLength
protected byte auxDataLength
-
auxData
protected byte[] auxData
-
-
Constructor Detail
-
IGMPMembership
public IGMPMembership(Ip4Address gaddr)
Constructor initialized with a multicast group address.- Parameters:
gaddr- A multicast group address.
-
IGMPMembership
public IGMPMembership()
Default constructor.
-
-
Method Detail
-
getRecordType
public byte getRecordType()
Gets the IGMP record type.- Returns:
- record type
-
setRecordType
public void setRecordType(byte type)
Sets the IGMP record type.- Parameters:
type- A multicast record type, like MODE_IS_INCLUDE or MODE_IS_EXCLUDE.
-
serialize
public byte[] serialize(java.nio.ByteBuffer bb)
Serialize this Membership Report.
-
deserialize
public IGMPGroup deserialize(java.nio.ByteBuffer bb) throws DeserializationException
Deserialize the IGMP Membership report packet.- Specified by:
deserializein classIGMPGroup- Parameters:
bb- the ByteBuffer wrapping the serialized message. The position of the ByteBuffer should be pointing at the head of either message type.- Returns:
- IGMP Group
- Throws:
DeserializationException- if deserialization fails
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
-