com.io7m.smfj.bytebuffer

## Class SMFByteBufferPackedAttribute

- java.lang.Object
- - com.io7m.smfj.bytebuffer.SMFByteBufferPackedAttribute

- All Implemented Interfaces:
    SMFByteBufferPackedAttributeType, Comparable<SMFByteBufferPackedAttributeType>

      @Generated(value={"Immutables.generator","SMFByteBufferPackedAttributeType"})
      public final class SMFByteBufferPackedAttribute
      extends Object
      implements SMFByteBufferPackedAttributeType

  A packed attribute.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `SMFByteBufferPackedAttribute.Builder` Builds instances of type `SMFByteBufferPackedAttribute`.

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `SMFAttribute` | `attribute()`
    `static SMFByteBufferPackedAttribute.Builder` | `builder()` Creates a builder for `SMFByteBufferPackedAttribute`.
    `static SMFByteBufferPackedAttribute` | `copyOf(SMFByteBufferPackedAttributeType instance)` Creates an immutable copy of a `SMFByteBufferPackedAttributeType` value.
    `boolean` | `equals(Object another)` This instance is equal to all instances of `SMFByteBufferPackedAttribute` that have equal attribute values.
    `int` | `hashCode()` Computes a hash code from attributes: `attribute`, `order`, `offsetOctets`.
    `static SMFByteBufferPackedAttribute` | `of(SMFAttribute attribute, int order, int offsetOctets)` Construct a new immutable `SMFByteBufferPackedAttribute` instance.
    `int` | `offsetOctets()` A specification of the offset in octets from the start of each vertex at which this attribute's data will be written.
    `int` | `order()`
    `String` | `toString()` Prints the immutable value `SMFByteBufferPackedAttribute` with attribute values.
    `SMFByteBufferPackedAttribute` | `withAttribute(SMFAttribute value)` Copy the current immutable object by setting a value for the `attribute` attribute.
    `SMFByteBufferPackedAttribute` | `withOffsetOctets(int value)` Copy the current immutable object by setting a value for the `offsetOctets` attribute.
    `SMFByteBufferPackedAttribute` | `withOrder(int value)` Copy the current immutable object by setting a value for the `order` attribute.

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

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

    - ### Methods inherited from interface com.io7m.smfj.bytebuffer.SMFByteBufferPackedAttributeType

      `compareTo`

- - ### Method Detail

    - #### attribute

          public SMFAttribute attribute()

      Specified by:
        `attribute` in interface `SMFByteBufferPackedAttributeType`
      Returns:
        The real underlying attribute

    - #### order

          public int order()

      Specified by:
        `order` in interface `SMFByteBufferPackedAttributeType`
      Returns:
        The order in which the attribute appears

    - #### offsetOctets

          public int offsetOctets()

      A specification of the offset in octets from the start of each vertex at which this attribute's data will be written.
      Specified by:
        `offsetOctets` in interface `SMFByteBufferPackedAttributeType`
      Returns:
        The offset in octets

    - #### withAttribute

          public final SMFByteBufferPackedAttribute withAttribute(SMFAttribute value)

      Copy the current immutable object by setting a value for the `attribute` attribute. A shallow reference equality check is used to prevent copying of the same value by returning `this`.
      Parameters:
        `value` - A new value for attribute
      Returns:
        A modified copy of the `this` object

    - #### withOrder

          public final SMFByteBufferPackedAttribute withOrder(int value)

      Copy the current immutable object by setting a value for the `order` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
      Parameters:
        `value` - A new value for order
      Returns:
        A modified copy of the `this` object

    - #### withOffsetOctets

          public final SMFByteBufferPackedAttribute withOffsetOctets(int value)

      Copy the current immutable object by setting a value for the `offsetOctets` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
      Parameters:
        `value` - A new value for offsetOctets
      Returns:
        A modified copy of the `this` object

    - #### equals

          public boolean equals(Object another)

      This instance is equal to all instances of `SMFByteBufferPackedAttribute` that have equal attribute values.
      Overrides:
        `equals` in class `Object`
      Returns:
        `true` if `this` is equal to `another` instance

    - #### hashCode

          public int hashCode()

      Computes a hash code from attributes: `attribute`, `order`, `offsetOctets`.
      Overrides:
        `hashCode` in class `Object`
      Returns:
        hashCode value

    - #### toString

          public String toString()

      Prints the immutable value `SMFByteBufferPackedAttribute` with attribute values.
      Overrides:
        `toString` in class `Object`
      Returns:
        A string representation of the value

    - #### of

          public static SMFByteBufferPackedAttribute of(SMFAttribute attribute,
                                                        int order,
                                                        int offsetOctets)

      Construct a new immutable `SMFByteBufferPackedAttribute` instance.
      Parameters:
        `attribute` - The value for the `attribute` attribute
        `order` - The value for the `order` attribute
        `offsetOctets` - The value for the `offsetOctets` attribute
      Returns:
        An immutable SMFByteBufferPackedAttribute instance

    - #### copyOf

          public static SMFByteBufferPackedAttribute copyOf(SMFByteBufferPackedAttributeType instance)

      Creates an immutable copy of a `SMFByteBufferPackedAttributeType` value. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.
      Parameters:
        `instance` - The instance to copy
      Returns:
        A copied immutable SMFByteBufferPackedAttribute instance

    - #### builder

          public static SMFByteBufferPackedAttribute.Builder builder()

      Creates a builder for `SMFByteBufferPackedAttribute`.
      Returns:
        A new SMFByteBufferPackedAttribute builder

Copyright © 2017 <code@io7m.com> http://io7m.com