com.vaadin.server.communication
Class ServerRpcHandler
java.lang.Object
com.vaadin.server.communication.ServerRpcHandler
- All Implemented Interfaces:
- java.io.Serializable
public class ServerRpcHandler
- extends java.lang.Object
- implements java.io.Serializable
Handles a client-to-server message containing serialized server RPC
invocations.
- Since:
- 7.1
- Author:
- Vaadin Ltd
- See Also:
- Serialized Form
Nested Class Summary |
static class |
ServerRpcHandler.RpcRequest
A data transfer object representing an RPC request sent by the client
side. |
Method Summary |
protected void |
changeVariables(java.lang.Object source,
VariableOwner owner,
java.util.Map<java.lang.String,java.lang.Object> m)
|
static java.lang.String |
getIgnoredDisabledError(java.lang.String what,
ClientConnector connector)
Generates an error message when the client is trying to to something
('what') with a connector which is disabled or invisible. |
protected java.lang.String |
getMessage(java.io.Reader reader)
|
void |
handleRpc(UI ui,
java.io.Reader reader,
VaadinRequest request)
Reads JSON containing zero or more serialized RPC calls (including legacy
variable changes) and executes the calls. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ServerRpcHandler
public ServerRpcHandler()
handleRpc
public void handleRpc(UI ui,
java.io.Reader reader,
VaadinRequest request)
throws java.io.IOException,
LegacyCommunicationManager.InvalidUIDLSecurityKeyException
- Reads JSON containing zero or more serialized RPC calls (including legacy
variable changes) and executes the calls.
- Parameters:
ui
- The UI
receiving the calls. Cannot be null.reader
- The Reader
used to read the JSON.request
-
- Throws:
java.io.IOException
- If reading the message fails.
LegacyCommunicationManager.InvalidUIDLSecurityKeyException
- If the received security key does not match the one stored in
the session.
changeVariables
protected void changeVariables(java.lang.Object source,
VariableOwner owner,
java.util.Map<java.lang.String,java.lang.Object> m)
getMessage
protected java.lang.String getMessage(java.io.Reader reader)
throws java.io.IOException
- Throws:
java.io.IOException
getIgnoredDisabledError
public static java.lang.String getIgnoredDisabledError(java.lang.String what,
ClientConnector connector)
- Generates an error message when the client is trying to to something
('what') with a connector which is disabled or invisible.
- Parameters:
connector
- the connector which is disabled (or invisible)
- Returns:
- an error message
- Since:
- 7.1.8
Copyright © 2000-2014 Vaadin Ltd. All Rights Reserved.