Class: LogixToolkit::Operations::Implication

Inherits:
Object
  • Object
show all
Defined in:
lib/logix-toolkit/operations/implication.rb

Overview

The “implication” class used to define implication operations (e.g A → B)

Class Method Summary collapse

Class Method Details

.check3?(arg0, arg1, arg2) ⇒ Boolean

Returns:

  • (Boolean)


19
20
21
22
23
24
25
# File 'lib/logix-toolkit/operations/implication.rb', line 19

def self.check3? arg0, arg1, arg2
  if BooleanVerifier.verify? arg0, arg1, arg2
    ErrorsAndExceptions.operation_unavailable_atm
  else
    ErrorsAndExceptions.couldnt_be_performed
  end
end

.check4?(arg0, arg1, arg2, arg3) ⇒ Boolean

Returns:

  • (Boolean)


27
28
29
30
31
32
33
# File 'lib/logix-toolkit/operations/implication.rb', line 27

def self.check4? arg0, arg1, arg2, arg3
  if BooleanVerifier.verify? arg0, arg1, arg2, arg3
    ErrorsAndExceptions.operation_unavailable_atm
  else
    ErrorsAndExceptions.couldnt_be_performed
  end
end

.check5?(arg0, arg1, arg2, arg3) ⇒ Boolean

Returns:

  • (Boolean)


35
36
37
38
39
40
41
# File 'lib/logix-toolkit/operations/implication.rb', line 35

def self.check5? arg0, arg1, arg2, arg3
  if BooleanVerifier.verify? arg0, arg1, arg2, arg3
    ErrorsAndExceptions.operation_unavailable_atm
  else
    ErrorsAndExceptions.couldnt_be_performed
  end
end

.check?(arg0, arg1) ⇒ Boolean

Returns:

  • (Boolean)


7
8
9
10
11
12
13
14
15
16
17
# File 'lib/logix-toolkit/operations/implication.rb', line 7

def self.check? arg0, arg1
  if BooleanVerifier.verify? arg0, arg1
    if !arg0 or arg1
      return true
    else
      return false
    end
  else
    ErrorsAndExceptions.couldnt_be_performed
  end
end