DecimalScheme

data class DecimalScheme(var minValue: Double = DEFAULT_MIN_VALUE, var maxValue: Double = DEFAULT_MAX_VALUE, var decimalCount: Int = DEFAULT_DECIMAL_COUNT, var showTrailingZeroes: Boolean = DEFAULT_SHOW_TRAILING_ZEROES, var decimalSeparator: String = DEFAULT_DECIMAL_SEPARATOR, var groupingSeparatorEnabled: Boolean = DEFAULT_GROUPING_SEPARATOR_ENABLED, var groupingSeparator: String = DEFAULT_GROUPING_SEPARATOR, val affixDecorator: AffixDecorator = DEFAULT_AFFIX_DECORATOR, val arrayDecorator: ArrayDecorator = DEFAULT_ARRAY_DECORATOR) : Scheme(source)

Contains settings for generating random decimals.

Constructors

Link copied to clipboard
constructor(minValue: Double = DEFAULT_MIN_VALUE, maxValue: Double = DEFAULT_MAX_VALUE, decimalCount: Int = DEFAULT_DECIMAL_COUNT, showTrailingZeroes: Boolean = DEFAULT_SHOW_TRAILING_ZEROES, decimalSeparator: String = DEFAULT_DECIMAL_SEPARATOR, groupingSeparatorEnabled: Boolean = DEFAULT_GROUPING_SEPARATOR_ENABLED, groupingSeparator: String = DEFAULT_GROUPING_SEPARATOR, affixDecorator: AffixDecorator = DEFAULT_AFFIX_DECORATOR, arrayDecorator: ArrayDecorator = DEFAULT_ARRAY_DECORATOR)

Types

Link copied to clipboard
object Companion

Holds constants.

Properties

Link copied to clipboard

The affixation to apply to the generated values.

Link copied to clipboard

Settings that determine whether the output should be an array of values.

Link copied to clipboard
var decimalCount: Int

The number of decimals to display.

Link copied to clipboard
var decimalSeparator: String

The character that should separate decimals.

Link copied to clipboard
open override val decorators: List<DecoratorScheme>

Additional logic that determines how strings are generated.

Link copied to clipboard
var groupingSeparator: String

The character that should separate groups if groupingSeparatorEnabled is true.

Link copied to clipboard

true if and only if the groupingSeparator should be used to separate groups.

Link copied to clipboard
var maxValue: Double

The maximum value to be generated, inclusive.

Link copied to clipboard
var minValue: Double

The minimum value to be generated, inclusive.

Link copied to clipboard
open override val name: String

The name of the scheme as shown to the user.

Link copied to clipboard
var showTrailingZeroes: Boolean

Whether to include trailing zeroes in the decimals.

Link copied to clipboard
open override val typeIcon: TypeIcon

The icon signifying the type of data represented by this scheme, ignoring its decorators, or null if this scheme does not represent any kind of data, as is the case for DecoratorSchemes.

Functions

Link copied to clipboard
open override fun deepCopy(retainUuid: Boolean): DecimalScheme

Returns a deep copy, retaining the uuid if and only if retainUuid is true.

Link copied to clipboard
open override fun doValidate(): String?

Validates the state, and indicates whether and why it is invalid.