ViewModel is called Span in meta model.
Span.allinstances->select(sp|sp.Name='somename')
Span and Nesting
Span can have nestings: Span.allinstances->select(sp|sp.Name='somename').Nesting.Name
Span and Nesting can both have OwnedColumns - Collection(Column).
Span and Nesting both have a root PlacingContainer
Span and Nesting has Class set, mandatory for Span and optional for Nesting - if not set for nesting classifier will be derived from root column expression type.
Span may be Rooted or not : RequiresRootObject:Boolean, if true self is defined in expressions to an object of that type
Nesting representing Table can be made Editable Tables by TaggedValue Editable=true
Nesting representing Table can be made Multiselect Tables by TaggedValue MultiSelect=true
Nestings represents Table/ListView when a Column resulting in a collection has its ReferedNesting set to it
Column
A Column corresponds to a UIWidget - depending on the its expression result type:
- TextEdit : result type String, IsStatic=false
- Label: result type String, IsStatic=true
- DateTimePicker: result type DateTime
- CheckBox: result type Boolean
- Image: result type Blob, TaggedValue: Eco.BlobType=Image
- Picker: result type Object, Addition column in ColumnForPickList - this columns expression result type is Collection(Object) and may point to Nesting, where Nesting first column describe content of picklist
- Table/ListView: result type Collection(Object) and ReferedNesting points out Nesting.
- Button: IsAction=true, expression is ActionLanguage
Column has Name: Must be Unique in owning Span or Nesting
Columns may be used to influence Visible, ReadOnly, Label, Style, HelperText, Placeholder for other columns
- If a column is <OtherColumnsName>_Visible: expression should result in Boolean, controls widget visibility by a expression
- If a column is <OtherColumnsName>_ReadOnly: expression should result in Boolean, controls data mutability by a expression
- If a column is <OtherColumnsName>_Label: expression should result in String, controls widget label by a expression
- If a column is <OtherColumnsName>_Style: expression should result in String, controls widget style-name by a expression
- If a column is <OtherColumnsName>_HelperText: expression should result in String, controls widget tooltip by a expression
- If a column is <OtherColumnsName>_Placeholder: expression should result in String, controls widget placeholder text by a expression
Column has PresentationString: When value is <Name> , the presentation label of the widget will be the Name. When empty the label is not rendered.
Column has Expression: The ocl expression resulting in the data exposed/shown, usually an attribute of a an object or a constant expression
Column has CodeComment: Description of purpose
Column has RowSpan:Integer: Value * 20px will be MinHeight in rendering - default 1
Column has ColSpan:Integer: Value * 50px will be MinWidth in rendering
Column has PCAlignSelf: Start, End, Center, Baseline, Stretch
Column has PCGrow:Integer: Default 1 , Flex Grow in PlacingContainer
Column has PCMarginTop,PCMarginBottom,PCMarginLeft, PCMarginRight, PCMaxSize,PCMinSize, PCMaxSizeSecondary, PCMinSizeSecondary - all Integers - maps to Flexbox behaviour.
PlacingContainer
PlacingContainer corresponds to a Flexbox
PlacingContainer should either contain Columns - Collection(Column) or ChildContainers - Collection(PlacingContainer) - it is not correct to both have columns and ChildContainers in the same PlacingContainer.
PlacingContainer has Type: Row,Column this controls Flexbox rendering
PlacingContainer has JustifyContent: Start, End, Center, SpaceBetween, SpaceAround this controls Flexbox rendering
PlacingContainer has AlignContent: Start, End, Center, SpaceBetween, SpaceAround, Stretch this controls Flexbox rendering
PlacingContainer has AlignItem: Start, End, Center, Baseline, Stretch this controls Flexbox rendering
PlacingContainer has SelfAlign: Start, End, Center, Baseline, Stretch
PlacingContainer has MarginTop,MarginBottom,MarginLeft, MarginRight, MaxSize,MinSize - all Integers - controls Flexbox rendering
PlacingContainer has VisibleExpression: The ocl expression (Boolean result) controlling visibility (returns true if empty)
PlacingContainer has StyleExpression: The ocl expression (String result) controlling Style reference
