org.jdesktop.wonderland.client
Interface ClientPlugin

All Known Implementing Classes:
BaseClientPlugin

public interface ClientPlugin

Client plugins can implement this interface to add new functionality to the Wonderland client. The initialize method of the service will be called during the intialization of the client Main. It is guaranteed to be called after theclient context has been initialized, so plugins can use the context to get access to server resources.

Author:
kaplanj

Method Summary
 void cleanup()
          Clean up any resources used by this plugin.
 void initialize(ServerSessionManager loginInfo)
          Intialize this plugin.
 

Method Detail

initialize

void initialize(ServerSessionManager loginInfo)
Intialize this plugin. The plugin can use static object in the client such as the ClientContext to register itself with the Wonderland environment. In addition, a plugin is given the LoginManager for the WonderlandServer it is associated with.

Plugins are loaded after the client logs in to the given server, but before any WonderlandSessions have been created. Plugins that need to use a WonderlandSession can either create their own or (more typically) install a SessionLifecyclyListener to wait for session creation.

Parameters:
loginManager - the loginManager representing the server this plugin is connected to.

cleanup

void cleanup()
Clean up any resources used by this plugin. This is called when the client's login for the ServerSessionManager lapses due to logout, timeout, or other reasons. Plugins should clean up any registrations such as SessionLifecycleListeners or PrimaryServerListeners.



Open Wonderland - http://openwonderland.org