module Athena::Validator::Violation::ConstraintViolationListInterface

Overview

A wrapper type around an Array(AVD::ConstraintViolationInterface).

Direct including types

Defined in:

violation/constraint_violation_list_interface.cr

Instance Method Summary

Instance Method Detail

abstract def add(violation : AVD::Violation::ConstraintViolationInterface) : Nil #

Adds the provided violation to self.


[View source]
abstract def add(violations : AVD::Violation::ConstraintViolationListInterface) : Nil #

Adds each of the provided violations to self.


[View source]
abstract def has?(index : Int) : Bool #

Returns true if a violation exists at the provided index, otherwise false.


[View source]
abstract def remove(index : Int) : Nil #

Returns the violation at the provided index.


[View source]
abstract def set(index : Int, violation : AVD::Violation::ConstraintViolationInterface) : Nil #

Sets the provided violation at the provided index.


[View source]
abstract def size : Int #

Returns the number of violations in self.


[View source]
abstract def to_json(builder : JSON::Builder) : Nil #

Returns a JSON representation of self.


[View source]
abstract def to_s(io : IO) : Nil #

Returns a string representation of self.


[View source]