Class: Dry::Validation::Message
- Inherits:
-
Struct
- Object
- Struct
- Dry::Validation::Message
- Defined in:
- lib/dry/validation/error_compiler/input.rb
Instance Attribute Summary collapse
-
#predicate ⇒ Object
Returns the value of attribute predicate.
-
#rule ⇒ Object
Returns the value of attribute rule.
-
#text ⇒ Object
Returns the value of attribute text.
Instance Method Summary collapse
Instance Attribute Details
#predicate ⇒ Object
Returns the value of attribute predicate
5 6 7 |
# File 'lib/dry/validation/error_compiler/input.rb', line 5 def predicate @predicate end |
#rule ⇒ Object
Returns the value of attribute rule
5 6 7 |
# File 'lib/dry/validation/error_compiler/input.rb', line 5 def rule @rule end |
#text ⇒ Object
Returns the value of attribute text
5 6 7 |
# File 'lib/dry/validation/error_compiler/input.rb', line 5 def text @text end |
Instance Method Details
#eql?(other) ⇒ Boolean
14 15 16 |
# File 'lib/dry/validation/error_compiler/input.rb', line 14 def eql?(other) other.is_a?(String) ? text == other : super end |
#signature ⇒ Object
10 11 12 |
# File 'lib/dry/validation/error_compiler/input.rb', line 10 def signature @signature ||= [rule, predicate].hash end |
#to_s ⇒ Object
6 7 8 |
# File 'lib/dry/validation/error_compiler/input.rb', line 6 def to_s text end |