com.h3c.of.lib.instr

## Class Instruction

- java.lang.Object
- - com.h3c.of.lib.OpenflowStructure
  - - com.h3c.of.lib.instr.Instruction

- All Implemented Interfaces:
    Structure
  Direct Known Subclasses:
    InstrApplyActions, InstrClearActions, InstrExperimenter, InstrGotoTable, InstrHeader, InstrMeter, InstrMutableAction, InstrWriteActions, InstrWriteMetadata

      public abstract class Instruction
      extends OpenflowStructure

  Represents a Flow instruction.

- - ### Field Summary

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

      `version`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `InstructionType` | `getInstructionType()` Returns the Instruction type.
    `int` | `getTotalLength()` Returns the total length of the instruction in bytes.
    `String` | `toDebugString()` Returns a string representation useful for debugging.
    `String` | `toDebugString(int indent)` Returns a string representation useful for debugging.
    `String` | `toString()`

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

      `getVersion, hex, hex, validate`

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

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

- - ### Method Detail

    - #### getTotalLength

          public int getTotalLength()

      Returns the total length of the instruction in bytes.
      Returns:
        the length of the instruction

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `OpenflowStructure`

    - #### toDebugString

          public String toDebugString(int indent)

      Returns a string representation useful for debugging. This default implementation delegates to `toString()`, but subclasses are free to override this behavior.
      Parameters:
        `indent` - the number of spaces with which to prefix each line
      Returns:
        a (possibly multi-line) string representation of this instruction

    - #### toDebugString

          public String toDebugString()

      Returns a string representation useful for debugging. This default implementation delegates to `toString()`, but subclasses are free to override this behavior.
      Specified by:
        `toDebugString` in interface `Structure`
      Overrides:
        `toDebugString` in class `OpenflowStructure`
      Returns:
        a (possibly multi-line) string representation of this instruction

    - #### getInstructionType

          public InstructionType getInstructionType()

      Returns the Instruction type.
      Returns:
        the instruction type

Copyright © 2014. All Rights Reserved.