Class PublicationSettings
- java.lang.Object
-
- com.jalios.jcms.taglib.settings.BasicSettings<T>
-
- com.jalios.jcms.taglib.settings.SelectorSettings<T>
-
- com.jalios.jcms.taglib.settings.AbstractChooserSettings<T>
-
- com.jalios.jcms.taglib.settings.AbstractDataSettings<PublicationSettings>
-
- com.jalios.jcms.taglib.settings.impl.PublicationSettings
-
- All Implemented Interfaces:
ControlSettings<PublicationSettings>,java.lang.Cloneable
public class PublicationSettings extends AbstractDataSettings<PublicationSettings>
Publication Settings- Author:
- Nicolas Dos Santos
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.jalios.jcms.taglib.settings.SelectorSettings
SelectorSettings.SegmentedType, SelectorSettings.SelectMode, SelectorSettings.SelectorType
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringCATEGORIESstatic java.lang.StringDOCUMENT_KINDSstatic java.lang.StringDROPDOWN_DISABLEDstatic java.lang.StringEXACT_TYPEstatic java.lang.StringFILE_INPUT_DISABLEDstatic java.lang.StringFILE_INPUT_ENABLEDstatic java.lang.StringNO_WORKSPACE_FILTERstatic java.lang.StringPSTATUSstatic java.lang.StringSUPER_TYPEstatic java.lang.StringSUPER_TYPE_CLASS-
Fields inherited from class com.jalios.jcms.taglib.settings.AbstractDataSettings
DATA_CLASS
-
Fields inherited from class com.jalios.jcms.taglib.settings.SelectorSettings
ENABLE_SEARCH, ENUM_DATA_ATTRIBUTES, ENUM_LABEL_APPENDS, ENUM_LABEL_PREPENDS, ENUM_LABELS, ENUM_VALUES, INLINE, MULTIPLE, REQUIRED, SEGMENTED_TYPE, SEGMENTED_TYPE_DEFAULT, SELECT_ITEM_EMPTY_VALUE, SELECT_ITEM_EMPTY_VALUE_LABEL, SELECTOR_TYPE, WRAPPER_CSS
-
Fields inherited from class com.jalios.jcms.taglib.settings.BasicSettings
APPEND, ARIA_ATTR_PREFIX, ARIA_ATTRIBUTES, AUTOFOCUS, CLEAR_BUTTON, CSS, DATA_ATTR_PREFIX, DATA_ATTRIBUTES, DISABLED, HIDE_CLEAR_BUTTON, HTML_ATTRIBUTES, ID, LANGUAGE_CHOOSER, MAX_LENGTH, NAME, PLACEHOLDER, PREPEND, READONLY, TITLE, TRIGGER_ACTION, TRIGGER_EVENT, VALUE
-
-
Constructor Summary
Constructors Constructor Description PublicationSettings()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description PublicationSettingscategory(Category[] categories)Specify the categories to filter the Publications.PublicationSettingscategory(Category category, Category... otherCategories)Specify the categories to filter the Publications.PublicationSettingscategory(java.lang.String[] categoryIds)Specify the categories to filter the Publications.PublicationSettingscategory(java.lang.String categoryId, java.lang.String... otherCategoryIds)Specify the categories to filter the Publications.PublicationSettingscategory(java.util.Collection<Category> categories)Specify the categories to filter the Publications.PublicationSettingsclone()Clone the current ControlSettings.PublicationSettingsdisableDropdown()Specify whether the dropdown menu is disabled.PublicationSettingsdisableFileInput()Specify whether the file input is disabled for Publications of type FileDocument.PublicationSettingsdocumentKinds(java.lang.String[] documentKinds)Specify the document kinds to filter the Publications.PublicationSettingsdocumentKinds(java.lang.String documentKinds, java.lang.String... otherDocumentKinds)PublicationSettingsdocumentKinds(java.util.Collection<java.lang.String> documentKinds)Specify the document kinds to filter the Publications.PublicationSettingsenableFileInput()Specify whether the file input is enabled for Publications of type FileDocument.PublicationSettingsexactType()Specify whether it only retrieves Publications of the type defined by the superType, and not child classes.protected java.lang.StringgetChooserIcon()Property key whose value corresponds to the icon used for the chooser button.protected java.lang.StringgetChooserName()Chooser name used by the databroker when there is a click event in the chooser button.protected java.lang.StringgetChooserOption(java.util.Map<java.lang.String,java.lang.String[]> customOptionMap)Options used by the databroker when there is a click event in the chooser button.java.lang.Class<? extends Data>getDataClass()Data class supported by the currentControlSettingsstatic java.util.List<java.lang.String>getDocumentKindsList()Returns the list of document kinds defined in the properties.<V> VgetOption(java.lang.String optionName)Returns the value of the specified option.protected PublicationSettingsgetThis()Returns the exact type of the this reference.
It's a way to recover the type of thethisobject in a class hierarchy (cf.ControlTypegetType()Returns theControlTyperelated to the currentControlSettingsimplementation.PublicationSettingsnoWorkspaceFilter()Specify whether we don't filter on Workspace.PublicationSettingspstatus(int pstatus)Specify the pstatus to filter the Publications.voidresolveOptions(TypeFieldEntry tfe)Set options from the specifiedTypeFieldEntry.PublicationSettingssuperType(java.lang.Class<?> clazz)Specify the super type to filter the Publication.PublicationSettingssuperType(java.lang.String className)Specify the super type to filter the Publications.protected booleanuseCurrentWorkspace()Override this method and return 'true' to add current Workspace in chooser option if not defined by WORKSPACE option.-
Methods inherited from class com.jalios.jcms.taglib.settings.AbstractChooserSettings
addAcChooserOption, addChooserOption, getAcChooserName, getAcChooserOption, getChooserTitle, popupHeight, popupWidth, superGetOption, workspace, workspace
-
Methods inherited from class com.jalios.jcms.taglib.settings.SelectorSettings
checkbox, chooser, disableInline, emptyValueLabel, enumDataAttribute, enumLabelAppends, enumLabelAppends, enumLabelAppends, enumLabelPreprends, enumLabelPreprends, enumLabelPreprends, enumLabels, enumLabels, enumLabels, enumValues, enumValues, enumValues, inline, multiple, radio, required, segmented, select, select, selectorType, single, wrapperCss
-
Methods inherited from class com.jalios.jcms.taglib.settings.BasicSettings
addOption, append, aria, aria, autofocus, clearOption, css, dataAttribute, dataAttribute, dataAttributes, disable, getOptionNames, htmlAttributes, htmlAttributes, id, isChannelReady, maxLength, merge, name, onChange, onFocusOut, placeholder, prepend, readonly, removeOption, require, showLanguageChooser, sortSet, title, toStringArray, toStringArray, toStringArray, toStringArray, toStringArray, trigger, value
-
-
-
-
Field Detail
-
SUPER_TYPE
public static final java.lang.String SUPER_TYPE
- See Also:
- Constant Field Values
-
SUPER_TYPE_CLASS
public static final java.lang.String SUPER_TYPE_CLASS
- See Also:
- Constant Field Values
-
PSTATUS
public static final java.lang.String PSTATUS
- See Also:
- Constant Field Values
-
CATEGORIES
public static final java.lang.String CATEGORIES
- See Also:
- Constant Field Values
-
NO_WORKSPACE_FILTER
public static final java.lang.String NO_WORKSPACE_FILTER
- See Also:
- Constant Field Values
-
DOCUMENT_KINDS
public static final java.lang.String DOCUMENT_KINDS
- See Also:
- Constant Field Values
-
EXACT_TYPE
public static final java.lang.String EXACT_TYPE
- See Also:
- Constant Field Values
-
FILE_INPUT_DISABLED
public static final java.lang.String FILE_INPUT_DISABLED
- See Also:
- Constant Field Values
-
FILE_INPUT_ENABLED
public static final java.lang.String FILE_INPUT_ENABLED
- See Also:
- Constant Field Values
-
DROPDOWN_DISABLED
public static final java.lang.String DROPDOWN_DISABLED
- See Also:
- Constant Field Values
-
-
Method Detail
-
getType
public ControlType getType()
Description copied from interface:ControlSettingsReturns theControlTyperelated to the currentControlSettingsimplementation.- Returns:
ControlType
-
getThis
protected PublicationSettings getThis()
Description copied from class:BasicSettingsReturns the exact type of the this reference.
It's a way to recover the type of thethisobject in a class hierarchy (cf. getThis "trick").- Specified by:
getThisin classBasicSettings<PublicationSettings>- Returns:
- The exact type of the this reference
-
getDataClass
public java.lang.Class<? extends Data> getDataClass()
Description copied from class:AbstractDataSettingsData class supported by the currentControlSettings- Specified by:
getDataClassin classAbstractDataSettings<PublicationSettings>- Returns:
- The
Dataclass
-
getOption
public <V> V getOption(java.lang.String optionName)
Description copied from interface:ControlSettingsReturns the value of the specified option.- Specified by:
getOptionin interfaceControlSettings<PublicationSettings>- Overrides:
getOptionin classAbstractDataSettings<PublicationSettings>- Parameters:
optionName- Option name- Returns:
- Option value
-
resolveOptions
public void resolveOptions(TypeFieldEntry tfe)
Description copied from interface:ControlSettingsSet options from the specifiedTypeFieldEntry.- Specified by:
resolveOptionsin interfaceControlSettings<PublicationSettings>- Overrides:
resolveOptionsin classSelectorSettings<PublicationSettings>- Parameters:
tfe-TypeFieldEntry
-
getChooserName
protected java.lang.String getChooserName()
Description copied from class:AbstractChooserSettingsChooser name used by the databroker when there is a click event in the chooser button.- Specified by:
getChooserNamein classAbstractChooserSettings<PublicationSettings>- Returns:
- The chooser name
- See Also:
- "/js/jalios/core/jalios-widget-chooser.js"
-
getChooserOption
protected java.lang.String getChooserOption(java.util.Map<java.lang.String,java.lang.String[]> customOptionMap)
Description copied from class:AbstractChooserSettingsOptions used by the databroker when there is a click event in the chooser button.- Overrides:
getChooserOptionin classAbstractDataSettings<PublicationSettings>- Parameters:
customOptionMap- Extra chooser options forwarded by the optionChooserConstants.EXTRA_CHOOSER_OPTIONand appended to the query string- Returns:
Stringrepresenting the options as query string
-
getChooserIcon
protected java.lang.String getChooserIcon()
Description copied from class:AbstractChooserSettingsProperty key whose value corresponds to the icon used for the chooser button.Example:
If we declare the following icon property:
The method returnicon.chooser-publication: glyph: icomoon-file-text2chooser-publication- Overrides:
getChooserIconin classAbstractChooserSettings<PublicationSettings>- Returns:
- Property key representing the chooser button icon
-
useCurrentWorkspace
protected boolean useCurrentWorkspace()
Description copied from class:AbstractChooserSettingsOverride this method and return 'true' to add current Workspace in chooser option if not defined by WORKSPACE option.- Overrides:
useCurrentWorkspacein classAbstractChooserSettings<PublicationSettings>- Returns:
trueto use the current workspace,falseinstead
-
clone
public PublicationSettings clone() throws java.lang.CloneNotSupportedException
Description copied from interface:ControlSettingsClone the current ControlSettings.- Specified by:
clonein interfaceControlSettings<PublicationSettings>- Overrides:
clonein classBasicSettings<PublicationSettings>- Returns:
- the new cloned ControlSettings
- Throws:
java.lang.CloneNotSupportedException
-
superType
public PublicationSettings superType(java.lang.Class<?> clazz)
Specify the super type to filter the Publication.- Parameters:
clazz- Class of super type- Returns:
- a reference to this object - used to chain calls
-
superType
public PublicationSettings superType(java.lang.String className)
Specify the super type to filter the Publications.- Parameters:
className- Class name of super type- Returns:
- a reference to this object - used to chain calls
-
pstatus
public PublicationSettings pstatus(int pstatus)
Specify the pstatus to filter the Publications.- Parameters:
pstatus- pstatus- Returns:
- a reference to this object - used to chain calls
-
category
public PublicationSettings category(java.lang.String[] categoryIds)
Specify the categories to filter the Publications.- Parameters:
categoryIds- IDs ofCategoryobjects- Returns:
- a reference to this object - used to chain calls
-
category
public PublicationSettings category(Category[] categories)
Specify the categories to filter the Publications.- Parameters:
categories- Array ofCategoryobjects- Returns:
- a reference to this object - used to chain calls
-
category
public PublicationSettings category(java.util.Collection<Category> categories)
Specify the categories to filter the Publications.- Parameters:
categories- Collection ofCategoryobjects- Returns:
- a reference to this object - used to chain calls
-
category
public PublicationSettings category(Category category, Category... otherCategories)
Specify the categories to filter the Publications.
-
category
public PublicationSettings category(java.lang.String categoryId, java.lang.String... otherCategoryIds)
Specify the categories to filter the Publications.
-
noWorkspaceFilter
public PublicationSettings noWorkspaceFilter()
Specify whether we don't filter on Workspace.- Returns:
- a reference to this object - used to chain calls
-
documentKinds
public PublicationSettings documentKinds(java.lang.String[] documentKinds)
Specify the document kinds to filter the Publications.- Parameters:
documentKinds- Array of document kinds- Returns:
- a reference to this object - used to chain calls
-
documentKinds
public PublicationSettings documentKinds(java.util.Collection<java.lang.String> documentKinds)
Specify the document kinds to filter the Publications.- Parameters:
documentKinds- Collection of document kinds- Returns:
- a reference to this object - used to chain calls
-
documentKinds
public PublicationSettings documentKinds(java.lang.String documentKinds, java.lang.String... otherDocumentKinds)
-
getDocumentKindsList
public static java.util.List<java.lang.String> getDocumentKindsList()
Returns the list of document kinds defined in the properties.- Returns:
- List available document kinds
- See Also:
- "jcms.prop: properties with prefix 'file-document.kinds-group.'"
-
exactType
public PublicationSettings exactType()
Specify whether it only retrieves Publications of the type defined by the superType, and not child classes.- Returns:
- a reference to this object - used to chain calls
- See Also:
superType(Class),superType(String)
-
disableFileInput
public PublicationSettings disableFileInput()
Specify whether the file input is disabled for Publications of type FileDocument.- Returns:
- a reference to this object - used to chain calls
-
enableFileInput
public PublicationSettings enableFileInput()
Specify whether the file input is enabled for Publications of type FileDocument.- Returns:
- a reference to this object - used to chain calls
-
disableDropdown
public PublicationSettings disableDropdown()
Specify whether the dropdown menu is disabled.- Returns:
- a reference to this object - used to chain calls
-
-