org.elkoserver.server.presence
Interface SocialGraph


public interface SocialGraph

Interface representing an entire social graph, irrespective of its underlying semantics or storage implementation.


Method Summary
 org.elkoserver.server.presence.Domain domain()
          Obtain the domain that this social graph describes.
 void init(org.elkoserver.server.presence.PresenceServer master, org.elkoserver.server.presence.Domain domain, JSONObject conf)
          Initialize this social graph.
 void loadUserGraph(org.elkoserver.server.presence.ActiveUser user)
          Fetch the social graph for a new user presence from persistant storage.
 void shutdown()
          Do any work required prior to shutting down the server.
 void update(org.elkoserver.server.presence.PresenceServer master, org.elkoserver.server.presence.Domain domain, JSONObject conf)
          Update this social graph.
 

Method Detail

init

void init(org.elkoserver.server.presence.PresenceServer master,
          org.elkoserver.server.presence.Domain domain,
          JSONObject conf)
Initialize this social graph.

Parameters:
master - The object representing the presence server environment in which this graph will be used.
domain - The domain for which this graph is the applicable description.
conf - A JSONObject full of configuration information, whose particulars depend on the class implementing this interface.

loadUserGraph

void loadUserGraph(org.elkoserver.server.presence.ActiveUser user)
Fetch the social graph for a new user presence from persistant storage. Implementors of this method must then invoke the user's userGraphIsReady() method to inform the system that the graph information can now be used.

Parameters:
user - The user whose social graph should be fetched.

domain

org.elkoserver.server.presence.Domain domain()
Obtain the domain that this social graph describes.

Returns:
this social graph's domain.

update

void update(org.elkoserver.server.presence.PresenceServer master,
            org.elkoserver.server.presence.Domain domain,
            JSONObject conf)
Update this social graph.

Parameters:
master - The object representing the presence server environment in which this graph is being used.
domain - The domain being updated.
conf - A JSONObject full of Domain-specific configuration update information, whose particulars depend on the class implementing this interface.

shutdown

void shutdown()
Do any work required prior to shutting down the server. This method will be called by the PresenceServer as part of its orderly shutdown procedure.