Class: RGen::MetamodelBuilder::AttributeDescription
- Inherits:
-
MetamodelDescription
- Object
- MetamodelDescription
- RGen::MetamodelBuilder::AttributeDescription
- Defined in:
- lib/rgen/metamodel_builder/metamodel_description.rb
Overview
DERIVED: ordered = true, unique = false, lowerBound = 0/1, upperBound = 1 DERIVED: when :derived : changeable= false, :volatile=true, transient=true
Instance Attribute Summary
Attributes inherited from MetamodelDescription
Instance Method Summary collapse
-
#initialize(type, props) ⇒ AttributeDescription
constructor
A new instance of AttributeDescription.
Methods inherited from MetamodelDescription
#annotations, default_value, has_default?, #many?, #value
Constructor Details
#initialize(type, props) ⇒ AttributeDescription
Returns a new instance of AttributeDescription.
105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 |
# File 'lib/rgen/metamodel_builder/metamodel_description.rb', line 105 def initialize(type, props) super(props) # type default type ||= :EString setupType(type) # fixed values can not be changed by user setupDefaults checkForInvalidProperties if @props[:derived] @props[:changeable] = false @props[:volatile] = true @props[:transient] = true end checkAllPropertiesSet end |