Class: Literal::Decorator
Constant Summary
Constants included from Attributable
Constants included from Monads
Monads::Either, Monads::Left, Monads::Maybe, Monads::Nothing, Monads::Result, Monads::Right, Monads::Some
Instance Method Summary collapse
- #__getobj__ ⇒ Object
- #__setobj__(object) ⇒ Object
- #method_missing(method) ⇒ Object
- #respond_to_missing?(method, include_private = false) ⇒ Boolean
Methods included from Attributes
generate_literal_initializer, generate_literal_reader, generate_literal_writer
Methods included from Attributable
#attribute, #define_literal_methods, #literal_attributes, #literal_extension
Methods included from Types
#_Any, #_Array, #_Boolean, #_Callable, #_Class, #_Constraint, #_Descendant, #_Enumerable, #_Falsy, #_Float, #_Frozen, #_Hash, #_Integer, #_Interface, #_Intersection, #_Is, #_JSONData, #_Lambda, #_Map, #_Never, #_Nilable, #_Not, #_Procable, #_Range, #_Set, #_Shape, #_String, #_Symbol, #_Truthy, #_Tuple, #_Union, #_Void
Methods included from Monads
#Either, #Left, #Maybe, #Result, #Right, #Some, #Success
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method) ⇒ Object
6 7 8 |
# File 'lib/literal/decorator.rb', line 6 def method_missing(method, ...) @__object__.public_send(method, ...) end |
Instance Method Details
#__getobj__ ⇒ Object
14 15 16 |
# File 'lib/literal/decorator.rb', line 14 def __getobj__ @__object__ end |
#__setobj__(object) ⇒ Object
18 19 20 |
# File 'lib/literal/decorator.rb', line 18 def __setobj__(object) @__object__ = object end |
#respond_to_missing?(method, include_private = false) ⇒ Boolean
10 11 12 |
# File 'lib/literal/decorator.rb', line 10 def respond_to_missing?(method, include_private = false) @__object__.respond_to?(method, include_private) end |