Class: Monolens::Type::String
- Inherits:
-
Object
- Object
- Monolens::Type::String
- Extended by:
- ErrorHandling
- Defined in:
- lib/monolens/type/string.rb
Class Method Summary collapse
Methods included from ErrorHandling
Class Method Details
.===(instance) ⇒ Object
7 8 9 |
# File 'lib/monolens/type/string.rb', line 7 def self.===(instance) instance.is_a?(::String) end |
.dress(instance, registry, &block) ⇒ Object
11 12 13 14 15 |
# File 'lib/monolens/type/string.rb', line 11 def self.dress(instance, registry, &block) fail!("Invalid string #{instance}", &block) unless self === instance instance end |