|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface ServerConnector
Interface implemented by all client side classes that can be communicate with the server. Classes implementing this interface are initialized by the framework when needed and have the ability to communicate with the server.
| Method Summary | ||
|---|---|---|
com.google.web.bindery.event.shared.HandlerRegistration |
addStateChangeHandler(StateChangeEvent.StateChangeHandler handler)
Adds a handler that is called whenever any part of the state has been updated by the server. |
|
com.google.web.bindery.event.shared.HandlerRegistration |
addStateChangeHandler(java.lang.String propertyName,
StateChangeEvent.StateChangeHandler handler)
Adds a handler that is called whenever the given part of the state has been updated by the server. |
|
void |
doInit(java.lang.String connectorId,
ApplicationConnection connection)
Called once by the framework to initialize the connector. |
|
void |
fireEvent(com.google.gwt.event.shared.GwtEvent<?> event)
Sends the given event to all registered handlers. |
|
java.util.List<ServerConnector> |
getChildren()
Returns the child connectors for this connector (child components and extensions). |
|
ApplicationConnection |
getConnection()
Gets ApplicationConnection instance that created this connector. |
|
ServerConnector |
getParent()
Returns the parent of this connector. |
|
|
getRpcImplementations(java.lang.String rpcInterfaceId)
For internal use by the framework: returns the registered RPC implementations for an RPC interface identifier. |
|
com.vaadin.shared.communication.SharedState |
getState()
Gets the current shared state of the connector. |
|
boolean |
hasEventListener(java.lang.String eventIdentifier)
Checks if an event listener has been registered on the server side for the given event identifier. |
|
boolean |
isEnabled()
Tests whether the connector is enabled or not. |
|
void |
onUnregister()
Event called when connector has been unregistered. |
|
void |
removeStateChangeHandler(StateChangeEvent.StateChangeHandler handler)
Removes a handler that is called whenever any part of the state has been updated by the server. |
|
void |
removeStateChangeHandler(java.lang.String propertyName,
StateChangeEvent.StateChangeHandler handler)
Removes a handler that is called whenever any part of the state has been updated by the server. |
|
void |
setChildren(java.util.List<ServerConnector> children)
Sets the children for this connector. |
|
void |
setParent(ServerConnector parent)
Sets the parent for this connector. |
|
void |
updateEnabledState(boolean enabledState)
|
|
| Methods inherited from interface com.vaadin.shared.Connector |
|---|
getConnectorId |
| Method Detail |
|---|
ApplicationConnection getConnection()
doInit(String, ApplicationConnection)boolean isEnabled()
void doInit(java.lang.String connectorId,
ApplicationConnection connection)
Note that the shared state is not yet available at this point nor any hierarchy information.
<T extends com.vaadin.shared.communication.ClientRpc> java.util.Collection<T> getRpcImplementations(java.lang.String rpcInterfaceId)
rpcInterfaceId - RPC interface identifier: fully qualified interface type name
com.google.web.bindery.event.shared.HandlerRegistration addStateChangeHandler(StateChangeEvent.StateChangeHandler handler)
handler - The handler that should be added.
void removeStateChangeHandler(StateChangeEvent.StateChangeHandler handler)
handler - The handler that should be removed.
com.google.web.bindery.event.shared.HandlerRegistration addStateChangeHandler(java.lang.String propertyName,
StateChangeEvent.StateChangeHandler handler)
propertyName - the name of the property for which the handler should be
calledhandler - The handler that should be added.
void removeStateChangeHandler(java.lang.String propertyName,
StateChangeEvent.StateChangeHandler handler)
propertyName - the name of the property for which the handler should be
calledhandler - The handler that should be removed.void fireEvent(com.google.gwt.event.shared.GwtEvent<?> event)
event - The event to send.void onUnregister()
ServerConnector getParent()
getParent in interface com.vaadin.shared.ConnectorsetParent(ServerConnector).void setParent(ServerConnector parent)
Note that calling this method does not fire a
ConnectorHierarchyChangeEvent. The event is fired only when the
whole hierarchy has been updated.
parent - The new parent of the connectorvoid updateEnabledState(boolean enabledState)
void setChildren(java.util.List<ServerConnector> children)
Note that this method is separate from
HasComponentsConnector.setChildComponents(List) and takes both
extensions and child components. Both methods are called separately by
the framework if the connector can have child components.
children - The new child connectors (extensions and/or components)java.util.List<ServerConnector> getChildren()
Note that the method HasComponentsConnector.getChildComponents()
can be used to obtain the subset of child connectors that correspond to
components and not extensions.
com.vaadin.shared.communication.SharedState getState()
SharedState. Never null.boolean hasEventListener(java.lang.String eventIdentifier)
eventIdentifier - The identifier for the event
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||