Class PeriodGenerator
java.lang.Object
org.instancio.internal.generator.AbstractGenerator<Period>
org.instancio.internal.generator.time.PeriodGenerator
- All Implemented Interfaces:
Generator<Period>
,GeneratorSpec<Period>
,PeriodGeneratorSpec
-
Constructor Summary
-
Method Summary
Methods inherited from class org.instancio.internal.generator.AbstractGenerator
getContext, hints
-
Constructor Details
-
PeriodGenerator
-
-
Method Details
-
days
Description copied from interface:PeriodGeneratorSpec
Generate number ofPeriod
days in the given range.- Specified by:
days
in interfacePeriodGeneratorSpec
- Parameters:
min
- minimum number of days (inclusive)max
- maximum number of days (inclusive)- Returns:
- spec builder
-
months
Description copied from interface:PeriodGeneratorSpec
Generate number ofPeriod
months in the given range.- Specified by:
months
in interfacePeriodGeneratorSpec
- Parameters:
min
- minimum number of months (inclusive)max
- maximum number of months (inclusive)- Returns:
- spec builder
-
years
Description copied from interface:PeriodGeneratorSpec
Generate number ofPeriod
years in the given range.- Specified by:
years
in interfacePeriodGeneratorSpec
- Parameters:
min
- minimum number of years (inclusive)max
- maximum number of years (inclusive)- Returns:
- spec builder
-
generate
Description copied from interface:Generator
Returns a generated value.If this method produces random data, the data needs to be generated using the provided
Random
instance. This ensures generated values are reproducible for a given seed value.
-