Class Batch
java.lang.Object
com.suse.salt.netapi.datatypes.Batch
A class representing the batch parameter. Salt uses a string for the batch parameter,
but it accept strings representing both exact numerals and percents, so this class
encapsulates the creation and usage of the batch strings, adding safety.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classHelper class for building a Batch. -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic BatchasAmount(int value) Construct a Batch from a value representing an exact amount of itemsstatic BatchasPercent(int value) Construct a Batch from a value representing a percentstatic Batch.BatchBuildercustom()Returns a BatchBuilder for instantiating a custom Batch.getBatch()getDelay()toString()
-
Field Details
-
batch
-
delay
-
presencePingTimeout
-
presencePingGatherJobTimeout
-
-
Constructor Details
-
Batch
-
-
Method Details
-
toString
-
getBatch
-
getDelay
-
getPresencePingTimeout
-
getPresencePingGatherJobTimeout
-
getParams
-
asPercent
Construct a Batch from a value representing a percent- Parameters:
value- the percent, which must be greater than 0 and less than or equal to 100- Returns:
- the Batch
-
asAmount
Construct a Batch from a value representing an exact amount of items- Parameters:
value- the exact amount of items, which must be greater than 0- Returns:
- the Batch
-
custom
Returns a BatchBuilder for instantiating a custom Batch.- Returns:
- a BatchBuilder instance.
-