Allow a SceneService.moveTo() to respond by requesting that the client move to

a new server and reissue its request, which it, in theory, now does.


git-svn-id: svn+ssh://src.earth.threerings.net/vilya/trunk@354 c613c5cb-e716-0410-b11b-feb51c14d237
This commit is contained in:
Michael Bayne
2007-07-13 21:59:46 +00:00
parent 6a77a7e1f1
commit d5023554e8
9 changed files with 224 additions and 173 deletions
@@ -30,8 +30,8 @@ import com.threerings.whirled.data.SceneModel;
import com.threerings.whirled.data.SceneUpdate;
/**
* The scene service class provides the client interface to the scene
* related invocation services (e.g. moving from scene to scene).
* The scene service class provides the client interface to the scene related invocation services
* (e.g. moving from scene to scene).
*/
public interface SceneService extends InvocationService
{
@@ -49,38 +49,39 @@ public interface SceneService extends InvocationService
public void moveSucceeded (int placeId, PlaceConfig config);
/**
* Indicates that a move succeeded and that the client's cached
* scene information should be updated with the supplied data.
* Indicates that a move succeeded and that the client's cached scene information should be
* updated with the supplied data.
*
* @param placeId the place object id of the newly occupied scene.
* @param config metadata related to the newly occupied scene.
* @param updates updates that must be applied to the client's
* copy of a scene model to bring it up to date.
* @param updates updates that must be applied to the client's copy of a scene model to
* bring it up to date.
*/
public void moveSucceededWithUpdates (int placeId, PlaceConfig config,
SceneUpdate[] updates);
public void moveSucceededWithUpdates (
int placeId, PlaceConfig config, SceneUpdate[] updates);
/**
* Indicates that a move succeeded and that the client's cached
* scene information should be updated with the supplied data.
* Indicates that a move succeeded and that the client's cached scene information should be
* updated with the supplied data.
*
* @param placeId the place object id of the newly occupied scene.
* @param config metadata related to the newly occupied scene.
* @param model a fresh copy of the most recent scene data for the
* newly occupied scene.
* @param model a fresh copy of the most recent scene data for the newly occupied scene.
*/
public void moveSucceededWithScene (int placeId, PlaceConfig config,
SceneModel model);
public void moveSucceededWithScene (int placeId, PlaceConfig config, SceneModel model);
/**
* Indicates that the client must switch to the specified server and reissue its move
* request in order to relocate to its desired scene.
*/
public void moveRequiresServerSwitch (String hostname, int[] ports);
}
/**
* Requests that that this client's body be moved to the specified
* scene.
* Requests that that this client's body be moved to the specified scene.
*
* @param sceneId the scene id to which we want to move.
* @param version the version number of the scene object that we have
* in our local repository.
* @param version the version number of the scene object that we have in our local repository.
*/
public void moveTo (Client client, int sceneId, int version,
SceneMoveListener listener);
public void moveTo (Client client, int sceneId, int version, SceneMoveListener listener);
}