Pass a message along with a FailureResponse.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4819 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -169,8 +169,7 @@ public class ClientDObjectMgr
|
||||
}
|
||||
|
||||
} else if (obj instanceof FailureResponse) {
|
||||
int oid = ((FailureResponse)obj).getOid();
|
||||
notifyFailure(oid);
|
||||
notifyFailure(((FailureResponse)obj).getOid(), ((FailureResponse)obj).getMessage());
|
||||
|
||||
} else if (obj instanceof PongResponse) {
|
||||
_client.gotPong((PongResponse)obj);
|
||||
@@ -303,7 +302,7 @@ public class ClientDObjectMgr
|
||||
* Notifies the subscribers that had requested this object (for subscription) that it is not
|
||||
* available.
|
||||
*/
|
||||
protected void notifyFailure (int oid)
|
||||
protected void notifyFailure (int oid, String message)
|
||||
{
|
||||
// let the penders know that the object is not available
|
||||
PendingRequest<?> req = _penders.remove(oid);
|
||||
@@ -313,8 +312,7 @@ public class ClientDObjectMgr
|
||||
}
|
||||
|
||||
for (int i = 0; i < req.targets.size(); i++) {
|
||||
// and let them know that the object is in
|
||||
req.targets.get(i).requestFailed(oid, null);
|
||||
req.targets.get(i).requestFailed(oid, new ObjectAccessException(message));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user