com.h3c.util.pkt

## Class DhcpV6.Builder

- java.lang.Object
- - com.h3c.util.pkt.DhcpV6.Builder

- Enclosing class:
    DhcpV6

      public static class DhcpV6.Builder
      extends Object

  Builder (mutable) used to create a new protocol instances.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `DhcpV6.Builder()` Create a new builder using the defaults:
    `DhcpV6.Builder(DhcpV6 dhcp)` Copy constructor builder initialized from the passed in protocol.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `DhcpV6` | `build()` Creates a new protocol instance from this builder.
    `DhcpV6.Builder` | `msgType(DhcpV6.MessageType msgType)` Sets the message type.
    `DhcpV6.Builder` | `options(DhcpOptionV6[] options)` Sets the options array.
    `DhcpV6.Builder` | `transId(int transId)` Sets the transaction ID.

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

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

- - ### Constructor Detail

    - #### DhcpV6.Builder

          public DhcpV6.Builder()

      Create a new builder using the defaults:

           msgType = SOLICIT
           options = NO_OPTIONS

    - #### DhcpV6.Builder

          public DhcpV6.Builder(DhcpV6 dhcp)

      Copy constructor builder initialized from the passed in protocol.
      Parameters:
        `dhcp` - builder is initialed from this protocol's data

  - ### Method Detail

    - #### build

          public DhcpV6 build()

      Creates a new protocol instance from this builder.
      Returns:
        the new protocol instance

    - #### msgType

          public DhcpV6.Builder msgType(DhcpV6.MessageType msgType)

      Sets the message type.
      Parameters:
        `msgType` - message type enumeration
      Returns:
        this instance

    - #### transId

          public DhcpV6.Builder transId(int transId)

      Sets the transaction ID.
      Parameters:
        `transId` - transaction ID
      Returns:
        this instance

    - #### options

          public DhcpV6.Builder options(DhcpOptionV6[] options)

      Sets the options array.
      Parameters:
        `options` - array of options
      Returns:
        this instance

Copyright © 2014. All Rights Reserved.