public class ContentTypeDefinition extends Object implements ContentTypeDescriptor
Modifier and Type | Field and Description |
---|---|
private I18nizableText |
_category |
private List<ClientSideElement.ScriptFile> |
_cssFiles |
private I18nizableText |
_defaultTitle |
private I18nizableText |
_description |
private String |
_iconDecorator |
private String |
_iconGlyph |
private String |
_id |
private boolean |
_isAbstract |
private I18nizableText |
_label |
private String |
_largeIcon |
private String |
_mediumIcon |
private List<MetadataDefinition> |
_metadata |
private List<AbstractMetadataSetElement> |
_metadataSet |
private String |
_parentRef |
private String |
_pluginName |
private String |
_right |
private String[] |
_supertypeIds |
private Set<String> |
_tags |
Constructor and Description |
---|
ContentTypeDefinition(String id)
Constructs a new representative of a content type
|
Modifier and Type | Method and Description |
---|---|
I18nizableText |
getCategory()
Retrieves the category of the content type.
|
List<ClientSideElement.ScriptFile> |
getCSSFiles()
Returns the list of CSS files needed to correctly display the content's in BO, such as the content's icon
|
I18nizableText |
getDefaultTitle()
Retrieves the default title of the content type.
|
I18nizableText |
getDescription()
Retrieves the description of the content type.
|
Set<String> |
getEditionMetadataSetNames(boolean includeInternal)
Returns all names of "edition" metadataSets.
|
String |
getIconDecorator()
Retrieves the CSS class to use for decorator above the main icon
|
String |
getIconGlyph()
Retrieves the CSS class to use for glyph icon
|
String |
getId()
Retrieves the id of the content type.
|
I18nizableText |
getLabel()
Retrieves the label of the content type.
|
String |
getLargeIcon()
Retrieves the URL of the icon without the context path.
|
String |
getMediumIcon()
Retrieves the URL of the icon without the context path.
|
List<MetadataDefinition> |
getMetadata()
Get metadata of content type
|
List<AbstractMetadataSetElement> |
getMetadataSet()
Get metadataSet of content type
|
MetadataSet |
getMetadataSetForEdition(String metadataSetName)
Retrieves the metadata set name for edition.
|
MetadataSet |
getMetadataSetForView(String metadataSetName)
Retrieves the metadata set name for view.
|
String |
getParentRef()
Get the parent reference of content type
|
String |
getPluginName()
Retrieves the name of the plugin declaring this content type.
|
String |
getRight()
Get the right of the content type
|
String |
getSmallIcon()
Retrieves the URL of the icon without the context path.
|
String[] |
getSupertypeIds()
Retrieves the super type's ids.
|
Set<String> |
getTags()
Get tags of content type
|
View |
getView(String viewName) |
Set<String> |
getViewMetadataSetNames(boolean includeInternal)
Returns all names of "view" metadataSets.
|
Set<String> |
getViewNames(boolean includeInternal) |
boolean |
isAbstract()
Indicates if the content type is abstract
|
void |
setCategory(I18nizableText category)
Set the category of content type
|
void |
setCSSFiles(List<ClientSideElement.ScriptFile> cSSFiles)
Set CSS files of content type
|
void |
setDefaultTitle(I18nizableText defaultTitle)
Set the default title of content type
|
void |
setDescription(I18nizableText description)
Set the description of content type
|
void |
setIconDecorator(String iconDecorator)
Set icon decorator of content type
|
void |
setIconGlyph(String iconGlyph)
Set icon glyph of content type
|
void |
setId(String id)
Set id of content type
|
void |
setIsAbstract(boolean isAbstract)
Set if content type is abstract
|
void |
setLabel(I18nizableText label)
Set the label of content type
|
void |
setLargeIcon(String largeIcon)
Set large icon of content type
|
void |
setMediumIcon(String mediumIcon)
Set medium icon of content type
|
void |
setMetadata(List<MetadataDefinition> metadata)
Set metadata of content type
|
void |
setMetadataSet(List<AbstractMetadataSetElement> metadataSet)
Set metadata set of content type
|
void |
setParentRef(String parentRef)
Set the parent reference of content type
|
void |
setPluginName(String pluginName)
Set the plugin name of content type
|
void |
setRight(String right)
Set the right of content type
|
void |
setSupertypeIds(String[] supertypeIds)
Set supertypes of content type
|
void |
setTags(Set<String> tags)
Set tags of content type
|
private String _pluginName
private I18nizableText _label
private I18nizableText _description
private I18nizableText _defaultTitle
private I18nizableText _category
private String[] _supertypeIds
private boolean _isAbstract
private String _iconGlyph
private String _iconDecorator
private String _largeIcon
private String _mediumIcon
private List<ClientSideElement.ScriptFile> _cssFiles
private List<MetadataDefinition> _metadata
private List<AbstractMetadataSetElement> _metadataSet
private String _parentRef
public ContentTypeDefinition(String id)
id
- id of content typepublic String getId()
ContentTypeDescriptor
getId
in interface ContentTypeDescriptor
public String getPluginName()
ContentTypeDescriptor
getPluginName
in interface ContentTypeDescriptor
public I18nizableText getLabel()
ContentTypeDescriptor
getLabel
in interface ContentTypeDescriptor
public I18nizableText getDescription()
ContentTypeDescriptor
getDescription
in interface ContentTypeDescriptor
public I18nizableText getDefaultTitle()
ContentTypeDescriptor
getDefaultTitle
in interface ContentTypeDescriptor
public I18nizableText getCategory()
ContentTypeDescriptor
getCategory
in interface ContentTypeDescriptor
public String[] getSupertypeIds()
ContentTypeDescriptor
getSupertypeIds
in interface ContentTypeDescriptor
public boolean isAbstract()
public String getIconGlyph()
ContentTypeDescriptor
getIconGlyph
in interface ContentTypeDescriptor
public String getIconDecorator()
ContentTypeDescriptor
getIconDecorator
in interface ContentTypeDescriptor
public String getSmallIcon()
ContentTypeDescriptor
getSmallIcon
in interface ContentTypeDescriptor
public String getMediumIcon()
ContentTypeDescriptor
getMediumIcon
in interface ContentTypeDescriptor
public String getLargeIcon()
ContentTypeDescriptor
getLargeIcon
in interface ContentTypeDescriptor
public Set<String> getViewMetadataSetNames(boolean includeInternal)
ContentTypeDescriptor
getViewMetadataSetNames
in interface ContentTypeDescriptor
includeInternal
- if the result should include internal metadataSets.public Set<String> getEditionMetadataSetNames(boolean includeInternal)
ContentTypeDescriptor
getEditionMetadataSetNames
in interface ContentTypeDescriptor
includeInternal
- if the result should include internal metadataSets.public Set<String> getViewNames(boolean includeInternal)
public MetadataSet getMetadataSetForView(String metadataSetName)
ContentTypeDescriptor
getMetadataSetForView
in interface ContentTypeDescriptor
metadataSetName
- the metadata set name.public MetadataSet getMetadataSetForEdition(String metadataSetName)
ContentTypeDescriptor
getMetadataSetForEdition
in interface ContentTypeDescriptor
metadataSetName
- the metadata set name.public List<ClientSideElement.ScriptFile> getCSSFiles()
ContentTypeDescriptor
getCSSFiles
in interface ContentTypeDescriptor
public String getRight()
public List<AbstractMetadataSetElement> getMetadataSet()
public List<MetadataDefinition> getMetadata()
public String getParentRef()
public void setRight(String right)
right
- the right to setpublic void setTags(Set<String> tags)
tags
- tags to setpublic void setMetadata(List<MetadataDefinition> metadata)
metadata
- metadata to setpublic void setMetadataSet(List<AbstractMetadataSetElement> metadataSet)
metadataSet
- metadata set to setpublic void setPluginName(String pluginName)
pluginName
- the plugin name to setpublic void setLabel(I18nizableText label)
label
- the label to setpublic void setDescription(I18nizableText description)
description
- the description to setpublic void setDefaultTitle(I18nizableText defaultTitle)
defaultTitle
- the default title to setpublic void setCategory(I18nizableText category)
category
- the category of content typepublic void setSupertypeIds(String[] supertypeIds)
supertypeIds
- supertypes to setpublic void setIconGlyph(String iconGlyph)
iconGlyph
- icon glyph to setpublic void setIconDecorator(String iconDecorator)
iconDecorator
- icon decorator to setpublic void setLargeIcon(String largeIcon)
largeIcon
- large icon to setpublic void setMediumIcon(String mediumIcon)
mediumIcon
- medium icon to setpublic void setCSSFiles(List<ClientSideElement.ScriptFile> cSSFiles)
cSSFiles
- css files to setpublic void setIsAbstract(boolean isAbstract)
isAbstract
- the boolean to setpublic void setParentRef(String parentRef)
parentRef
- the parent reference to set