Class: Jekyll::Archimate::ElementEntity
- Inherits:
-
EntityBase
- Object
- EntityBase
- Jekyll::Archimate::ElementEntity
- Defined in:
- lib/jekyll/archimate/archimate_hook.rb
Overview
Represents an ArchiMate Element
Instance Attribute Summary
Attributes inherited from EntityBase
Instance Method Summary collapse
Methods inherited from EntityBase
Constructor Details
This class inherits a constructor from Jekyll::Archimate::EntityBase
Instance Method Details
#attr_hash ⇒ Object
47 48 49 50 51 52 53 54 |
# File 'lib/jekyll/archimate/archimate_hook.rb', line 47 def attr_hash super.merge( type: "Element", element_type: entity.type, relationships: model.relationships.select { |rel| rel.source&.id == entity.id || rel.target&.id == entity.id }.map(&:id), views: model.diagrams.select { |dia| dia.element_ids.include?(entity.id) }.map(&:id) ) end |