# Class MNativeWorkspaceConfiguration

java.lang.Object
com.io7m.montarre.api.natives.MNativeWorkspaceConfiguration

All Implemented Interfaces:
  `MNativeWorkspaceConfigurationType`

public final class MNativeWorkspaceConfiguration extends Object implements MNativeWorkspaceConfigurationType
A workspace configuration.

- ## Nested Class Summary

  Nested Classes
  Modifier and Type
  Class
  Description
  `static final class`
  `MNativeWorkspaceConfiguration.Builder`
  Builds instances of type `MNativeWorkspaceConfiguration`.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `Path`
  `baseDirectory()`
  `static MNativeWorkspaceConfiguration.Builder`
  `builder()`
  Creates a builder for `MNativeWorkspaceConfiguration`.
  `static MNativeWorkspaceConfiguration`
  `copyOf(MNativeWorkspaceConfigurationType instance)`
  Creates an immutable copy of a `MNativeWorkspaceConfigurationType` value.
  `boolean`
  `equals(Object another)`
  This instance is equal to all instances of `MNativeWorkspaceConfiguration` that have equal attribute values.
  `int`
  `hashCode()`
  Computes a hash code from attributes: `baseDirectory`, `javaRuntimeDownloadFormat`, `javaRuntimeDownloadURI`, `javaRuntimeDownloadSHA256`.
  `MArchiveFormat`
  `javaRuntimeDownloadFormat()`
  `String`
  `javaRuntimeDownloadSHA256()`
  `URI`
  `javaRuntimeDownloadURI()`
  `String`
  `toString()`
  Prints the immutable value `MNativeWorkspaceConfiguration` with attribute values.
  `final MNativeWorkspaceConfiguration`
  `withBaseDirectory(Path value)`
  Copy the current immutable object by setting a value for the `baseDirectory` attribute.
  `final MNativeWorkspaceConfiguration`
  `withJavaRuntimeDownloadFormat(MArchiveFormat value)`
  Copy the current immutable object by setting a value for the `javaRuntimeDownloadFormat` attribute.
  `final MNativeWorkspaceConfiguration`
  `withJavaRuntimeDownloadSHA256(String value)`
  Copy the current immutable object by setting a value for the `javaRuntimeDownloadSHA256` attribute.
  `final MNativeWorkspaceConfiguration`
  `withJavaRuntimeDownloadURI(URI value)`
  Copy the current immutable object by setting a value for the `javaRuntimeDownloadURI` attribute.

  ### Methods inherited from class Object

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

- ## Method Details

  - ### baseDirectory

    public Path baseDirectory()
    Specified by:
      `baseDirectory` in interface `MNativeWorkspaceConfigurationType`
    Returns:
      The base workspace directory

  - ### javaRuntimeDownloadFormat

    public MArchiveFormat javaRuntimeDownloadFormat()
    Specified by:
      `javaRuntimeDownloadFormat` in interface `MNativeWorkspaceConfigurationType`
    Returns:
      The Java runtime archive format

  - ### javaRuntimeDownloadURI

    public URI javaRuntimeDownloadURI()
    Specified by:
      `javaRuntimeDownloadURI` in interface `MNativeWorkspaceConfigurationType`
    Returns:
      The Java runtime archive URI

  - ### javaRuntimeDownloadSHA256

    public String javaRuntimeDownloadSHA256()
    Specified by:
      `javaRuntimeDownloadSHA256` in interface `MNativeWorkspaceConfigurationType`
    Returns:
      The Java runtime archive checksum

  - ### withBaseDirectory

    public final MNativeWorkspaceConfiguration withBaseDirectory(Path value)
    Copy the current immutable object by setting a value for the `baseDirectory` attribute. A shallow reference equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for baseDirectory
    Returns:
      A modified copy or the `this` object

  - ### withJavaRuntimeDownloadFormat

    public final MNativeWorkspaceConfiguration withJavaRuntimeDownloadFormat(MArchiveFormat value)
    Copy the current immutable object by setting a value for the `javaRuntimeDownloadFormat` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for javaRuntimeDownloadFormat
    Returns:
      A modified copy or the `this` object

  - ### withJavaRuntimeDownloadURI

    public final MNativeWorkspaceConfiguration withJavaRuntimeDownloadURI(URI value)
    Copy the current immutable object by setting a value for the `javaRuntimeDownloadURI` attribute. A shallow reference equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for javaRuntimeDownloadURI
    Returns:
      A modified copy or the `this` object

  - ### withJavaRuntimeDownloadSHA256

    public final MNativeWorkspaceConfiguration withJavaRuntimeDownloadSHA256(String value)
    Copy the current immutable object by setting a value for the `javaRuntimeDownloadSHA256` attribute. An equals check used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for javaRuntimeDownloadSHA256
    Returns:
      A modified copy or the `this` object

  - ### equals

    public boolean equals(Object another)
    This instance is equal to all instances of `MNativeWorkspaceConfiguration` 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: `baseDirectory`, `javaRuntimeDownloadFormat`, `javaRuntimeDownloadURI`, `javaRuntimeDownloadSHA256`.
    Overrides:
      `hashCode` in class `Object`
    Returns:
      hashCode value

  - ### toString

    public String toString()
    Prints the immutable value `MNativeWorkspaceConfiguration` with attribute values.
    Overrides:
      `toString` in class `Object`
    Returns:
      A string representation of the value

  - ### copyOf

    public static MNativeWorkspaceConfiguration copyOf(MNativeWorkspaceConfigurationType instance)
    Creates an immutable copy of a `MNativeWorkspaceConfigurationType` 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 MNativeWorkspaceConfiguration instance

  - ### builder

    public static MNativeWorkspaceConfiguration.Builder builder()
    Creates a builder for `MNativeWorkspaceConfiguration`.

        MNativeWorkspaceConfiguration.builder()
           .setBaseDirectory(java.nio.file.Path) // required baseDirectory
           .setJavaRuntimeDownloadFormat(com.io7m.montarre.api.MArchiveFormat) // required javaRuntimeDownloadFormat
           .setJavaRuntimeDownloadURI(java.net.URI) // required javaRuntimeDownloadURI
           .setJavaRuntimeDownloadSHA256(String) // required javaRuntimeDownloadSHA256
           .build();

    Returns:
      A new MNativeWorkspaceConfiguration builder