Package com.jalios.jcms.document.editor
Interface DocumentEditor
- All Known Implementing Classes:
AbstractDocumentEditor,ImageDocumentEditor
public interface DocumentEditor
This interface must be implemented by component that what provides a service to edit a document.
A DocumentEditor must be declared in properties with prefix
file-document. and suffix .class.
Example:
file-document.editor.mySuperEditor.class: com.jalios.jcmsplugin.mySuperEditor.MySuperEditorDocumentEditor- Since:
- jcms-10.0.3
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionbooleanaccept(FileDocument doc, Member mbr) Returns true if the editor accepts the member to edit the document.default booleanaccept(FileDocument doc, Member mbr, OpeningMode openingMode) Returns true if the editor accepts the member to edit the document.default StringgetButtonLabel(String lang, FileDocument doc, Member mbr) Return the localized label used for the button (if only this editor is available).getIcon(FileDocument doc, Member mbr) Returns the 16x16-sized icon of the editor (icon property name without the icon.default StringgetIcon48(FileDocument doc, Member mbr) Returns the 48x48-sized icon of the editor (icon property name without the icon.default StringgetKey()default StringReturns HTML attributes to add to the link.default StringgetLinkAttributes(String lang, FileDocument doc, Member mbr) Returns HTML attributes to add to the link.default StringReturns CSS classes to add to the link.default StringgetMenuLabel(String lang, FileDocument doc, Member mbr) Return the localized label used in the dropdown menu.default StringgetMenuLabel(String lang, FileDocument doc, Member mbr, OpeningMode openingMode) Return the localized label used in the dropdown menu.Returns the localized name of the editor.getUrl(FileDocument doc, Member mbr, String baseUrl) Returns the URL to open the document.default StringgetUrl(FileDocument doc, Member mbr, String baseUrl, OpeningMode openingMode) Returns the URL to open the document.default void
-
Field Details
-
READ_LABEL_PROP
- See Also:
-
EDIT_LABEL_PROP
- See Also:
-
-
Method Details
-
accept
Returns true if the editor accepts the member to edit the document.- Parameters:
doc- the documentmbr- the member- Returns:
- true if the editor accepts the member to edit the document.
- Since:
- jcms-10.0.3
-
accept
Returns true if the editor accepts the member to edit the document.- Parameters:
doc- the documentmbr- the memberopeningMode- the OpeningMode- Returns:
- true if the editor accepts the member to edit the document.
- Since:
- jcms-11.0.0
-
getUrl
Returns the URL to open the document.- Parameters:
doc- the documentmbr- the memberbaseUrl- the base URL of the site- Returns:
- the URL to edit the document.
- Since:
- jcms-10.0.3
-
getUrl
Returns the URL to open the document.- Parameters:
doc- the documentmbr- the memberbaseUrl- the base URL of the siteopeningMode- READ or WRITE (seeOpeningMode)- Returns:
- the URL to edit the document.
- Since:
- jcms-10.0.8
-
getName
Returns the localized name of the editor.- Parameters:
lang- the language- Returns:
- the localized name of the editor.
- Since:
- jcms-10.0.3
-
getIcon
Returns the 16x16-sized icon of the editor (icon property name without the icon. prefix).- Parameters:
doc- the documentmbr- the document- Returns:
- the icon of the editor.
- Since:
- jcms-10.0.3
-
getIcon48
Returns the 48x48-sized icon of the editor (icon property name without the icon. prefix)- Parameters:
doc- the documentmbr- the document- Returns:
- the icon of the editor.
- Since:
- jcms-10.0.8
-
getMenuLabel
Return the localized label used in the dropdown menu.- Parameters:
lang- the languagedoc- the documentmbr- the document- Returns:
- the localized label used in the dropdown menu.
- Since:
- jcms-10.0.3
-
getMenuLabel
Return the localized label used in the dropdown menu.- Parameters:
lang- the languagedoc- the documentmbr- the documentopeningMode- the OpeningMode- Returns:
- the localized label used in the dropdown menu.
- Since:
- jcms-11.0.0
-
getButtonLabel
Return the localized label used for the button (if only this editor is available).- Parameters:
lang- the languagedoc- the documentmbr- the document- Returns:
- the localized label used for the button (if only this editor is available).
- Since:
- jcms-10.0.3
-
getLinkCss
Returns CSS classes to add to the link.- Returns:
- CSS classes to add to the link.
- Since:
- jcms-10.0.3
-
getLinkAttributes
Returns HTML attributes to add to the link.- Returns:
- HTML attributes to add to the link.
- Since:
- jcms-10.0.3
-
getLinkAttributes
Returns HTML attributes to add to the link.- Parameters:
lang- the languagedoc- the documentmbr- the document- Returns:
- HTML attributes to add to the link.
- Since:
- jcms-10.0.6
-
getKey
-
setKey
-