diff --git a/src/java/com/threerings/presents/data/InvocationMarshaller.java b/src/java/com/threerings/presents/data/InvocationMarshaller.java index b2b140c3e..cdfaa89ec 100644 --- a/src/java/com/threerings/presents/data/InvocationMarshaller.java +++ b/src/java/com/threerings/presents/data/InvocationMarshaller.java @@ -1,5 +1,5 @@ // -// $Id: InvocationMarshaller.java,v 1.1 2002/08/14 19:07:55 mdb Exp $ +// $Id: InvocationMarshaller.java,v 1.2 2002/09/20 04:52:49 mdb Exp $ package com.threerings.presents.data; @@ -107,6 +107,14 @@ public class InvocationMarshaller _invOid = invOid; } + /** + * Returns the code assigned to this marshaller. + */ + public int getInvocationCode () + { + return _invCode; + } + /** * Called by generated invocation marshaller code; packages up and * sends the specified invocation service request. diff --git a/src/java/com/threerings/presents/server/InvocationManager.java b/src/java/com/threerings/presents/server/InvocationManager.java index 262e261b1..baf3f4407 100644 --- a/src/java/com/threerings/presents/server/InvocationManager.java +++ b/src/java/com/threerings/presents/server/InvocationManager.java @@ -1,5 +1,5 @@ // -// $Id: InvocationManager.java,v 1.13 2002/09/06 01:49:23 mdb Exp $ +// $Id: InvocationManager.java,v 1.14 2002/09/20 04:52:49 mdb Exp $ package com.threerings.presents.server; @@ -112,6 +112,19 @@ public class InvocationManager return marsh; } + /** + * Clears out a dispatcher registration. This should be called to free + * up resources when an invocation service is no longer going to be + * used. + */ + public void clearDispatcher (InvocationMarshaller marsh) + { + if (_dispatchers.remove(marsh.getInvocationCode()) == null) { + Log.warning("Requested to remove unregistered marshaller? " + + "[marsh=" + marsh + "]."); + } + } + public void objectAvailable (DObject object) { // this must be our invocation object