public class TagUtilities
extends java.lang.Object
Constructor and Description |
---|
TagUtilities(DesignerContext context) |
Modifier and Type | Method and Description |
---|---|
void |
addTags(TagPath parentFolder,
java.util.List<TagNode> tags,
java.lang.String actionName,
TagManagerBase.CollisionPolicy policy) |
static TagPathTreeNode |
getBaseNode(TagPathTreeNode node)
Returns the closes udt instance parent tag, or the input tag, if not under a udt.
|
static <T extends TagPathTreeNode> |
getBaseNodes(java.util.List<T> selected)
Returns the nodes that we can edit - generally those passed in, but returns the parent udt tag for selected
member tags
|
java.lang.Class |
getNodeType(TagPathTreeNode node)
Returns the java type of the tag or tag property that the node points to.
|
TagProp |
getProp(TagPathTreeNode node)
Returns the TagProp pointed to by a TagNode or a TagPropNode.
|
Tag |
getTag(TagPathTreeNode node)
Returns the tag pointed to by a TagNode or a TagPropNode.
|
boolean |
isFolder(TagPathTreeNode node) |
static boolean |
isUDTMember(TagPathTreeNode node) |
void |
modifyTagProperty(TagPathTreeNode node,
java.lang.Object aValue)
Modifies the tag property pointed to by the given node to the value of aValue.
|
void |
modifyTagProperty(TagPathTreeNode node,
TagProp prop,
java.lang.Object aValue)
Modifies the given property of the tag pointed to by node to aValue.
|
void |
removeTags(java.util.List<TagPath> paths,
java.lang.String actionName)
This wrapper for TagManager.removeTag() will add the tag removal to the UNDO/REDO mechanism.
|
public TagUtilities(DesignerContext context)
public void modifyTagProperty(TagPathTreeNode node, java.lang.Object aValue)
node
- aValue
- public void modifyTagProperty(@Nonnull TagPathTreeNode node, TagProp prop, java.lang.Object aValue)
node
- prop
- aValue
- public Tag getTag(TagPathTreeNode node)
node
- public TagProp getProp(TagPathTreeNode node)
node
- public java.lang.Class getNodeType(TagPathTreeNode node)
node
- public boolean isFolder(TagPathTreeNode node)
public static <T extends TagPathTreeNode> java.util.List<T> getBaseNodes(java.util.List<T> selected)
public static TagPathTreeNode getBaseNode(TagPathTreeNode node)
node
- public static boolean isUDTMember(TagPathTreeNode node)
public void removeTags(java.util.List<TagPath> paths, java.lang.String actionName)
path
- public void addTags(TagPath parentFolder, java.util.List<TagNode> tags, java.lang.String actionName, TagManagerBase.CollisionPolicy policy)