Class ImmutableInfectivityProfileCSV

java.lang.Object
io.github.ai4ci.output.ImmutableInfectivityProfileCSV
All Implemented Interfaces:
CSVWriter.Writeable, CommonCSV.Model, InfectivityProfileCSV

@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable @CheckReturnValue public final class ImmutableInfectivityProfileCSV extends Object implements InfectivityProfileCSV
Immutable implementation of InfectivityProfileCSV.

Use the builder to create immutable instances: ImmutableInfectivityProfileCSV.builder().

  • Method Details

    • getModelName

      public String getModelName()
      Specified by:
      getModelName in interface CommonCSV.Model
      Returns:
      The value of the modelName attribute
    • getExperimentName

      public String getExperimentName()
      Specified by:
      getExperimentName in interface CommonCSV.Model
      Returns:
      The value of the experimentName attribute
    • getTau

      public int getTau()
      Specified by:
      getTau in interface InfectivityProfileCSV
      Returns:
      The value of the tau attribute
    • getProbability

      public double getProbability()
      Specified by:
      getProbability in interface InfectivityProfileCSV
      Returns:
      The value of the probability attribute
    • withModelName

      public final ImmutableInfectivityProfileCSV withModelName(String value)
      Copy the current immutable object by setting a value for the modelName attribute. An equals check used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for modelName
      Returns:
      A modified copy of the this object
    • withExperimentName

      public final ImmutableInfectivityProfileCSV withExperimentName(String value)
      Copy the current immutable object by setting a value for the experimentName attribute. An equals check used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for experimentName
      Returns:
      A modified copy of the this object
    • withTau

      public final ImmutableInfectivityProfileCSV withTau(int value)
      Copy the current immutable object by setting a value for the tau attribute. A value equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for tau
      Returns:
      A modified copy of the this object
    • withProbability

      public final ImmutableInfectivityProfileCSV withProbability(double value)
      Copy the current immutable object by setting a value for the probability attribute. A value strict bits equality used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for probability
      Returns:
      A modified copy of the this object
    • equals

      public boolean equals(@Nullable Object another)
      This instance is equal to all instances of ImmutableInfectivityProfileCSV 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: modelName, experimentName, tau, probability.
      Overrides:
      hashCode in class Object
      Returns:
      hashCode value
    • toString

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

      public static ImmutableInfectivityProfileCSV copyOf(InfectivityProfileCSV instance)
      Creates an immutable copy of a InfectivityProfileCSV 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 InfectivityProfileCSV instance
    • toBuilder

      Creates a builder for ImmutableInfectivityProfileCSV.prefilled with attibute values of this instance to easily create modified copies.
      Returns:
      A new ImmutableInfectivityProfileCSV builder with attributes of this instance
    • builder

      public static ImmutableInfectivityProfileCSV.Builder builder()
      Creates a builder for ImmutableInfectivityProfileCSV.
       ImmutableInfectivityProfileCSV.builder()
          .setModelName(String) // required modelName
          .setExperimentName(String) // required experimentName
          .setTau(int) // required tau
          .setProbability(double) // required probability
          .build();
       
      Returns:
      A new ImmutableInfectivityProfileCSV builder