Class: Monolens::Type::Boolean
- Inherits:
-
Object
- Object
- Monolens::Type::Boolean
- Includes:
- ErrorHandling
- Defined in:
- lib/monolens/type/boolean.rb
Class Method Summary collapse
Methods included from ErrorHandling
Class Method Details
.===(instance) ⇒ Object
12 13 14 |
# File 'lib/monolens/type/boolean.rb', line 12 def self.===(instance) instance == true || instance == false end |
.dress(instance, registry, &block) ⇒ Object
6 7 8 9 10 |
# File 'lib/monolens/type/boolean.rb', line 6 def self.dress(instance, registry, &block) fail!("Invalid Boolean `#{instance}`") unless self === instance instance end |