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:
@@ -341,7 +341,7 @@ public class SceneDirector extends BasicDirector
|
||||
}
|
||||
|
||||
// update our scene cache
|
||||
_scache.put(new Integer(model.sceneId), model);
|
||||
_scache.put(Integer.valueOf(model.sceneId), model);
|
||||
|
||||
// and pass through to the normal move succeeded handler
|
||||
moveSucceeded(placeId, config);
|
||||
@@ -446,7 +446,7 @@ public class SceneDirector extends BasicDirector
|
||||
protected SceneModel loadSceneModel (int sceneId)
|
||||
{
|
||||
// first look in the model cache
|
||||
Integer key = new Integer(sceneId);
|
||||
Integer key = Integer.valueOf(sceneId);
|
||||
SceneModel model = (SceneModel)_scache.get(key);
|
||||
|
||||
// load from the repository if it's not cached
|
||||
|
||||
Reference in New Issue
Block a user