Package org.opencms.ugc.client.export
Class CmsXmlContentUgcApi
java.lang.Object
org.opencms.ugc.client.export.CmsXmlContentUgcApi
- All Implemented Interfaces:
org.timepedia.exporter.client.Exportable
Root access point for the Javascript form editing API exported with gwt-exporter. Can be used
to acquire new form editing sessions.
-
Field Summary
Modifier and TypeFieldDescriptionstatic final org.opencms.ugc.shared.rpc.I_CmsUgcEditServiceAsync
Service instance.static final String
The service URL. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionGets the request counter.Creates an RPC helper object.void
handleError
(Throwable e, I_CmsErrorCallback callback) Passes an exception to the given error handling callback and optionally outputs some debug info.void
initFormForSession
(String sessionId, com.google.gwt.dom.client.Element formElement, I_CmsClientCmsUgcSessionCallback onSuccess, I_CmsErrorCallback onError) Loads a pre-created session.void
setErrorCallback
(I_CmsStringArrayCallback callback) Sets the error callback for all uncaught exceptions.void
setWaitIndicatorCallback
(I_CmsBooleanCallback callback) Sets the wait indicator callback.
-
Field Details
-
SERVICE
Service instance. -
SERVICE_URL
The service URL.
-
-
Constructor Details
-
CmsXmlContentUgcApi
public CmsXmlContentUgcApi()Default constructor for gwt-exporter.
-
-
Method Details
-
getRequestCounter
Gets the request counter.- Returns:
- the request counter
-
getRpcHelper
Creates an RPC helper object.- Returns:
- the RPC helper
-
handleError
Passes an exception to the given error handling callback and optionally outputs some debug info.- Parameters:
e
- the exceptioncallback
- the error handling callback
-
initFormForSession
public void initFormForSession(String sessionId, com.google.gwt.dom.client.Element formElement, I_CmsClientCmsUgcSessionCallback onSuccess, I_CmsErrorCallback onError) Loads a pre-created session.- Parameters:
sessionId
- the session idformElement
- the form elementonSuccess
- the callback to call in case of successonError
- the callback to call in case of an error
-
setErrorCallback
Sets the error callback for all uncaught exceptions.- Parameters:
callback
- the error callback
-
setWaitIndicatorCallback
Sets the wait indicator callback.- Parameters:
callback
- a callback used to switch the wait indicator off or on.
-