Class SizeParametersImpl

java.lang.Object
dev.orne.test.rnd.params.SizeParametersImpl
All Implemented Interfaces:
GenerationParameters, SizeParameters, SizeParameters.Builder

@API(status=EXPERIMENTAL, since="0.1") public class SizeParametersImpl extends Object implements SizeParameters, SizeParameters.Builder
The basic implementation of SizeParameters.
Since:
0.1
Version:
1.0, 2022-12
Author:
(w) Iker Hernaez
  • Constructor Details

    • SizeParametersImpl

      public SizeParametersImpl()
      Empty constructor.
    • SizeParametersImpl

      public SizeParametersImpl(@NotNull @NotNull GenerationParameters copy)
      Copy constructor.
      Parameters:
      copy - The instance to copy.
  • Method Details

    • getMinSize

      public int getMinSize()
      Returns the minimum size.
      Specified by:
      getMinSize in interface SizeParameters
      Returns:
      The minimum size.
    • setMinSize

      public void setMinSize(int value)
      Sets the minimum size.
      Specified by:
      setMinSize in interface SizeParameters
      Parameters:
      value - The minimum size.
    • withMinSize

      @NotNull public @NotNull SizeParametersImpl withMinSize(int value)
      Sets the minimum size.
      Specified by:
      withMinSize in interface SizeParameters.Builder
      Parameters:
      value - The minimum size.
      Returns:
      This instance, for method chaining.
    • getMaxSize

      public int getMaxSize()
      Returns the maximum size.
      Specified by:
      getMaxSize in interface SizeParameters
      Returns:
      The maximum size.
    • setMaxSize

      public void setMaxSize(int value)
      Sets the maximum size.
      Specified by:
      setMaxSize in interface SizeParameters
      Parameters:
      value - The maximum size.
    • withMaxSize

      @NotNull public @NotNull SizeParametersImpl withMaxSize(int value)
      Sets the maximum size.
      Specified by:
      withMaxSize in interface SizeParameters.Builder
      Parameters:
      value - The maximum size.
      Returns:
      This instance, for method chaining.
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object