Package com.io7m.coffeepick.runtime

# Class RuntimeRepositoryDescription.Builder

java.lang.Object
com.io7m.coffeepick.runtime.RuntimeRepositoryDescription.Builder

Enclosing class:
  RuntimeRepositoryDescription

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

Builds instances of type `RuntimeRepositoryDescription`. 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
  --- | --- | ---
  `RuntimeRepositoryDescription` | `build()` | Builds a new `RuntimeRepositoryDescription`.
  `RuntimeRepositoryDescription.Builder` | `from​(RuntimeRepositoryDescriptionType instance)` | Fill a builder with attribute values from the provided `RuntimeRepositoryDescriptionType` instance.
  `RuntimeRepositoryDescription.Builder` | `putAllRuntimes​(java.util.Map<java.lang.String,​? extends RuntimeDescription> entries)` | Put all mappings from the specified map as entries to `runtimes` map.
  `RuntimeRepositoryDescription.Builder` | `putRuntimes​(java.lang.String key, RuntimeDescription value)` | Put one entry to the `runtimes` map.
  `RuntimeRepositoryDescription.Builder` | `putRuntimes​(java.util.Map.Entry<java.lang.String,​? extends RuntimeDescription> entry)` | Put one entry to the `runtimes` map.
  `RuntimeRepositoryDescription.Builder` | `setBranding​(RuntimeRepositoryBranding branding)` | Initializes the value for the `branding` attribute.
  `RuntimeRepositoryDescription.Builder` | `setId​(java.net.URI id)` | Initializes the value for the `id` attribute.
  `RuntimeRepositoryDescription.Builder` | `setRuntimes​(java.util.Map<java.lang.String,​? extends RuntimeDescription> entries)` | Sets or replaces all mappings from the specified map as entries for the `runtimes` map.
  `RuntimeRepositoryDescription.Builder` | `setUpdated​(java.time.OffsetDateTime updated)` | Initializes the optional value `updated` to updated.
  `RuntimeRepositoryDescription.Builder` | `setUpdated​(java.util.Optional<? extends java.time.OffsetDateTime> updated)` | Initializes the optional value `updated` to updated.

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

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

- ## Method Details

  - ### from

    public final RuntimeRepositoryDescription.Builder from​(RuntimeRepositoryDescriptionType instance)
    Fill a builder with attribute values from the provided `RuntimeRepositoryDescriptionType` instance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values. Collection elements and entries will be added, not replaced.
    Parameters:
      `instance` - The instance from which to copy values
    Returns:
      `this` builder for use in a chained invocation

  - ### setId

    public final RuntimeRepositoryDescription.Builder setId​(java.net.URI id)
    Initializes the value for the `id` attribute.
    Parameters:
      `id` - The value for id
    Returns:
      `this` builder for use in a chained invocation

  - ### setUpdated

    public final RuntimeRepositoryDescription.Builder setUpdated​(java.time.OffsetDateTime updated)
    Initializes the optional value `updated` to updated.
    Parameters:
      `updated` - The value for updated
    Returns:
      `this` builder for chained invocation

  - ### setUpdated

    public final RuntimeRepositoryDescription.Builder setUpdated​(java.util.Optional<? extends java.time.OffsetDateTime> updated)
    Initializes the optional value `updated` to updated.
    Parameters:
      `updated` - The value for updated
    Returns:
      `this` builder for use in a chained invocation

  - ### putRuntimes

    public final RuntimeRepositoryDescription.Builder putRuntimes​(java.lang.String key, RuntimeDescription value)
    Put one entry to the `runtimes` map.
    Parameters:
      `key` - The key in the runtimes map
      `value` - The associated value in the runtimes map
    Returns:
      `this` builder for use in a chained invocation

  - ### putRuntimes

    public final RuntimeRepositoryDescription.Builder putRuntimes​(java.util.Map.Entry<java.lang.String,​? extends RuntimeDescription> entry)
    Put one entry to the `runtimes` map. Nulls are not permitted
    Parameters:
      `entry` - The key and value entry
    Returns:
      `this` builder for use in a chained invocation

  - ### setRuntimes

    public final RuntimeRepositoryDescription.Builder setRuntimes​(java.util.Map<java.lang.String,​? extends RuntimeDescription> entries)
    Sets or replaces all mappings from the specified map as entries for the `runtimes` map. Nulls are not permitted
    Parameters:
      `entries` - The entries that will be added to the runtimes map
    Returns:
      `this` builder for use in a chained invocation

  - ### putAllRuntimes

    public final RuntimeRepositoryDescription.Builder putAllRuntimes​(java.util.Map<java.lang.String,​? extends RuntimeDescription> entries)
    Put all mappings from the specified map as entries to `runtimes` map. Nulls are not permitted
    Parameters:
      `entries` - The entries that will be added to the runtimes map
    Returns:
      `this` builder for use in a chained invocation

  - ### setBranding

    public final RuntimeRepositoryDescription.Builder setBranding​(RuntimeRepositoryBranding branding)
    Initializes the value for the `branding` attribute.
    Parameters:
      `branding` - The value for branding
    Returns:
      `this` builder for use in a chained invocation

  - ### build

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