Class: Is::Property::Validators::OR
- Defined in:
- lib/is/monkey/properties.rb
Direct Known Subclasses
Instance Method Summary collapse
- #===(value) ⇒ Boolean
-
#initialize(*args) ⇒ OR
constructor
A new instance of OR.
Constructor Details
#initialize(*args) ⇒ OR
Returns a new instance of OR.
277 278 279 |
# File 'lib/is/monkey/properties.rb', line 277 def initialize *args @args = args end |
Instance Method Details
#===(value) ⇒ Boolean
283 284 285 286 287 288 289 290 |
# File 'lib/is/monkey/properties.rb', line 283 def === value @args.each do |v| if v === value return true end end return false end |