Class: Object

Inherits:
BasicObject
Defined in:
lib/json_logic/truthy.rb

Overview

JsonLogic truthy / falsy logic Cf. jsonlogic.com/truthy.html

Instance Method Summary collapse

Instance Method Details

#falsy?Boolean

Returns:

  • (Boolean)


9
10
11
# File 'lib/json_logic/truthy.rb', line 9

def falsy?
  false
end

#truthy?Boolean

Returns:

  • (Boolean)


5
6
7
# File 'lib/json_logic/truthy.rb', line 5

def truthy?
  !falsy?
end