com.h3c.of.ctl.pkt

## Class HintFactory

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

-     public class HintFactory
      extends Object

  Provides facilities for creating `Hint` instances.

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static Hint` | `createHint(HintType type)` Creates a hint with the specified type.
    `static Hint` | `createHint(HintType type, Class<? extends SequencedPacketListener> cls)` Creates a hint that describes the implementing class of a packet listener.
    `static Hint` | `createHint(int experType)` Creates an experimenter hint for the specified experimenter-defined type.
    `static Hint` | `createHint(int experType, ExperimenterHint.Payload payload)` Creates an experimenter hint for the specified experimenter-defined type and given payload.

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

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

- - ### Method Detail

    - #### createHint

          public static Hint createHint(HintType type)

      Creates a hint with the specified type. This method is used to create hint types that have no additional context data. The currently supported types are:
      - `TEST_PACKET`
      Parameters:
        `type` - the hint type
      Returns:
        the hint

    - #### createHint

          public static Hint createHint(HintType type,
                        Class<? extends SequencedPacketListener> cls)

      Creates a hint that describes the implementing class of a packet listener.
      Parameters:
        `type` - must be HintType.HANDLER
        `cls` - the packet listener class
      Returns:
        the hint

    - #### createHint

          public static Hint createHint(int experType)

      Creates an experimenter hint for the specified experimenter-defined type. Note that experimenter-defined types must be negative.
      Parameters:
        `experType` - the experimenter-defined type
      Returns:
        the experimenter hint

    - #### createHint

          public static Hint createHint(int experType,
                        ExperimenterHint.Payload payload)

      Creates an experimenter hint for the specified experimenter-defined type and given payload. Note that experimenter-defined types must be negative.
      Parameters:
        `experType` - the experimenter-defined type
        `payload` - the experimenter payload
      Returns:
        the experimenter hint

Copyright © 2014. All Rights Reserved.