class Xumlidot::Types::Klass
representation for a class
Attributes
attributes[RW]
Definition currently holds the superclass … may change these to nesting and ancestors yet…
calls[RW]
Definition currently holds the superclass … may change these to nesting and ancestors yet…
class_methods[RW]
Definition currently holds the superclass … may change these to nesting and ancestors yet…
constants[RW]
Definition currently holds the superclass … may change these to nesting and ancestors yet…
definition[RW]
Definition currently holds the superclass … may change these to nesting and ancestors yet…
instance_methods[RW]
Definition currently holds the superclass … may change these to nesting and ancestors yet…
Public Class Methods
new(definition)
click to toggle source
# File lib/xumlidot/types/klass.rb, line 36 def initialize(definition) @definition = definition @instance_methods = InstanceMethods.new @class_methods = KlassMethods.new @attributes = Attributes.new @constants = Constants.new end
Public Instance Methods
add_method(m)
click to toggle source
# File lib/xumlidot/types/klass.rb, line 49 def add_method(m) m = m.definition if m.respond_to?(:definition) if m.superclass_method == true @class_methods << m else @instance_methods << m end end
to_s()
click to toggle source
# File lib/xumlidot/types/klass.rb, line 45 def to_s "#{definition} " end