summaryrefslogtreecommitdiff
path: root/jurt/com
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2014-08-12 15:10:41 +0200
committerNoel Grandin <noel@peralex.com>2014-08-19 14:57:17 +0200
commit8a2c6c29af41cd7a62f37861fb0d4e81a857bb45 (patch)
tree87575bd76a2ce98793d2bb1773ddc4a9c4e5e41c /jurt/com
parentff0ad0493ee1729c726587f667761b04101d774c (diff)
java: use 'Long.valueOf' instead of 'new Long'
Change-Id: If4fff3dd37326fbcdd01b743355a16591d71fa69
Diffstat (limited to 'jurt/com')
-rw-r--r--jurt/com/sun/star/lib/uno/protocols/urp/Unmarshal.java2
-rw-r--r--jurt/com/sun/star/uno/AnyConverter.java10
2 files changed, 6 insertions, 6 deletions
diff --git a/jurt/com/sun/star/lib/uno/protocols/urp/Unmarshal.java b/jurt/com/sun/star/lib/uno/protocols/urp/Unmarshal.java
index b2776e23b66d..865bb0733bb7 100644
--- a/jurt/com/sun/star/lib/uno/protocols/urp/Unmarshal.java
+++ b/jurt/com/sun/star/lib/uno/protocols/urp/Unmarshal.java
@@ -234,7 +234,7 @@ final class Unmarshal {
private Long readHyperValue() {
try {
- return new Long(input.readLong());
+ return Long.valueOf(input.readLong());
} catch (IOException e) {
throw new RuntimeException(e.toString());
}
diff --git a/jurt/com/sun/star/uno/AnyConverter.java b/jurt/com/sun/star/uno/AnyConverter.java
index 9acdb1622e16..83819d51a89f 100644
--- a/jurt/com/sun/star/uno/AnyConverter.java
+++ b/jurt/com/sun/star/uno/AnyConverter.java
@@ -574,13 +574,13 @@ public class AnyConverter
case TypeClass.HYPER_value:
switch (tc) {
case TypeClass.BYTE_value:
- return new Long( ((Byte)object).byteValue() );
+ return Long.valueOf( ((Byte)object).byteValue() );
case TypeClass.SHORT_value:
case TypeClass.UNSIGNED_SHORT_value:
- return new Long( ((Short)object).shortValue() );
+ return Long.valueOf( ((Short)object).shortValue() );
case TypeClass.LONG_value:
case TypeClass.UNSIGNED_LONG_value:
- return new Long( ((Integer)object).intValue() );
+ return Long.valueOf( ((Integer)object).intValue() );
case TypeClass.HYPER_value:
return object;
}
@@ -588,9 +588,9 @@ public class AnyConverter
case TypeClass.UNSIGNED_HYPER_value:
switch (tc) {
case TypeClass.UNSIGNED_SHORT_value:
- return new Long( ((Short)object).shortValue() );
+ return Long.valueOf( ((Short)object).shortValue() );
case TypeClass.UNSIGNED_LONG_value:
- return new Long( ((Integer)object).intValue() );
+ return Long.valueOf( ((Integer)object).intValue() );
case TypeClass.UNSIGNED_HYPER_value:
return object;
}