com.h3c.of.ctl.pkt

## Class AbstractHint

- java.lang.Object
- - com.h3c.of.ctl.pkt.AbstractHint

- All Implemented Interfaces:
    Hint
  Direct Known Subclasses:
    ExperimenterHint, HandlerHint, TypeOnlyHint

      public abstract class AbstractHint
      extends Object
      implements Hint

  An abstract base implementation of `Hint` that handles the hint type. Subclasses must provide the payload implementation.

- - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `AbstractHint(int encodedType)` Constructs the hint.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `int` | `getEncodedType()` Returns the hint type encoded as an integer.
    `HintType` | `getType()` Returns the hint type, if it is a standard type.
    `String` | `toString()`

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

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

- - ### Constructor Detail

    - #### AbstractHint

          protected AbstractHint(int encodedType)

      Constructs the hint.
      Parameters:
        `encodedType` - the hint type encoded as an integer

  - ### Method Detail

    - #### getEncodedType

          public int getEncodedType()

      Description copied from interface: `Hint`
      Returns the hint type encoded as an integer.
      Specified by:
        `getEncodedType` in interface `Hint`
      Returns:
        the encoded type

    - #### getType

          public HintType getType()

      Description copied from interface: `Hint`
      Returns the hint type, if it is a standard type. Non-standard types will return null, and will need to be differentiated via `Hint.getEncodedType()`.
      Specified by:
        `getType` in interface `Hint`
      Returns:
        the hint type

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

Copyright © 2014. All Rights Reserved.