Interface Appearance
- All Known Implementing Classes:
AppearanceImpl
A representation of the model object 'Appearance'.
This class is used for configuring common aspects of HTML and Bootstrap elements such as background, spacing, text, etc.
The following features are supported:
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptioneffectiveAppearance(String path) Returns the value of the 'Attributes' map.Returns the value of the 'Background' attribute.Returns the value of the 'Border' containment reference list.Returns the value of the 'Children' map.getFloat()Returns the value of the 'Float' containment reference list.Returns the value of the 'Margin' containment reference list.Returns the value of the 'Padding' containment reference list.getText()Returns the value of the 'Text' containment reference.voidsetBackground(Color value) Sets the value of the 'Background' attribute.voidSets the value of the 'Text' containment reference.Methods inherited from interface org.eclipse.emf.ecore.EObject
eAllContents, eClass, eContainer, eContainingFeature, eContainmentFeature, eContents, eCrossReferences, eGet, eGet, eInvoke, eIsProxy, eIsSet, eResource, eSet, eUnsetMethods inherited from interface org.eclipse.emf.common.notify.Notifier
eAdapters, eDeliver, eNotify, eSetDeliver
-
Method Details
-
getBackground
Returns the value of the 'Background' attribute. Bootstrap color for background.- Returns:
- the value of the 'Background' attribute.
- See Also:
-
setBackground
Sets the value of the 'Background' attribute.- Parameters:
value- the new value of the 'Background' attribute.- See Also:
-
getAttributes
Returns the value of the 'Attributes' map. The key is of typeString, and the value is of typeEObject, HTML element (tag) attributes. Attributes defined at the appearance level overwrite attributes defined at the HTML element level. It is recommended to use one of the other. ## Interpolation Attribute values are interpolated, i.e. tokens in the form of ``${token name[|default value]}`` are replaced with the contextual values or default values, if any. Examples: * ``${my-style}`` - Token without a default value. * ``${font-weight|bold}`` - Token with a default value. ## Regular attributes For all top-level entries except ``class``, ``style``, and ``data`` attribute value is produced by converting the value to string for scalars and to JSON string for lists and maps. For attributes which do not start with ``data-`` a warning is issued if the value is not a scalar, i.e. a list or a map. ## Class For class attribute its value is formed by concantenating elements using space as a separator. If elements are hierarchical then class name is formed by concatenation with a dash (``-``) as a separator. ## Data If value of ``data`` attbibute is a map then keys of that map get concatenated with ``data`` using dash (``-``) as a separator, them same applies to nested maps. Non-map values become attribute values - scalars are converted to string, lists are converted to JSON string. ## Style Style can be defined as a string, list or map. If style is defined as a list, all list values are concatenated with a space as a separator - it is a convent way for long unstructured definitions. If style value is a map then the value and its contained map values are processed in the following fashion: * Keys are concatenated with dash as a separator. * List values are contcatenated wtih space as a separator.- Returns:
- the value of the 'Attributes' map.
- See Also:
-
getBorder
Returns the value of the 'Border' containment reference list. The list contents are of typeBorder. Border configuration.- Returns:
- the value of the 'Border' containment reference list.
- See Also:
-
getMargin
Returns the value of the 'Margin' containment reference list. The list contents are of typeSpacing. Margin configuration.- Returns:
- the value of the 'Margin' containment reference list.
- See Also:
-
getPadding
Returns the value of the 'Padding' containment reference list. The list contents are of typeSpacing. Padding configuration.- Returns:
- the value of the 'Padding' containment reference list.
- See Also:
-
getText
Returns the value of the 'Text' containment reference. Text style- Returns:
- the value of the 'Text' containment reference.
- See Also:
-
setText
Sets the value of the 'Text' containment reference.- Parameters:
value- the new value of the 'Text' containment reference.- See Also:
-
getFloat
Returns the value of the 'Float' containment reference list. The list contents are of typeFloat. Float configuration.- Returns:
- the value of the 'Float' containment reference list.
- See Also:
-
getChildren
Returns the value of the 'Children' map. The key is of typeString, and the value is of typeAppearance,- Returns:
- the value of the 'Children' map.
- See Also:
-
effectiveAppearance
-