Sha256: 10aa5dd60353ef0c6dd551fe2d00b79c2d88cea2e197dbe37df515d8cd3a8cca
Contents?: true
Size: 584 Bytes
Versions: 28
Compression:
Stored size: 584 Bytes
Contents
module PDoc module Models class Class < Entity include Container attr_accessor :constructor attr_accessor :superclass def attach_to_parent(parent) parent.classes << self end def subclasses @subclasses ||= [] end def subclasses? @subclasses && !@subclasses.empty? end def to_hash super.merge({ :superclass => superclass, :constructor => constructor, :subclasses => subclasses.map { |obj| obj.id } }) end end end end
Version data entries
28 entries across 28 versions & 2 rubygems