Class: Lutaml::Uml::Document

Inherits:
Object
  • Object
show all
Includes:
HasAttributes, HasMembers
Defined in:
lib/lutaml/uml/document.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from HasMembers

#members=

Methods included from HasAttributes

#update_attributes

Constructor Details

#initialize(attributes = {}) ⇒ Document

rubocop:disable Rails/ActiveRecordAliases



26
27
28
# File 'lib/lutaml/uml/document.rb', line 26

def initialize(attributes = {})
  update_attributes(attributes)
end

Instance Attribute Details

#captionObject

Returns the value of attribute caption.



16
17
18
# File 'lib/lutaml/uml/document.rb', line 16

def caption
  @caption
end

#commentsObject

Returns the value of attribute comments.



16
17
18
# File 'lib/lutaml/uml/document.rb', line 16

def comments
  @comments
end

#fidelityObject

Returns the value of attribute fidelity.



16
17
18
# File 'lib/lutaml/uml/document.rb', line 16

def fidelity
  @fidelity
end

#fontnameObject

Returns the value of attribute fontname.



16
17
18
# File 'lib/lutaml/uml/document.rb', line 16

def fontname
  @fontname
end

#groupsObject

Returns the value of attribute groups.



16
17
18
# File 'lib/lutaml/uml/document.rb', line 16

def groups
  @groups
end

#nameObject

Returns the value of attribute name.



16
17
18
# File 'lib/lutaml/uml/document.rb', line 16

def name
  @name
end

#packagesObject

Returns the value of attribute packages.



23
24
25
# File 'lib/lutaml/uml/document.rb', line 23

def packages
  @packages
end

#titleObject

Returns the value of attribute title.



16
17
18
# File 'lib/lutaml/uml/document.rb', line 16

def title
  @title
end

Instance Method Details

#associationsObject



76
77
78
# File 'lib/lutaml/uml/document.rb', line 76

def associations
  @associations || []
end

#associations=(value) ⇒ Object



50
51
52
53
54
# File 'lib/lutaml/uml/document.rb', line 50

def associations=(value)
  @associations = value.to_a.map do |attributes|
    Association.new(attributes)
  end
end

#classesObject



56
57
58
# File 'lib/lutaml/uml/document.rb', line 56

def classes
  @classes || []
end

#classes=(value) ⇒ Object

rubocop:enable Rails/ActiveRecordAliases



30
31
32
# File 'lib/lutaml/uml/document.rb', line 30

def classes=(value)
  @classes = value.to_a.map { |attributes| Class.new(attributes) }
end

#data_typesObject



64
65
66
# File 'lib/lutaml/uml/document.rb', line 64

def data_types
  @data_types || []
end

#data_types=(value) ⇒ Object



34
35
36
# File 'lib/lutaml/uml/document.rb', line 34

def data_types=(value)
  @data_types = value.to_a.map { |attributes| DataType.new(attributes) }
end

#enumsObject



60
61
62
# File 'lib/lutaml/uml/document.rb', line 60

def enums
  @enums || []
end

#enums=(value) ⇒ Object



38
39
40
# File 'lib/lutaml/uml/document.rb', line 38

def enums=(value)
  @enums = value.to_a.map { |attributes| Enum.new(attributes) }
end

#primitivesObject



72
73
74
# File 'lib/lutaml/uml/document.rb', line 72

def primitives
  @primitives || []
end

#primitives=(value) ⇒ Object



46
47
48
# File 'lib/lutaml/uml/document.rb', line 46

def primitives=(value)
  @primitives = value.to_a.map { |attributes| PrimitiveType.new(attributes) }
end