java.lang.Object
org.opendaylight.openflowjava.nx.codec.match.NxmHeader

public final class NxmHeader extends Object
Nxm header.
Author:
msunal
  • Constructor Summary Link icon

    Constructors
    Constructor
    Description
    NxmHeader(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 a NxmHeader from a long representation.
    NxmHeader(org.opendaylight.yangtools.yang.common.Uint64 header)
    Builds a NxmHeader from a BigInteger representation, that is, one for which BigInteger.longValue() produces a valid long representation.
  • Method Summary Link icon

    Modifier and Type
    Method
    Description
    boolean
     
    long
     
    int
     
    int
     
    int
     
    int
     
    boolean
     
    static boolean
    isExperimenter(org.opendaylight.yangtools.yang.common.Uint64 uint)
     
    boolean
     
    long
    Returns the long representation of the header.
     
    org.opendaylight.yangtools.yang.common.Uint64
    Returns the Uint64 representation of the header.

    Methods inherited from class java.lang.Object Link icon

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details Link icon

    • NxmHeader Link icon

      public NxmHeader(org.opendaylight.yangtools.yang.common.Uint64 header)
      Builds a NxmHeader from a BigInteger representation, that is, one for which BigInteger.longValue() produces a valid long representation.
      Parameters:
      header - the header as BigInteger.
      See Also:
    • NxmHeader Link icon

      public NxmHeader(long header)
      Builds a NxmHeader from a long 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 a long.
    • NxmHeader Link icon

      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 Link icon

      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 Link icon

    • toUint64 Link icon

      public org.opendaylight.yangtools.yang.common.Uint64 toUint64()
      Returns the Uint64 representation of the header.
      Returns:
      the header.
      See Also:
    • toLong Link icon

      public long toLong()
      Returns the long representation of the header.
      Returns:
      the header.
      See Also:
    • getOxmClass Link icon

      public int getOxmClass()
    • getNxmField Link icon

      public int getNxmField()
    • isHasMask Link icon

      public boolean isHasMask()
    • getLength Link icon

      public int getLength()
    • getExperimenterId Link icon

      public long getExperimenterId()
    • isExperimenter Link icon

      public boolean isExperimenter()
    • isExperimenter Link icon

      public static boolean isExperimenter(org.opendaylight.yangtools.yang.common.Uint64 uint)
    • hashCode Link icon

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals Link icon

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toString Link icon

      public String toString()
      Overrides:
      toString in class Object