Here are the predefined attributes editors:
editorKind | Description |
textSingle | A single-line Text field, default for String and number attributes |
textMulti | A multi-line Text field, default for "Text" datatypes |
richText | A multi-line Styled Text field, default for "RichText" datatypes |
checkbox | A checkbox, default for boolean attributes |
combo | A combobox, default for enumeration attributes |
radio | A radio button based widget, may be used for enumeration attributes |
image | An image visualizer, default for "Image" datatypes, may be used for String attributes |
<!ELEMENT extension (editorWidgetMapping*)>
<!ATTLIST extension
point CDATA #REQUIRED
id CDATA #IMPLIED
name CDATA #IMPLIED>
<!ELEMENT editorWidgetMapping (attributeMapping* , dataTypeMapping*)>
<!ATTLIST editorWidgetMapping
id CDATA #REQUIRED
metamodel CDATA #REQUIRED>
enables to control the binding of editor widgets for specific attributes of a metamodel.
<!ELEMENT attributeMapping (enumLiteral*)>
<!ATTLIST attributeMapping
name CDATA #REQUIRED
editorKind (textSingle|textMulti|richText|checkbox|combo|radio|image)
editable (true | false)>
defines a widget mapping for a specific attribute
isChangeable
property of the attribute.<!ELEMENT dataTypeMapping (enumLiteral*)>
<!ATTLIST dataTypeMapping
name CDATA #REQUIRED
editorKind (textSingle|textMulti|richText|checkbox|combo|radio|image)
editable (true | false)>
defines a mapping for all attributes whose type matches a specific datatype
isChangeable
property of the attribute.<!ELEMENT enumLiteral EMPTY>
<!ATTLIST enumLiteral
literal CDATA #REQUIRED>
defines literal values, that will be displayed in an editable combobox. This element may be used with String attributes mapped to a combo
editor. It enables to define some user-extensible enumerations for String attributes.
VisibilityKind
enumeration to radio buttons (rather than a combobox),
and the body
attribute of Comment to a multiline text field.
<extension point=
"com.sodius.mdw.platform.model.editorWidgetMapping"
>
<editorWidgetMapping id=
"com.sodius.mdw.metamodel.uml21.editorWidgetMapping"
metamodel=
"uml21"
>
<dataTypeMapping editorKind=
"radio"
name=
"VisibilityKind"
/>
<attributeMapping editorKind=
"textMulti"
name=
"Comment.body"
/>
</editorWidgetMapping>
</extension>
SODIUS