Package org.opencms.gwt
Class CmsGwtActionElement
java.lang.Object
org.opencms.jsp.CmsJspBean
org.opencms.jsp.CmsJspActionElement
org.opencms.gwt.CmsGwtActionElement
- Direct Known Subclasses:
CmsContainerpageActionElement
,CmsContentEditorActionElement
,CmsEditProviderActionElement
,CmsGalleryActionElement
,CmsPostUploadDialogActionElement
,CmsPropertiesActionElement
,CmsPublishActionElement
,CmsSitemapActionElement
,CmsUploadActionElement
Sitemap action used to generate the sitemap editor.
see jsp file /system/workplace/commons/sitemap.jsp.
- Since:
- 8.0.0
-
Field Summary
Modifier and TypeFieldDescriptionprotected static final String
The closing script tag.protected static final String
The opening script tag.Fields inherited from class org.opencms.jsp.CmsJspActionElement
NOT_INITIALIZED
-
Constructor Summary
ConstructorDescriptionCmsGwtActionElement
(javax.servlet.jsp.PageContext context, javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse res) Constructor. -
Method Summary
Modifier and TypeMethodDescriptioncreateNoCacheScript
(String moduleName) Deprecated.static String
createNoCacheScript
(String moduleName, String moduleVersion) Returns the script tag for the "*.nocache.js".export()
Returns the serialized data for the core provider wrapped in a script tag.export
(boolean includeFontCss) Returns the serialized data for the core provider wrapped into a script tag.Returns the serialized data for the core provider.static String
exportCommon
(CmsObject cms, CmsCoreData coreData) Returns the serialized data for the core provider wrapped into a script tag.static String
exportDictionary
(String name, Method method, Object data) Serializes the result of the given method for RPC-prefetching.static String
exportDictionary
(String name, String data) Exports a dictionary by the given name as the content attribute of a meta tag.static String
exportMeta
(String name, String data) Generates the HTML for a meta tag with given name and content.protected String
exportModuleScriptTag
(String moduleName) Exports script tag to the main OpenCms GWT no-cache js script tag.Returns the needed server data for client-side usage.static String
Returns the OpenCms font icon CSS link.Returns the workplace locale for the current user.static String
Serializes the result of the given method for RPC-prefetching.static String
wrapScript
(String... s) Concatenates the given strings and surrounds them with script tags.Methods inherited from class org.opencms.jsp.CmsJspActionElement
editable, editable, editable, editableManualClose, editableManualOpen, getContent, getContent, getMessages, getMessages, getMessages, getMessages, getNavigation, getNavigationUri, img, img, include, include, include, include, include, include, includeSilent, includeSilent, includeSilent, includeSilent, info, label, link, link, properties, properties, property, property, property, property, template, template, template, toAbsolute, user
Methods inherited from class org.opencms.jsp.CmsJspBean
getCmsObject, getController, getJspContext, getMessage, getRequest, getRequestContext, getResponse, handleException, handleMissingFlexController, init, isNotInitialized, isSupressingExceptions, setContentType, setStatus, setSupressingExceptions
-
Field Details
-
SCRIPT_TAG_CLOSE
The closing script tag.- See Also:
-
SCRIPT_TAG_OPEN
The opening script tag.- See Also:
-
-
Constructor Details
-
CmsGwtActionElement
public CmsGwtActionElement(javax.servlet.jsp.PageContext context, javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse res) Constructor.- Parameters:
context
- the JSP page context objectreq
- the JSP requestres
- the JSP response
-
-
Method Details
-
createNoCacheScript
Returns the script tag for the "*.nocache.js".- Parameters:
moduleName
- the module name to get the script tag formoduleVersion
- the module version- Returns:
- the
"<script>"
tag for the "*.nocache.js".
-
exportDictionary
public static String exportDictionary(String name, Method method, Object data) throws com.google.gwt.user.client.rpc.SerializationException Serializes the result of the given method for RPC-prefetching.- Parameters:
name
- the dictionary namemethod
- the methoddata
- the result to serialize- Returns:
- the serialized data
- Throws:
com.google.gwt.user.client.rpc.SerializationException
- if something goes wrong
-
exportDictionary
Exports a dictionary by the given name as the content attribute of a meta tag.- Parameters:
name
- the dictionary namedata
- the data- Returns:
- the meta tag
-
exportMeta
Generates the HTML for a meta tag with given name and content.- Parameters:
name
- the name of the meta tagdata
- the content of the meta tag- Returns:
- the HTML for the meta tag
-
getFontIconCssLink
Returns the OpenCms font icon CSS link.- Returns:
- the CSS link
-
serialize
public static String serialize(Method method, Object data) throws com.google.gwt.user.client.rpc.SerializationException Serializes the result of the given method for RPC-prefetching.- Parameters:
method
- the methoddata
- the result to serialize- Returns:
- the serialized data
- Throws:
com.google.gwt.user.client.rpc.SerializationException
- if something goes wrong
-
wrapScript
Concatenates the given strings and surrounds them with script tags.- Parameters:
s
- the array of strings to concatenate and wrap- Returns:
- the concatenation of the input strings, wrapped in script tags
-
createNoCacheScript
Deprecated.Returns the script tag for the "*.nocache.js".- Parameters:
moduleName
- the module name to get the script tag for- Returns:
- the
"<script>"
tag for the "*.nocache.js".
-
export
Returns the serialized data for the core provider wrapped in a script tag.- Returns:
- the data
- Throws:
Exception
- if something goes wrong
-
export
Returns the serialized data for the core provider wrapped into a script tag.- Parameters:
includeFontCss
-true
to include the OpenCms font CSS, not necessary in case VAADIN theme is loaded also- Returns:
- the data
- Throws:
Exception
- if something goes wrong
-
exportAll
Returns the serialized data for the core provider.- Returns:
- the data
- Throws:
Exception
- if something goes wrong
-
getCoreData
Returns the needed server data for client-side usage.- Returns:
- the needed server data for client-side usage
-
getWorkplaceLocale
Returns the workplace locale for the current user.- Returns:
- the workplace locale
-
exportModuleScriptTag
Exports script tag to the main OpenCms GWT no-cache js script tag.- Parameters:
moduleName
- the client module to start- Returns:
- the HTML string
-