com.h3c.of.lib.mp

## Class MBodyMutableFlowStatsRequest

- java.lang.Object
- - com.h3c.of.lib.OpenflowStructure
  - - com.h3c.of.lib.mp.MBodyFlowStatsRequest
    - - com.h3c.of.lib.mp.MBodyMutableFlowStatsRequest

- All Implemented Interfaces:
    MultipartBody, MutableObject, MutableStructure, Structure

      public class MBodyMutableFlowStatsRequest
      extends MBodyFlowStatsRequest
      implements MutableStructure

  Mutable subclass of `MBodyFlowStatsRequest`.

- - ### Field Summary

    - ### Fields inherited from class com.h3c.of.lib.OpenflowStructure

      `version`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `MBodyMutableFlowStatsRequest(ProtocolVersion pv)` Constructs a mutable multipart body FLOW request type.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `MBodyMutableFlowStatsRequest` | `cookie(long cookie)` Sets the requirement that matching flow entries contain this cookie value; since 1.1.
    `MBodyMutableFlowStatsRequest` | `cookieMask(long cookieMask)` Sets the mask used to restrict the cookie bits that must match; Since 1.1.
    `MBodyMutableFlowStatsRequest` | `match(Match match)` Describes the fields to match; Since 1.0.
    `MBodyMutableFlowStatsRequest` | `outGroup(GroupId outGroup)` Sets the requirement that matching flow entries include this as an output group; Since 1.1.
    `MBodyMutableFlowStatsRequest` | `outPort(BigPortNumber outPort)` Sets the requirement that matching flow entries include this as an output port; Since 1.0.
    `MBodyMutableFlowStatsRequest` | `tableId(TableId tableId)` Sets the ID of the table to read; Since 1.0.
    `OpenflowStructure` | `toImmutable()` Returns an immutable instance of this structure.
    `String` | `toString()`
    `boolean` | `writable()` Returns true if this mutable object is still writable.

    - ### Methods inherited from class com.h3c.of.lib.mp.MBodyFlowStatsRequest

      `getCookie, getCookieMask, getMatch, getOutGroup, getOutPort, getTableId, getTotalLength, toDebugString, validate`

    - ### Methods inherited from class com.h3c.of.lib.OpenflowStructure

      `getVersion, hex, hex`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

    - ### Methods inherited from interface com.h3c.of.lib.Structure

      `getVersion, toDebugString`

- - ### Constructor Detail

    - #### MBodyMutableFlowStatsRequest

          public MBodyMutableFlowStatsRequest(ProtocolVersion pv)

      Constructs a mutable multipart body FLOW request type.

      Note that a freshly constructed instance has the following default values:

      - table ID: `TableId.ALL`
      - out port: `Port.ANY`
      - out group: `GroupId.ANY`
      - cookie: `0`
      - cookie mask: `0`
      - match: `null`

      A valid `Match` must be `set` for this request to be valid.

      Parameters:
        `pv` - the protocol version

  - ### Method Detail

    - #### toImmutable

          public OpenflowStructure toImmutable()

      Description copied from interface: `MutableStructure`
      Returns an immutable instance of this structure. In essence, converts this structure to be read-only.

      It is expected that the reference to this mutable structure will be dropped. Note that all method calls invoked on a `MutableStructure` after `toImmutable()` has been invoked will result in an `InvalidMutableException` being thrown.

      Specified by:
        `toImmutable` in interface `MutableStructure`
      Returns:
        an immutable instance of this structure.

    - #### writable

          public boolean writable()

      Description copied from interface: `MutableObject`
      Returns true if this mutable object is still writable. That is, the `#toImmutable()` method (defined on a sub-interface) has not yet been invoked.
      Specified by:
        `writable` in interface `MutableObject`
      Returns:
        true if this mutable object is still writable

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `MBodyFlowStatsRequest`

    - #### tableId

          public MBodyMutableFlowStatsRequest tableId(TableId tableId)

      Sets the ID of the table to read; Since 1.0.
      Parameters:
        `tableId` - the table ID
      Returns:
        self, for chaining
      Throws:
        `InvalidMutableException` - if this instance is no longer writable
        `NullPointerException` - if tableId is null

    - #### outPort

          public MBodyMutableFlowStatsRequest outPort(BigPortNumber outPort)

      Sets the requirement that matching flow entries include this as an output port; Since 1.0. A value of `Port.ANY` indicates no restriction.

      Note that in 1.0, port numbers are u16.

      Parameters:
        `outPort` - the out port to match
      Returns:
        self, for chaining
      Throws:
        `InvalidMutableException` - if this instance is no longer writable
        `NullPointerException` - if outPort is null
        `IllegalArgumentException` - if the port number is invalid

    - #### outGroup

          public MBodyMutableFlowStatsRequest outGroup(GroupId outGroup)

      Sets the requirement that matching flow entries include this as an output group; Since 1.1. A value of `GroupId.ANY` indicates no restriction.
      Parameters:
        `outGroup` - the out group to match
      Returns:
        self, for chaining
      Throws:
        `InvalidMutableException` - if this instance is no longer writable
        `NullPointerException` - if outGroup is null

    - #### cookie

          public MBodyMutableFlowStatsRequest cookie(long cookie)

      Sets the requirement that matching flow entries contain this cookie value; since 1.1.
      Parameters:
        `cookie` - the cookie value
      Returns:
        self, for chaining
      Throws:
        `InvalidMutableException` - if this instance is no longer writable
      See Also:
        `cookieMask(long)`

    - #### cookieMask

          public MBodyMutableFlowStatsRequest cookieMask(long cookieMask)

      Sets the mask used to restrict the cookie bits that must match; Since 1.1.
      Parameters:
        `cookieMask` - the cookie mask value
      Returns:
        self, for chaining
      Throws:
        `InvalidMutableException` - if this instance is no longer writable
      See Also:
        `cookie(long)`

    - #### match

          public MBodyMutableFlowStatsRequest match(Match match)

      Describes the fields to match; Since 1.0.
      Parameters:
        `match` - the match descriptor
      Returns:
        self, for chaining
      Throws:
        `InvalidMutableException` - if this instance is no longer writable
        `NullPointerException` - if match is null
        `IllegalArgumentException` - if match is mutable
        `VersionMismatchException` - if match is not the same version as this instance

Copyright © 2014. All Rights Reserved.