@cowwoc/requirements - v4.0.12
    Preparing search index...

    Class ValidationFailures

    A collection of validation failures.

    Index

    Constructors

    Properties

    EMPTY: ValidationFailures = ...

    A collection that does not contain any failures.

    Methods

    • Returns the error for the validation failures, if any.

      1. Returns `null` if no validation has failed.
      2. Returns `MultipleFailuresError` if there were multiple failures.
      3. Returns `Throwable` if there was one failure.

      Returns null | Error

      the error or null if no validation has failed

    • Returns the validation failure messages.

      Returns string[]

      an empty list if the validation was successful

    • Checks if any validation has failed.

      Returns boolean

      false if at least one validation has failed

    • Throws an error if a validation failed; otherwise, returns true.

      Returns boolean

      true if the validation passed

      RangeError if a method precondition was violated

      AssertionError if a class invariant or method postcondition was violated

      MultipleFailuresError if more than one validation failed. This error contains a list of the failures