|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.vaadin.terminal.gwt.client.ui.AbstractConnector
public abstract class AbstractConnector
An abstract implementation of Connector.
| Constructor Summary | |
|---|---|
AbstractConnector()
|
|
| Method Summary | ||
|---|---|---|
com.google.web.bindery.event.shared.HandlerRegistration |
addStateChangeHandler(StateChangeEvent.StateChangeHandler handler)
Adds a handler that is called whenever some part of the state has been updated by the server. |
|
void |
doInit(String connectorId,
ApplicationConnection connection)
Called once by the framework to initialize the connector. |
|
protected com.google.gwt.event.shared.HandlerManager |
ensureHandlerManager()
|
|
void |
fireEvent(com.google.gwt.event.shared.GwtEvent<?> event)
Sends the given event to all registered handlers. |
|
ApplicationConnection |
getConnection()
Gets ApplicationConnection instance that created this connector. |
|
String |
getConnectorId()
Returns the id for this connector. |
|
|
getRpcImplementations(String rpcInterfaceId)
For internal use by the framework: returns the registered RPC implementations for an RPC interface identifier. |
|
protected void |
init()
Called when the connector has been initialized. |
|
boolean |
isConnectorEnabled()
|
|
void |
onStateChanged(StateChangeEvent stateChangeEvent)
|
|
void |
onUnregister()
Event called when connector has been unregistered. |
|
protected
|
registerRpc(Class<T> rpcInterface,
T implementation)
Registers an implementation for a server to client RPC interface. |
|
protected
|
unregisterRpc(Class<T> rpcInterface,
T implementation)
Unregisters an implementation for a server to client RPC interface. |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.vaadin.terminal.gwt.client.ServerConnector |
|---|
isEnabled, setState |
| Methods inherited from interface com.vaadin.terminal.gwt.client.Connector |
|---|
getState |
| Constructor Detail |
|---|
public AbstractConnector()
| Method Detail |
|---|
public final ApplicationConnection getConnection()
ServerConnector
getConnection in interface ServerConnectorServerConnector.doInit(String, ApplicationConnection)public String getConnectorId()
Connector
getConnectorId in interface Connector
public final void doInit(String connectorId,
ApplicationConnection connection)
Note that the shared state is not yet available when this method is called.
Connector classes should override init() instead of this method.
doInit in interface ServerConnectorprotected void init()
protected <T extends ClientRpc> void registerRpc(Class<T> rpcInterface,
T implementation)
T - The type of the RPC interface that is being registeredrpcInterface - RPC interfaceimplementation - implementation that should receive RPC calls
protected <T extends ClientRpc> void unregisterRpc(Class<T> rpcInterface,
T implementation)
rpcInterface - RPC interfaceimplementation - implementation to unregisterpublic <T extends ClientRpc> Collection<T> getRpcImplementations(String rpcInterfaceId)
ServerConnector
getRpcImplementations in interface ServerConnectorrpcInterfaceId - RPC interface identifier: fully qualified interface type name
public boolean isConnectorEnabled()
public void fireEvent(com.google.gwt.event.shared.GwtEvent<?> event)
ServerConnector
fireEvent in interface ServerConnectorevent - The event to send.protected com.google.gwt.event.shared.HandlerManager ensureHandlerManager()
public com.google.web.bindery.event.shared.HandlerRegistration addStateChangeHandler(StateChangeEvent.StateChangeHandler handler)
ServerConnector
addStateChangeHandler in interface ServerConnectorhandler - The handler that should be added.
public void onStateChanged(StateChangeEvent stateChangeEvent)
onStateChanged in interface StateChangeEvent.StateChangeHandlerpublic void onUnregister()
ServerConnector
onUnregister in interface ServerConnector
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||