Skip to content

Tag: java-6

Does WebLogic Server 14 support JDK 6?

I want to migrate to WebLogic server 14 but, Could the Weblogic server 14 support old java versions like 6? Answer The requirements for various versions of WebLogic can be found in a xls file downloadable from this page. WebLogic 14c, in particular, requires Java 8 or Java 11

Varargs in method overloading in Java

The following code doesn’t compile. A compile-time error is issued. reference to test is ambiguous, both method test(int…) in varargspkg.Main and method test(float…) in varargspkg.Main match It seems to be obvious because the parameter values in the method call test(1, 2); can be promoted to…

Get keys from HashMap in Java

I have a Hashmap in Java like this: Then I fill it like this: How can I get the keys? Something like: team1.getKey() to return “United”. Answer A HashMap contains more than one key. You can use keySet() to get the set of all keys. will store 1 with key “foo” and 2 with key “bar&#…

@override annotation in JDK 1.6

I’m using JDK1.6. When I implement an interface and in the implementing class, if I give @override before my function names, Eclipse throws an compilation error. i.e. below code is wrong according to Eclipse. If I remove @Override annotation, then the code compiles fine. Does it mean that JDK1.6 does no…