Class SqlTimeGenerator.Builder

java.lang.Object
io.bloviate.gen.AbstractBuilder<Time>
io.bloviate.gen.SqlTimeGenerator.Builder
All Implemented Interfaces:
Builder<Time>
Enclosing class:
SqlTimeGenerator

public static class SqlTimeGenerator.Builder extends AbstractBuilder<Time>
Builder for SqlTimeGenerator instances.
  • Constructor Details

    • Builder

      public Builder(RandomGenerator random)
      Constructs a new builder.
      Parameters:
      random - the seeded random generator backing the produced generator
  • Method Details

    • start

      public SqlTimeGenerator.Builder start(Time start)
      Sets the inclusive lower bound of the generated range.
      Parameters:
      start - the earliest possible time, inclusive. Defaults to the epoch.
      Returns:
      this builder, for chaining
    • end

      public SqlTimeGenerator.Builder end(Time end)
      Sets the exclusive upper bound of the generated range.
      Parameters:
      end - the time one millisecond past the latest possible value, exclusive. Defaults to AbstractBuilder.DEFAULT_REFERENCE plus 100 hours.
      Returns:
      this builder, for chaining
    • build

      public SqlTimeGenerator build()
      Description copied from interface: Builder
      Builds and returns a configured data generator.
      Returns:
      a new DataGenerator configured with the builder's settings