Class AtomicBooleanGenerator
java.lang.Object
org.instancio.internal.generator.AbstractGenerator<AtomicBoolean>
org.instancio.internal.generator.util.concurrent.atomic.AtomicBooleanGenerator
- All Implemented Interfaces:
Generator<AtomicBoolean>
,GeneratorSpec<AtomicBoolean>
,NullableGeneratorSpec<AtomicBoolean>
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionReturns the public API method name of the generator spec.protected AtomicBoolean
tryGenerateNonNull
(Random random) Makes the best effort to return a non-null value.Methods inherited from class org.instancio.internal.generator.AbstractGenerator
generate, getContext, hints, isNullable, nullable, nullable
-
Constructor Details
-
AtomicBooleanGenerator
-
-
Method Details
-
apiMethod
Description copied from class:AbstractGenerator
Returns the public API method name of the generator spec. The returned name is used for reporting validation errors.- Specified by:
apiMethod
in classAbstractGenerator<AtomicBoolean>
- Returns:
- spec name if defined, or
null
otherwise
-
tryGenerateNonNull
Description copied from class:AbstractGenerator
Makes the best effort to return a non-null value. However, in certain cases this method will produce anull
.- Specified by:
tryGenerateNonNull
in classAbstractGenerator<AtomicBoolean>
- Parameters:
random
- for generating the value- Returns:
- generated value, either a null or non-null
-