Package com.io7m.waxmill.machines

# Class WXMSectorSizes.Builder

java.lang.Object
com.io7m.waxmill.machines.WXMSectorSizes.Builder

Enclosing class:
  WXMSectorSizes

    public static final class WXMSectorSizes.Builder
    extends java.lang.Object

Builds instances of type `WXMSectorSizes`. Initialize attributes and then invoke the `build()` method to create an immutable instance.

`Builder` is not thread-safe and generally should not be stored in a field or collection, but instead used immediately to create instances.

- ## Method Summary

  Modifier and Type | Method | Description
  --- | --- | ---
  `WXMSectorSizes` | `build()` | Builds a new `WXMSectorSizes`.
  `WXMSectorSizes.Builder` | `from​(WXMDeviceType.WXMSectorSizesType instance)` | Fill a builder with attribute values from the provided `WXMSectorSizesType` instance.
  `WXMSectorSizes.Builder` | `setLogical​(java.math.BigInteger logical)` | Initializes the value for the `logical` attribute.
  `WXMSectorSizes.Builder` | `setPhysical​(java.math.BigInteger physical)` | Initializes the value for the `physical` attribute.

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

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

- ## Method Details

  - ### from

    public final WXMSectorSizes.Builder from​(WXMDeviceType.WXMSectorSizesType instance)
    Fill a builder with attribute values from the provided `WXMSectorSizesType` instance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values.
    Parameters:
      `instance` - The instance from which to copy values
    Returns:
      `this` builder for use in a chained invocation

  - ### setLogical

    public final WXMSectorSizes.Builder setLogical​(java.math.BigInteger logical)
    Initializes the value for the `logical` attribute.
    Parameters:
      `logical` - The value for logical
    Returns:
      `this` builder for use in a chained invocation

  - ### setPhysical

    public final WXMSectorSizes.Builder setPhysical​(java.math.BigInteger physical)
    Initializes the value for the `physical` attribute.

    If not set, this attribute will have a default value as returned by the initializer of `physical`.

    Parameters:
      `physical` - The value for physical
    Returns:
      `this` builder for use in a chained invocation

  - ### build

    public WXMSectorSizes build()
    Builds a new `WXMSectorSizes`.
    Returns:
      An immutable instance of WXMSectorSizes
    Throws:
      `java.lang.IllegalStateException` - if any required attributes are missing