Package io.github.ai4ci.output
Class ImmutableOutbreakHistoryCSV.Builder
java.lang.Object
io.github.ai4ci.output.ImmutableOutbreakHistoryCSV.Builder
- Enclosing class:
- ImmutableOutbreakHistoryCSV
Builds instances of type
ImmutableOutbreakHistoryCSV
.
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 TypeMethodDescriptionbuild()
Builds a newImmutableOutbreakHistoryCSV
.from
(CommonCSV.Execution instance) Fill a builder with attribute values from the providedio.github.ai4ci.output.CommonCSV.Execution
instance.from
(CommonCSV.Model instance) Fill a builder with attribute values from the providedio.github.ai4ci.output.CommonCSV.Model
instance.from
(CommonCSV.State instance) Fill a builder with attribute values from the providedio.github.ai4ci.output.CommonCSV.State
instance.from
(OutbreakHistoryCSV instance) Fill a builder with attribute values from the providedio.github.ai4ci.output.OutbreakHistoryCSV
instance.setCurrentTestNegativesBySampleDate
(long currentTestNegativesBySampleDate) Initializes the value for thecurrentTestNegativesBySampleDate
attribute.setCurrentTestPositivesBySampleDate
(long currentTestPositivesBySampleDate) Initializes the value for thecurrentTestPositivesBySampleDate
attribute.setExperimentName
(String experimentName) Initializes the value for theexperimentName
attribute.setExperimentReplica
(int experimentReplica) Initializes the value for theexperimentReplica
attribute.setModelName
(String modelName) Initializes the value for themodelName
attribute.setModelReplica
(int modelReplica) Initializes the value for themodelReplica
attribute.setObservationTime
(int observationTime) Initializes the value for theobservationTime
attribute.setTime
(int time) Initializes the value for thetime
attribute.
-
Method Details
-
from
@CanIgnoreReturnValue public final ImmutableOutbreakHistoryCSV.Builder from(CommonCSV.Execution instance) Fill a builder with attribute values from the providedio.github.ai4ci.output.CommonCSV.Execution
instance.- Parameters:
instance
- The instance from which to copy values- Returns:
this
builder for use in a chained invocation
-
from
@CanIgnoreReturnValue public final ImmutableOutbreakHistoryCSV.Builder from(OutbreakHistoryCSV instance) Fill a builder with attribute values from the providedio.github.ai4ci.output.OutbreakHistoryCSV
instance.- Parameters:
instance
- The instance from which to copy values- Returns:
this
builder for use in a chained invocation
-
from
@CanIgnoreReturnValue public final ImmutableOutbreakHistoryCSV.Builder from(CommonCSV.State instance) Fill a builder with attribute values from the providedio.github.ai4ci.output.CommonCSV.State
instance.- Parameters:
instance
- The instance from which to copy values- Returns:
this
builder for use in a chained invocation
-
from
@CanIgnoreReturnValue public final ImmutableOutbreakHistoryCSV.Builder from(CommonCSV.Model instance) Fill a builder with attribute values from the providedio.github.ai4ci.output.CommonCSV.Model
instance.- Parameters:
instance
- The instance from which to copy values- Returns:
this
builder for use in a chained invocation
-
setModelName
@CanIgnoreReturnValue public final ImmutableOutbreakHistoryCSV.Builder setModelName(String modelName) Initializes the value for themodelName
attribute.- Parameters:
modelName
- The value for modelName- Returns:
this
builder for use in a chained invocation
-
setExperimentName
@CanIgnoreReturnValue public final ImmutableOutbreakHistoryCSV.Builder setExperimentName(String experimentName) Initializes the value for theexperimentName
attribute.- Parameters:
experimentName
- The value for experimentName- Returns:
this
builder for use in a chained invocation
-
setModelReplica
@CanIgnoreReturnValue public final ImmutableOutbreakHistoryCSV.Builder setModelReplica(int modelReplica) Initializes the value for themodelReplica
attribute.- Parameters:
modelReplica
- The value for modelReplica- Returns:
this
builder for use in a chained invocation
-
setExperimentReplica
@CanIgnoreReturnValue public final ImmutableOutbreakHistoryCSV.Builder setExperimentReplica(int experimentReplica) Initializes the value for theexperimentReplica
attribute.- Parameters:
experimentReplica
- The value for experimentReplica- Returns:
this
builder for use in a chained invocation
-
setTime
Initializes the value for thetime
attribute.- Parameters:
time
- The value for time- Returns:
this
builder for use in a chained invocation
-
setObservationTime
@CanIgnoreReturnValue public final ImmutableOutbreakHistoryCSV.Builder setObservationTime(int observationTime) Initializes the value for theobservationTime
attribute.- Parameters:
observationTime
- The value for observationTime- Returns:
this
builder for use in a chained invocation
-
setCurrentTestPositivesBySampleDate
@CanIgnoreReturnValue public final ImmutableOutbreakHistoryCSV.Builder setCurrentTestPositivesBySampleDate(long currentTestPositivesBySampleDate) Initializes the value for thecurrentTestPositivesBySampleDate
attribute.- Parameters:
currentTestPositivesBySampleDate
- The value for currentTestPositivesBySampleDate- Returns:
this
builder for use in a chained invocation
-
setCurrentTestNegativesBySampleDate
@CanIgnoreReturnValue public final ImmutableOutbreakHistoryCSV.Builder setCurrentTestNegativesBySampleDate(long currentTestNegativesBySampleDate) Initializes the value for thecurrentTestNegativesBySampleDate
attribute.- Parameters:
currentTestNegativesBySampleDate
- The value for currentTestNegativesBySampleDate- Returns:
this
builder for use in a chained invocation
-
build
Builds a newImmutableOutbreakHistoryCSV
.- Returns:
- An immutable instance of OutbreakHistoryCSV
- Throws:
IllegalStateException
- if any required attributes are missing
-