Class: Code::Object::Nothing
Constant Summary
Constants inherited
from Code::Object
NUMBER_CLASSES
Instance Attribute Summary
#methods, #raw
Instance Method Summary
collapse
code_new, #code_new, maybe, #name, repeat, |
#<=>, #==, #as_json, #blank?, #call, #code_and, #code_as_json, #code_blank?, #code_compare, #code_deep_duplicate, #code_different, #code_duplicate, #code_equal, #code_exclamation_mark, #code_exclusive_range, #code_falsy?, code_fetch, #code_fetch, code_get, #code_get, #code_greater, #code_greater_or_equal, #code_inclusive_range, #code_less, #code_less_or_equal, #code_methods, #code_name, #code_nothing?, #code_or, #code_presence, #code_presence_in, #code_present?, #code_self, code_set, #code_set, #code_something?, #code_strict_different, #code_strict_equal, #code_to_boolean, #code_to_class, #code_to_date, #code_to_decimal, #code_to_dictionary, #code_to_duration, #code_to_integer, #code_to_json, #code_to_list, #code_to_nothing, #code_to_parameter, #code_to_range, #code_to_time, #code_truthy?, #eql?, #falsy?, #hash, #inspect, #multi_fetch, #sig, #something?, #succ, #to_code, #to_i, #to_json, #to_s
Constructor Details
#initialize(*_args, **_kargs, &_block) ⇒ Nothing
6
7
8
|
# File 'lib/code/object/nothing.rb', line 6
def initialize(*_args, **_kargs, &_block)
self.raw = nil
end
|
Instance Method Details
#code_inspect ⇒ Object
26
27
28
|
# File 'lib/code/object/nothing.rb', line 26
def code_inspect
String.new("nothing")
end
|
#code_to_string ⇒ Object
22
23
24
|
# File 'lib/code/object/nothing.rb', line 22
def code_to_string
String.new
end
|
18
19
20
|
# File 'lib/code/object/nothing.rb', line 18
def nothing?
true
end
|
14
15
16
|
# File 'lib/code/object/nothing.rb', line 14
def present?
false
end
|
10
11
12
|
# File 'lib/code/object/nothing.rb', line 10
def truthy?
false
end
|