Class: H8::UndefinedClass

Inherits:
Object show all
Includes:
Singleton
Defined in:
lib/h8/tools.rb,
ext/h8/main.cpp

Overview

The class representing undefined in javascript. Singleton Note that H8::Undefined == false but is not FalseClass

Instance Method Summary collapse

Instance Method Details

#!Object



25
26
27
# File 'lib/h8/tools.rb', line 25

def !
  true
end

#==(x) ⇒ Object



29
30
31
# File 'lib/h8/tools.rb', line 29

def == x
  x.is_a?(H8::UndefinedClass) || x == false
end

#blank?Boolean

Returns:

  • (Boolean)


9
10
11
# File 'lib/h8/tools.rb', line 9

def blank?
  true
end

#empty?Boolean

Returns:

  • (Boolean)


17
18
19
# File 'lib/h8/tools.rb', line 17

def empty?
  true
end

#present?Boolean

Returns:

  • (Boolean)


21
22
23
# File 'lib/h8/tools.rb', line 21

def present?
  false
end

#undefined?Boolean

Returns:

  • (Boolean)


13
14
15
# File 'lib/h8/tools.rb', line 13

def undefined?
  true
end