Class: Sukima::Constraints::Format
- Inherits:
-
Object
- Object
- Sukima::Constraints::Format
- Defined in:
- lib/sukima/constraints.rb
Instance Method Summary collapse
Instance Method Details
#call(pattern, value) ⇒ Object
31 32 33 |
# File 'lib/sukima/constraints.rb', line 31 def call(pattern, value) "should match #{pattern.source}" unless value.is_a?(String) && pattern.match?(value) end |