Class NxmHeader
java.lang.Object
org.opendaylight.openflowjava.nx.codec.match.NxmHeader
Nxm header.
- Author:
- msunal
-
Constructor Summary
ConstructorDescriptionNxmHeader
(int nxmField, boolean hasMask, int length, long experimenterId) Build a experimenter header from it's constituent fields.NxmHeader
(int oxmClass, int nxmField, boolean hasMask, int length) Build a non experimenter header from it's constituent fields.NxmHeader
(long header) Builds aNxmHeader
from along
representation.NxmHeader
(org.opendaylight.yangtools.yang.common.Uint64 header) Builds aNxmHeader
from aBigInteger
representation, that is, one for whichBigInteger.longValue()
produces a valid long representation. -
Method Summary
Modifier and TypeMethodDescriptionboolean
long
int
int
int
int
hashCode()
boolean
static boolean
isExperimenter
(org.opendaylight.yangtools.yang.common.Uint64 uint) boolean
long
toLong()
Returns thelong
representation of the header.toString()
org.opendaylight.yangtools.yang.common.Uint64
toUint64()
Returns theUint64
representation of the header.
-
Constructor Details
-
NxmHeader
public NxmHeader(org.opendaylight.yangtools.yang.common.Uint64 header) Builds aNxmHeader
from aBigInteger
representation, that is, one for whichBigInteger.longValue()
produces a valid long representation.- Parameters:
header
- the header asBigInteger
.- See Also:
-
NxmHeader
public NxmHeader(long header) Builds aNxmHeader
from along
representation. For non experimenter, the 4 byte header are the least significant of the long, being the other 4 most significant bytes 0. For experimenter, the full 8 byte constitute the header, being the 4 least significant the experimenter id.- Parameters:
header
- the header as along
.
-
NxmHeader
public NxmHeader(int oxmClass, int nxmField, boolean hasMask, int length) Build a non experimenter header from it's constituent fields.- Parameters:
oxmClass
- the OXM class.nxmField
- the NXM field.hasMask
- the hasMask field.length
- the length field.
-
NxmHeader
public NxmHeader(int nxmField, boolean hasMask, int length, long experimenterId) Build a experimenter header from it's constituent fields. The OXM class will be set to 0xFFFF.- Parameters:
nxmField
- the NXM field.hasMask
- the hasMask field.length
- the length field.experimenterId
- the esperimenter id field.
-
-
Method Details
-
toUint64
public org.opendaylight.yangtools.yang.common.Uint64 toUint64()Returns theUint64
representation of the header.- Returns:
- the header.
- See Also:
-
toLong
public long toLong()Returns thelong
representation of the header.- Returns:
- the header.
- See Also:
-
getOxmClass
public int getOxmClass() -
getNxmField
public int getNxmField() -
isHasMask
public boolean isHasMask() -
getLength
public int getLength() -
getExperimenterId
public long getExperimenterId() -
isExperimenter
public boolean isExperimenter() -
isExperimenter
public static boolean isExperimenter(org.opendaylight.yangtools.yang.common.Uint64 uint) -
hashCode
public int hashCode() -
equals
-
toString
-