Use Comparable for the to be removed distributed set key.

git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2290 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
Michael Bayne
2003-02-26 17:54:56 +00:00
parent 5ed8637ecf
commit 56b0012782
11 changed files with 26 additions and 26 deletions
@@ -1,5 +1,5 @@
//
// $Id: ClientObject.java,v 1.5 2002/11/26 02:14:24 mdb Exp $
// $Id: ClientObject.java,v 1.6 2003/02/26 17:54:56 mdb Exp $
package com.threerings.presents.data;
@@ -78,7 +78,7 @@ public class ClientObject extends DObject
* the <code>receivers</code> set. The set will not change until the
* event is actually propagated through the system.
*/
public void removeFromReceivers (Object key)
public void removeFromReceivers (Comparable key)
{
requestEntryRemove(RECEIVERS, key);
}
@@ -1,5 +1,5 @@
//
// $Id: DObject.java,v 1.58 2003/02/18 18:59:08 mdb Exp $
// $Id: DObject.java,v 1.59 2003/02/26 17:54:56 mdb Exp $
package com.threerings.presents.dobj;
@@ -787,7 +787,7 @@ public class DObject implements Streamable
/**
* Calls by derived instances when a set remover method was called.
*/
protected void requestEntryRemove (String name, Object key)
protected void requestEntryRemove (String name, Comparable key)
{
// dispatch an entry removed event
postEvent(new EntryRemovedEvent(_oid, name, key));
@@ -1,5 +1,5 @@
//
// $Id: EntryRemovedEvent.java,v 1.11 2002/12/20 23:29:04 mdb Exp $
// $Id: EntryRemovedEvent.java,v 1.12 2003/02/26 17:54:56 mdb Exp $
package com.threerings.presents.dobj;
@@ -23,7 +23,7 @@ public class EntryRemovedEvent extends NamedEvent
* specified entry.
* @param key the entry key that identifies the entry to remove.
*/
public EntryRemovedEvent (int targetOid, String name, Object key)
public EntryRemovedEvent (int targetOid, String name, Comparable key)
{
super(targetOid, name);
_key = key;
@@ -40,7 +40,7 @@ public class EntryRemovedEvent extends NamedEvent
/**
* Returns the key that identifies the entry that has been removed.
*/
public Object getKey ()
public Comparable getKey ()
{
return _key;
}
@@ -83,6 +83,6 @@ public class EntryRemovedEvent extends NamedEvent
buf.append(", key=").append(_key);
}
protected Object _key;
protected Comparable _key;
protected transient DSet.Entry _oldEntry;
}