Class ZoneIdGenerator
java.lang.Object
org.instancio.internal.generator.AbstractGenerator<ZoneId>
org.instancio.internal.generator.time.ZoneIdGenerator
- All Implemented Interfaces:
Generator<ZoneId>,GeneratorSpec<ZoneId>,NullableGeneratorSpec<ZoneId>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the public API method name of the generator spec.protected ZoneIdtryGenerateNonNull(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
-
ZoneIdGenerator
-
-
Method Details
-
apiMethod
Description copied from class:AbstractGeneratorReturns the public API method name of the generator spec. The returned name is used for reporting validation errors.- Specified by:
apiMethodin classAbstractGenerator<ZoneId>- Returns:
- spec name if defined, or
nullotherwise
-
tryGenerateNonNull
Description copied from class:AbstractGeneratorMakes the best effort to return a non-null value. However, in certain cases this method will produce anull.- Specified by:
tryGenerateNonNullin classAbstractGenerator<ZoneId>- Parameters:
random- for generating the value- Returns:
- generated value, either a null or non-null
-