Package io.goobi.viewer.websockets
Class ConfigEditorEndpoint
java.lang.Object
io.goobi.viewer.websockets.ConfigEditorEndpoint
Endpoint for unlocking files opened in
AdminConfigEditorBean when leaving a page.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidCalled when leaving a adminConfigEditor page.voidvoidAccept messages containing a file path which is locked by the curren page and needs to be unlocked upon leaving the page.voidonOpen(Session session, EndpointConfig config) Store id of http session.
-
Constructor Details
-
ConfigEditorEndpoint
public ConfigEditorEndpoint()
-
-
Method Details
-
onOpen
Store id of http session.- Parameters:
session- WebSocket session being openedconfig- endpoint configuration providing HTTP session properties
-
onMessage
Accept messages containing a file path which is locked by the curren page and needs to be unlocked upon leaving the page.- Parameters:
message- a json object string in the form "{'fileToLock' : '/path/to/config/file'}"
-
onClose
Called when leaving a adminConfigEditor page. Unlocks the file set byonMessage(String)for the session set byonOpen(Session, EndpointConfig)usingAdminConfigEditorBean.unlockFile(Path, String)- Parameters:
session- WebSocket session being closed
-
onError
-