Modifier and Type | Class and Description |
---|---|
static class |
CMSTag.TagVisibility
Tag visibility
|
Modifier and Type | Field and Description |
---|---|
private I18nizableText |
_description |
private String |
_id |
private String |
_name |
private CMSTag |
_parent |
private Map<String,CMSTag> |
_tags |
private TagTargetType |
_targetType |
private I18nizableText |
_title |
private CMSTag.TagVisibility |
_visibility |
NAME_PATTERN
Constructor and Description |
---|
CMSTag(String id,
String name,
CMSTag parent,
I18nizableText title,
I18nizableText description,
CMSTag.TagVisibility visibility,
TagTargetType target)
Constructor
|
CMSTag(String id,
String name,
CMSTag parent,
I18nizableText title,
I18nizableText description,
TagTargetType target)
Constructor
|
Modifier and Type | Method and Description |
---|---|
void |
addTag(Tag tag)
Add a new child tag.
|
I18nizableText |
getDescription()
Retrieves the description.
|
String |
getId()
Get the tag unique id.
|
String |
getName()
Get the tag name.
|
CMSTag |
getParent()
Get the parent tag
|
String |
getParentName()
Get the parent name.
|
CMSTag |
getTag(String tagId)
Try to get a child tag by its id
|
Map<String,CMSTag> |
getTags()
Retrieves the Set of child tags
|
TagTargetType |
getTarget()
Retrieves the target type.
|
I18nizableText |
getTitle()
Retrieves the title.
|
CMSTag.TagVisibility |
getVisibility()
Retrieves the visibility type.
|
boolean |
hasTag(String tagId)
Determines if a tag exists
|
void |
setTags(Map<String,? extends Tag> tags)
Set the child tags
|
void |
setTarget(TagTargetType target)
Set the target type.
|
void |
setVisibility(CMSTag.TagVisibility visibility)
Set the visibility type.
|
private I18nizableText _title
private I18nizableText _description
private CMSTag.TagVisibility _visibility
private TagTargetType _targetType
public CMSTag(String id, String name, CMSTag parent, I18nizableText title, I18nizableText description, TagTargetType target)
id
- The id of the tag. The id must be unique.name
- The name of the tag. The name must be unique. The name is the same as the id except for JCR tag.parent
- The parent tag (can be null if the tag has no parent)title
- the tag titledescription
- the tag descriptiontarget
- the type of targetpublic CMSTag(String id, String name, CMSTag parent, I18nizableText title, I18nizableText description, CMSTag.TagVisibility visibility, TagTargetType target)
id
- The id of the tag. The id must be unique.name
- The name of the tag. The name must be unique. The name is the same as the id except for JCR tag.parent
- The parent tag (can be null if the tag has no parent)title
- the tag titledescription
- the tag descriptionvisibility
- the tag visibility.target
- The type of targetpublic I18nizableText getTitle()
Tag
public I18nizableText getDescription()
Tag
getDescription
in interface Tag
public String getParentName()
Tag
getParentName
in interface Tag
public Map<String,CMSTag> getTags()
Tag
public CMSTag getTag(String tagId)
Tag
public boolean hasTag(String tagId)
Tag
public CMSTag.TagVisibility getVisibility()
public void setVisibility(CMSTag.TagVisibility visibility)
visibility
- the visibility to set.public TagTargetType getTarget()
public void setTarget(TagTargetType target)
target
- the target to set.