Package org.instancio.generator.specs
Interface LocalTimeSpec
- All Superinterfaces:
AsGeneratorSpec<LocalTime>,GeneratorSpec<LocalTime>,LocalTimeGeneratorSpec,NullableGeneratorSpec<LocalTime>,Supplier<LocalTime>,TemporalGeneratorSpec<LocalTime>,TemporalSpec<LocalTime>,TruncatableTemporalGeneratorSpec<LocalTime>,ValueSpec<LocalTime>
public interface LocalTimeSpec
extends TemporalSpec<LocalTime>, LocalTimeGeneratorSpec, TruncatableTemporalGeneratorSpec<LocalTime>
Spec for generating
LocalTime values.- Since:
- 2.6.0
-
Method Summary
Modifier and TypeMethodDescriptionfuture()Generate a value in the future.Specifies the upper bound.Specifies the lower bound.nullable()Specifies that anullvalue can be generatedpast()Generate a value in the past.Generate a value within the given range.truncatedTo(TemporalUnit unit) Truncates generated values to the specified unit.Methods inherited from interface org.instancio.generator.specs.AsGeneratorSpec
as, asString
-
Method Details
-
past
Generate a value in the past.- Specified by:
pastin interfaceLocalTimeGeneratorSpec- Specified by:
pastin interfaceTemporalGeneratorSpec<LocalTime>- Specified by:
pastin interfaceTemporalSpec<LocalTime>- Returns:
- spec builder
-
future
Generate a value in the future.- Specified by:
futurein interfaceLocalTimeGeneratorSpec- Specified by:
futurein interfaceTemporalGeneratorSpec<LocalTime>- Specified by:
futurein interfaceTemporalSpec<LocalTime>- Returns:
- spec builder
-
min
Specifies the lower bound.- Specified by:
minin interfaceTemporalGeneratorSpec<LocalTime>- Specified by:
minin interfaceTemporalSpec<LocalTime>- Parameters:
min- lower bound (inclusive)- Returns:
- spec builder
- Since:
- 4.6.0
- See Also:
-
max
Specifies the upper bound.- Specified by:
maxin interfaceTemporalGeneratorSpec<LocalTime>- Specified by:
maxin interfaceTemporalSpec<LocalTime>- Parameters:
max- upper bound (inclusive)- Returns:
- spec builder
- Since:
- 4.6.0
- See Also:
-
range
Generate a value within the given range.- Specified by:
rangein interfaceLocalTimeGeneratorSpec- Specified by:
rangein interfaceTemporalGeneratorSpec<LocalTime>- Specified by:
rangein interfaceTemporalSpec<LocalTime>- Parameters:
min- lower bound (inclusive)max- upper bound (inclusive)- Returns:
- spec builder
- See Also:
-
truncatedTo
Truncates generated values to the specified unit.- Specified by:
truncatedToin interfaceLocalTimeGeneratorSpec- Specified by:
truncatedToin interfaceTruncatableTemporalGeneratorSpec<LocalTime>- Parameters:
unit- to truncate to- Returns:
- spec builder
- Since:
- 4.2.0
-
nullable
LocalTimeSpec nullable()Specifies that anullvalue can be generated- Specified by:
nullablein interfaceLocalTimeGeneratorSpec- Specified by:
nullablein interfaceNullableGeneratorSpec<LocalTime>- Specified by:
nullablein interfaceTemporalGeneratorSpec<LocalTime>- Specified by:
nullablein interfaceTemporalSpec<LocalTime>- Specified by:
nullablein interfaceValueSpec<LocalTime>- Returns:
- spec builder reference
- Since:
- 2.7.0
-