Class: Ramda::Internal::Functors::Const
- Inherits:
-
Object
- Object
- Ramda::Internal::Functors::Const
- Defined in:
- lib/ramda/internal/functors.rb
Overview
‘const` is a functor that effectively ignores the function given to `map`.
Instance Attribute Summary collapse
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Class Method Summary collapse
Instance Method Summary collapse
Instance Attribute Details
#value ⇒ Object (readonly)
Returns the value of attribute value.
6 7 8 |
# File 'lib/ramda/internal/functors.rb', line 6 def value @value end |
Class Method Details
.of(x) ⇒ Object
8 9 10 |
# File 'lib/ramda/internal/functors.rb', line 8 def self.of(x) new(x) end |
Instance Method Details
#map ⇒ Object
12 13 14 |
# File 'lib/ramda/internal/functors.rb', line 12 def map(*) Const.of(@value) end |