Module: RGen::ECore::EClass::ClassModule
- Defined in:
- lib/rgen/ecore/ecore.rb,
lib/rgen/ecore/ecore_ext.rb
Instance Method Summary collapse
- #concrete ⇒ Object
- #eAllAttributes_derived ⇒ Object
- #eAllContainments_derived ⇒ Object
- #eAllReferences_derived ⇒ Object
- #eAllStructuralFeatures_derived ⇒ Object
- #eAllSubTypes ⇒ Object
- #eAllSuperTypes_derived ⇒ Object
- #eAttributes_derived ⇒ Object
- #eReferences_derived ⇒ Object
- #isAssignableFrom(cls) ⇒ Object
- #qualifiedName ⇒ Object
Instance Method Details
#concrete ⇒ Object
67 68 69 |
# File 'lib/rgen/ecore/ecore_ext.rb', line 67 def concrete !(abstract || interface) end |
#eAllAttributes_derived ⇒ Object
165 166 167 |
# File 'lib/rgen/ecore/ecore.rb', line 165 def eAllAttributes_derived eAttributes + eSuperTypes.eAllAttributes end |
#eAllContainments_derived ⇒ Object
168 169 170 |
# File 'lib/rgen/ecore/ecore.rb', line 168 def eAllContainments_derived eReferences.select{|r| r.containment} + eSuperTypes.eAllContainments end |
#eAllReferences_derived ⇒ Object
171 172 173 |
# File 'lib/rgen/ecore/ecore.rb', line 171 def eAllReferences_derived eReferences + eSuperTypes.eAllReferences end |
#eAllStructuralFeatures_derived ⇒ Object
174 175 176 |
# File 'lib/rgen/ecore/ecore.rb', line 174 def eAllStructuralFeatures_derived eStructuralFeatures + eSuperTypes.eAllStructuralFeatures end |
#eAllSubTypes ⇒ Object
63 64 65 |
# File 'lib/rgen/ecore/ecore_ext.rb', line 63 def eAllSubTypes eSubTypes + eSubTypes.eAllSubTypes end |
#eAllSuperTypes_derived ⇒ Object
177 178 179 |
# File 'lib/rgen/ecore/ecore.rb', line 177 def eAllSuperTypes_derived eSuperTypes + eSuperTypes.eAllSuperTypes end |
#eAttributes_derived ⇒ Object
180 181 182 |
# File 'lib/rgen/ecore/ecore.rb', line 180 def eAttributes_derived eStructuralFeatures.select{|f| f.is_a?(EAttribute)} end |
#eReferences_derived ⇒ Object
183 184 185 |
# File 'lib/rgen/ecore/ecore.rb', line 183 def eReferences_derived eStructuralFeatures.select{|f| f.is_a?(EReference)} end |
#isAssignableFrom(cls) ⇒ Object
71 72 73 |
# File 'lib/rgen/ecore/ecore_ext.rb', line 71 def isAssignableFrom(cls) cls == self || cls.eAllSuperTypes.any? { |super_type| super_type == self } end |
#qualifiedName ⇒ Object
55 56 57 58 59 60 61 |
# File 'lib/rgen/ecore/ecore_ext.rb', line 55 def qualifiedName if ePackage ePackage.qualifiedName+"::"+name else name end end |