Package org.instancio.generator.specs
Interface LocalDateTimeSpec
- All Superinterfaces:
GeneratorSpec<LocalDateTime>,NullableGeneratorSpec<LocalDateTime>,TemporalGeneratorSpec<LocalDateTime>,TemporalSpec<LocalDateTime>,ValueSpec<LocalDateTime>
- All Known Implementing Classes:
LocalDateTimeGenerator
Spec for generating
LocalDateTime values.- Since:
- 2.6.0
-
Method Summary
Modifier and TypeMethodDescriptionfuture()Generate a value in the future.nullable()Specifies that anullvalue can be generatedpast()Generate a value in the past.range(LocalDateTime start, LocalDateTime end) Generate a value within the given range.
-
Method Details
-
past
LocalDateTimeSpec past()Description copied from interface:TemporalGeneratorSpecGenerate a value in the past.- Specified by:
pastin interfaceTemporalGeneratorSpec<LocalDateTime>- Specified by:
pastin interfaceTemporalSpec<LocalDateTime>- Returns:
- spec builder
-
future
LocalDateTimeSpec future()Description copied from interface:TemporalGeneratorSpecGenerate a value in the future.- Specified by:
futurein interfaceTemporalGeneratorSpec<LocalDateTime>- Specified by:
futurein interfaceTemporalSpec<LocalDateTime>- Returns:
- spec builder
-
range
Description copied from interface:TemporalGeneratorSpecGenerate a value within the given range.- Specified by:
rangein interfaceTemporalGeneratorSpec<LocalDateTime>- Specified by:
rangein interfaceTemporalSpec<LocalDateTime>- Parameters:
start- lower bound (inclusive)end- upper bound (inclusive)- Returns:
- spec builder
-
nullable
LocalDateTimeSpec nullable()Specifies that anullvalue can be generated- Specified by:
nullablein interfaceNullableGeneratorSpec<LocalDateTime>- Specified by:
nullablein interfaceTemporalGeneratorSpec<LocalDateTime>- Specified by:
nullablein interfaceTemporalSpec<LocalDateTime>- Specified by:
nullablein interfaceValueSpec<LocalDateTime>- Returns:
- spec builder reference
- Since:
- 2.7.0
-