Package org.ametys.core.right
Class Right
- java.lang.Object
-
- org.ametys.core.right.Right
-
-
Field Summary
Fields Modifier and Type Field Description private I18nizableText_categoryprivate String_declarationprivate I18nizableText_descriptionprivate String_idprivate I18nizableText_label
-
Constructor Summary
Constructors Constructor Description Right(String id, I18nizableText label, I18nizableText description, I18nizableText category, String declaration)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object object)I18nizableTextgetCategory()Returns the i18n category of this RightStringgetDeclaration()Returns the declaration of this RightI18nizableTextgetDescription()Returns the i18n description of this RightStringgetId()Returns the unique Id of this RightI18nizableTextgetLabel()Returns the i18n label of this RightinthashCode()Map<String,Object>toJSON()Represents this Right as JSONvoidtoSAX(ContentHandler ch)Represents this Right as SAX events
-
-
-
Field Detail
-
_label
private final I18nizableText _label
-
_description
private final I18nizableText _description
-
_category
private final I18nizableText _category
-
_declaration
private final String _declaration
-
-
Constructor Detail
-
Right
Right(String id, I18nizableText label, I18nizableText description, I18nizableText category, String declaration)
Constructor.- Parameters:
id- the unique Id of this rightlabel- the i18n label of this Rightdescription- the i18n description of the usage of this rightcategory- the i18n cateogry of the usage of this rightdeclaration- the declaration source (for debug purposes)
-
-
Method Detail
-
getId
public String getId()
Returns the unique Id of this Right- Returns:
- the unique Id of this Right
-
getLabel
public I18nizableText getLabel()
Returns the i18n label of this Right- Returns:
- the i18n label of this Right
-
getDescription
public I18nizableText getDescription()
Returns the i18n description of this Right- Returns:
- the i18n description of this Right
-
getCategory
public I18nizableText getCategory()
Returns the i18n category of this Right- Returns:
- the i18n category of this Right
-
getDeclaration
public String getDeclaration()
Returns the declaration of this Right- Returns:
- the declaration
-
toSAX
public void toSAX(ContentHandler ch) throws SAXException
Represents this Right as SAX events- Parameters:
ch- the ContentHandler to process SAX events- Throws:
SAXException- if an error occurs
-
toJSON
public Map<String,Object> toJSON()
Represents this Right as JSON- Returns:
- the right in JSON format
-
-