Use the valueOf factory methods pretty much everywhere.
These are the preferred way to get instances of Boolean, Byte, Short, Character, Integer, Long, Float, and Double object. It's always made sense for Boolean objects, and with 1.5 these factory methods were blessed as the proper way to get instances unless one absolutely needed a distinct object. git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4145 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
// $Id$
|
||||
//
|
||||
// Narya library - tools for developing networked games
|
||||
// Copyright (C) 2002-2005 Three Rings Design, Inc., All Rights Reserved
|
||||
// Copyright (C) 2002-2006 Three Rings Design, Inc., All Rights Reserved
|
||||
// http://www.threerings.net/code/narya/
|
||||
//
|
||||
// This library is free software; you can redistribute it and/or modify it
|
||||
@@ -52,7 +52,7 @@ public class ChatMarshaller extends InvocationMarshaller
|
||||
_invId = null;
|
||||
omgr.postEvent(new InvocationResponseEvent(
|
||||
callerOid, requestId, TELL_SUCCEEDED,
|
||||
new Object[] { new Long(arg1), arg2 }));
|
||||
new Object[] { Long.valueOf(arg1), arg2 }));
|
||||
}
|
||||
|
||||
// documentation inherited
|
||||
@@ -66,6 +66,7 @@ public class ChatMarshaller extends InvocationMarshaller
|
||||
|
||||
default:
|
||||
super.dispatchResponse(methodId, args);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
// $Id$
|
||||
//
|
||||
// Narya library - tools for developing networked games
|
||||
// Copyright (C) 2002-2005 Three Rings Design, Inc., All Rights Reserved
|
||||
// Copyright (C) 2002-2006 Three Rings Design, Inc., All Rights Reserved
|
||||
// http://www.threerings.net/code/narya/
|
||||
//
|
||||
// This library is free software; you can redistribute it and/or modify it
|
||||
@@ -43,7 +43,7 @@ public class SpeakMarshaller extends InvocationMarshaller
|
||||
public void speak (Client arg1, String arg2, byte arg3)
|
||||
{
|
||||
sendRequest(arg1, SPEAK, new Object[] {
|
||||
arg2, new Byte(arg3)
|
||||
arg2, Byte.valueOf(arg3)
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
//
|
||||
// $Id: SpeakObject.java,v 1.4 2004/08/27 02:12:31 mdb Exp $
|
||||
// $Id$
|
||||
//
|
||||
// Narya library - tools for developing networked games
|
||||
// Copyright (C) 2002-2004 Three Rings Design, Inc., All Rights Reserved
|
||||
|
||||
Reference in New Issue
Block a user