private static HashMap<Integer, Bitmap> mBitmapCache;
mBitmapCache.put(R.drawable.bg1,object);
Run Code Online (Sandbox Code Playgroud)
R.drawable.bg1是int...但我想转换成Integer因为Hashmap采用Integer...并且在几秒内绘制多个对象时,它会创建一个影响代码性能的整数对象运行时...
android ×1