Class: ARST::Node::Class

Inherits:
Base
  • Object
show all
Includes:
Namable
Defined in:
lib/arst/node/class.rb

Instance Attribute Summary collapse

Attributes included from Namable

#name

Attributes inherited from Base

#children, #parent

Instance Method Summary collapse

Methods included from Namable

#human_name

Methods inherited from Base

#ancestors, #type

Constructor Details

#initialize(options = {}) ⇒ Class

Returns a new instance of Class.



13
14
15
16
17
18
# File 'lib/arst/node/class.rb', line 13

def initialize(options={})
  super(options)
  
  # TODO: Validate keys
  self.superclass = options[:superclass]
end

Instance Attribute Details

#superclassObject

Returns the value of attribute superclass.



11
12
13
# File 'lib/arst/node/class.rb', line 11

def superclass
  @superclass
end

Instance Method Details

#superclass?Boolean

Returns:

  • (Boolean)


25
26
27
# File 'lib/arst/node/class.rb', line 25

def superclass?
  !superclass.nil?
end