Viewing Issue Advanced Details
[ Jump to Notes ]
|
[ View Simple ]
[ Issue History ]
[ Print ]
|
ID |
Category |
Severity |
Reproducibility |
Date Submitted |
Last Update |
0002138 |
[Resin] |
minor |
always |
11-04-07 09:49 |
11-05-07 13:21 |
|
Reporter |
regor |
View Status |
public |
|
Assigned To |
ferg |
Priority |
normal |
Resolution |
fixed |
Platform |
|
Status |
closed |
|
OS |
|
Projection |
none |
|
OS Version |
|
ETA |
none |
Fixed in Version |
3.1.4 |
Product Version |
|
|
Product Build |
|
|
Summary |
0002138: Use Integer.valueOf(int) instead of new Integer(int) |
Description |
You should consider to use expressions like "Integer.valueOf(int)" instead of "new Integer(int)". The former returns Objects from an Object pool.
I saw this in Hessian's BasicDeserializer class. This is especially bad for Boolean and Byte Objects which fit entirely into the Object pool.
Cheers
-Roger |
Steps To Reproduce |
|
Additional Information |
|
|
Attached Files |
|
|