Interface Validation.Builder

  • Method Details

    • minLength

      Validation.Builder minLength(Integer minLength)

      The minimum number of characters a text value can contain. Applies to TEXT value type and values within a TEXT_LIST. Must be less than or equal to MaxLength.

      Parameters:
      minLength - The minimum number of characters a text value can contain. Applies to TEXT value type and values within a TEXT_LIST. Must be less than or equal to MaxLength.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • maxLength

      Validation.Builder maxLength(Integer maxLength)

      The maximum number of characters a text value can contain. Applies to TEXT value type and values within a TEXT_LIST. Must be greater than or equal to MinLength.

      Parameters:
      maxLength - The maximum number of characters a text value can contain. Applies to TEXT value type and values within a TEXT_LIST. Must be greater than or equal to MinLength.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • minValues

      Validation.Builder minValues(Integer minValues)

      The minimum number of values in a list. Must be an integer greater than or equal to 0 and less than or equal to MaxValues. Applies to all list types.

      Parameters:
      minValues - The minimum number of values in a list. Must be an integer greater than or equal to 0 and less than or equal to MaxValues. Applies to all list types.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • maxValues

      Validation.Builder maxValues(Integer maxValues)

      The maximum number of values in a list. Must be an integer greater than or equal to 0 and greater than or equal to MinValues. Applies to all list types.

      Parameters:
      maxValues - The maximum number of values in a list. Must be an integer greater than or equal to 0 and greater than or equal to MinValues. Applies to all list types.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • ignoreCase

      Validation.Builder ignoreCase(Boolean ignoreCase)

      Boolean that defaults to false. Applies to text lists and text primary attributes. When true, enforces case-insensitive uniqueness for primary attributes and allows case-insensitive lookups.

      Parameters:
      ignoreCase - Boolean that defaults to false. Applies to text lists and text primary attributes. When true, enforces case-insensitive uniqueness for primary attributes and allows case-insensitive lookups.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • minimum

      Validation.Builder minimum(Double minimum)

      The smallest inclusive numeric value for NUMBER value type. Cannot be provided when ExclusiveMinimum is also provided. Must be less than or equal to Maximum and less than ExclusiveMaximum. Applies to NUMBER and values within NUMBER_LIST.

      Parameters:
      minimum - The smallest inclusive numeric value for NUMBER value type. Cannot be provided when ExclusiveMinimum is also provided. Must be less than or equal to Maximum and less than ExclusiveMaximum. Applies to NUMBER and values within NUMBER_LIST.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • maximum

      Validation.Builder maximum(Double maximum)

      The largest inclusive numeric value for NUMBER value type. Can be provided alongside ExclusiveMaximum where both operate independently. Must be greater than or equal to Minimum and greater than ExclusiveMinimum. Applies to NUMBER and values within NUMBER_LIST.

      Parameters:
      maximum - The largest inclusive numeric value for NUMBER value type. Can be provided alongside ExclusiveMaximum where both operate independently. Must be greater than or equal to Minimum and greater than ExclusiveMinimum. Applies to NUMBER and values within NUMBER_LIST.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • exclusiveMinimum

      Validation.Builder exclusiveMinimum(Double exclusiveMinimum)

      The smallest exclusive numeric value for NUMBER value type. Can be provided alongside Minimum where both operate independently. Must be less than ExclusiveMaximum and Maximum. Applies to NUMBER and values within NUMBER_LIST.

      Parameters:
      exclusiveMinimum - The smallest exclusive numeric value for NUMBER value type. Can be provided alongside Minimum where both operate independently. Must be less than ExclusiveMaximum and Maximum. Applies to NUMBER and values within NUMBER_LIST.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • exclusiveMaximum

      Validation.Builder exclusiveMaximum(Double exclusiveMaximum)

      The largest exclusive numeric value for NUMBER value type. Can be provided alongside Maximum where both operate independently. Must be greater than ExclusiveMinimum and Minimum. Applies to NUMBER and values within NUMBER_LIST.

      Parameters:
      exclusiveMaximum - The largest exclusive numeric value for NUMBER value type. Can be provided alongside Maximum where both operate independently. Must be greater than ExclusiveMinimum and Minimum. Applies to NUMBER and values within NUMBER_LIST.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • multipleOf

      Validation.Builder multipleOf(Double multipleOf)

      Specifies that numeric values must be multiples of this number. Must be greater than 0. The result of dividing a value by this multiple must result in an integer. Applies to NUMBER and values within NUMBER_LIST.

      Parameters:
      multipleOf - Specifies that numeric values must be multiples of this number. Must be greater than 0. The result of dividing a value by this multiple must result in an integer. Applies to NUMBER and values within NUMBER_LIST.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • enumValue

      Validation.Builder enumValue(ValidationEnum enumValue)

      Defines enumeration constraints for attribute values. Can specify a list of allowed values and whether custom values are permitted beyond the enumerated list.

      Parameters:
      enumValue - Defines enumeration constraints for attribute values. Can specify a list of allowed values and whether custom values are permitted beyond the enumerated list.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • enumValue

      default Validation.Builder enumValue(Consumer<ValidationEnum.Builder> enumValue)

      Defines enumeration constraints for attribute values. Can specify a list of allowed values and whether custom values are permitted beyond the enumerated list.

      This is a convenience method that creates an instance of the ValidationEnum.Builder avoiding the need to create one manually via ValidationEnum.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to enumValue(ValidationEnum).

      Parameters:
      enumValue - a consumer that will call methods on ValidationEnum.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also: