Class GenericTextFragment
java.lang.Object
de.xima.fc.gui.common.placeholder.PlaceHolder
de.xima.fc.gui.common.placeholder.GenericTextFragment
- All Implemented Interfaces:
IPlaceholder, Serializable
PlaceHolder implementation for plain or HTML text fragments (e.g. to make them manageable by the placeholder
dialog).- Since:
- 8.4.1
- Author:
- XIMA MEDIA GmbH
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class PlaceHolder
PlaceHolder.PlaceHolderBuilder -
Field Summary
Fields inherited from interface IPlaceholder
LINK_RECOGNITION_PATTERN -
Method Summary
Modifier and TypeMethodDescriptionstatic PlaceHolderfromTemplate(Textbaustein template, String groupName, boolean untagged, IGuiIcon icon, EPlaceholderInsertHint insertHint) Creates aPlaceHolderinstance based on the properties of atemplate.The preferred way for this text fragment to be inserted into input elements, although this might not be supported by all target components.Gets the full placeholder name with the brackets, e.g.Methods inherited from class PlaceHolder
comparator, empty, equals, formLang, formXfAction, formXfQualifier, getAlias, getDetailedDescription, getDisplayName, getIcon, getIconStyleClass, getIconValue, getKind, getName, getShortDescription, getSortKey, getText, getType, hashCode, isEmpty, toString
-
Method Details
-
getPlaceholder
Description copied from interface:IPlaceholderGets the full placeholder name with the brackets, e.g.[%$CLIENT_ID%]. Used when inserting the placeholder in an input field- Specified by:
getPlaceholderin interfaceIPlaceholder- Overrides:
getPlaceholderin classPlaceHolder- Returns:
- The full placeholder name including brackets.
-
getInsertHint
Description copied from interface:IPlaceholderThe preferred way for this text fragment to be inserted into input elements, although this might not be supported by all target components.The default implementation behaves as follows: If the placeholder starts with "LINK_", ends with "_LINK", or contains "_LINK_" or "_LINK." returns
LINK. Otherwise, returnsTEXT.- Specified by:
getInsertHintin interfaceIPlaceholder- Overrides:
getInsertHintin classPlaceHolder- Returns:
- The preferred insert mode for this text fragment.
-
fromTemplate
public static PlaceHolder fromTemplate(Textbaustein template, String groupName, boolean untagged, IGuiIcon icon, EPlaceholderInsertHint insertHint) Creates aPlaceHolderinstance based on the properties of atemplate.- Parameters:
template- the template to create the text fragment fromgroupName- a string for text fragment grouping (e.g. in datatables)untagged- true, if the provided template doesn't have any keywords/tagsicon- an icon to be used for this text fragment in the GUIinsertHint- describes the way this text fragment prefers to be inserted. Might not be supported by all target components.- Returns:
- The new
PlaceHolderinstance
-