Class: Nothing
Instance Method Summary collapse
-
#initialize ⇒ Nothing
constructor
A new instance of Nothing.
- #nothing? ⇒ Boolean
- #something? ⇒ Boolean
- #to_s ⇒ Object
- #try ⇒ Object
Constructor Details
#initialize ⇒ Nothing
Returns a new instance of Nothing.
6 7 |
# File 'lib/just_maybe/nothing.rb', line 6 def initialize end |
Instance Method Details
#nothing? ⇒ Boolean
9 10 11 |
# File 'lib/just_maybe/nothing.rb', line 9 def nothing? true end |
#something? ⇒ Boolean
13 14 15 |
# File 'lib/just_maybe/nothing.rb', line 13 def something? false end |
#to_s ⇒ Object
20 21 22 |
# File 'lib/just_maybe/nothing.rb', line 20 def to_s "Nothing" end |
#try ⇒ Object
17 18 |
# File 'lib/just_maybe/nothing.rb', line 17 def try end |