public static interface RepresentationTextCreator.RepresentationTextProvider extends PriorityProvider
Plugins may register these providers and override default element's representation text displayed in MagicDraw
HIGH_PRIORITY, LOW_PRIORITY, MEDIUM_PRIORITY
Modifier and Type | Method and Description |
---|---|
boolean |
accept(BaseElement element)
Checks if this provider should be used to create a representation text for the given element
|
java.util.Map<java.lang.Class<? extends Element>,SmartListenerConfig> |
createSmartListenerConfig()
Returns
SmartListenerConfig for the provider. |
default int |
getPriority()
Returns a priority of text creator.
|
java.lang.String |
getRepresentedText(BaseElement element,
RepresentationTextParams textParams)
Returns representation text for a given Element.
|
boolean accept(BaseElement element)
element
- given elementjava.lang.String getRepresentedText(BaseElement element, RepresentationTextParams textParams)
element
- element for which representation text has to be created.textParams
- parameters describing how to construct the text, what to includejava.util.Map<java.lang.Class<? extends Element>,SmartListenerConfig> createSmartListenerConfig()
SmartListenerConfig
for the provider. It describes on what model changes the representation
texts should be recalculated by explicitly calling RepresentationTextProvider#getRepresentedText(BaseElement, RepresentationTextParams)
instead of returning a cached value that was calculated earlier.SmartListenerConfig
default int getPriority()
getPriority
in interface PriorityProvider
PriorityProvider.MEDIUM_PRIORITY