public class ContentTypeEnumerator extends Object implements Enumerator, Serviceable, Configurable
ContentType
Modifier and Type | Field and Description |
---|---|
protected String |
_allOption
All option : 'disabled' to disable the 'all' option,
'blank' to use a blank value for 'all' option,
or 'concat' to concat all content types' ids for 'all' option
|
protected String[] |
_contentTypes
The parent content types
|
protected ContentTypeExtensionPoint |
_cTypeExtPt
The content type extension point
|
private ContentTypesTreeComponent |
_cTypeTreeComponent |
protected boolean |
_excludeAbstract
True to exclude abstract content types
|
protected boolean |
_excludeMixin
True to exclude mixin content types
|
protected boolean |
_excludePrivate
True to exclude private content types
|
protected boolean |
_excludeReferenceTable
True to exclude reference table content types
|
protected boolean |
_mixinOnly
True to include only mixin content types
|
protected String[] |
_strictContentTypes
The strict content types
|
Constructor and Description |
---|
ContentTypeEnumerator() |
Modifier and Type | Method and Description |
---|---|
protected void |
_handleAllOptionEntry(Map<Object,I18nizableText> entries)
Add the all option entry to the entry list if necessary
|
void |
configure(Configuration configuration) |
Map<String,Object> |
getConfiguration()
Get the configuration this enumerator
|
Map<Object,I18nizableText> |
getEntries()
Provides the enumerated values with their optional label.
|
I18nizableText |
getEntry(String value)
Retrieves a single label from a value.
|
protected Set<ContentType> |
getMatchingContentTypes()
Get the matching content types
|
void |
service(ServiceManager smanager) |
protected ContentTypeExtensionPoint _cTypeExtPt
protected String _allOption
protected boolean _excludePrivate
protected boolean _excludeReferenceTable
protected boolean _excludeAbstract
protected boolean _excludeMixin
protected boolean _mixinOnly
protected String[] _contentTypes
protected String[] _strictContentTypes
private ContentTypesTreeComponent _cTypeTreeComponent
public ContentTypeEnumerator()
public void service(ServiceManager smanager) throws ServiceException
service
in interface Serviceable
ServiceException
public void configure(Configuration configuration) throws ConfigurationException
configure
in interface Configurable
ConfigurationException
public Map<String,Object> getConfiguration()
Enumerator
getConfiguration
in interface Enumerator
public Map<Object,I18nizableText> getEntries() throws Exception
Enumerator
getEntries
in interface Enumerator
Exception
- if an error occurs.protected Set<ContentType> getMatchingContentTypes()
protected void _handleAllOptionEntry(Map<Object,I18nizableText> entries)
entries
- The enumerator entriespublic I18nizableText getEntry(String value) throws Exception
Enumerator
getEntry
in interface Enumerator
value
- the value.null
if not found.Exception
- if an error occurs.