I saw a piece of java code using Hashmap as follows:
Map indata = new HashMap(12);
//load data
indata.put(“checking”, ((object) new Double(1.0)));
indata.put(“PURPOSE”, ((object)"2”));
What confuse me is the two useages of "put" method, in which we have ((object) new Double(1.0))
and (object)"2". What do (object) function here? Any differences between ((object) new Double(1.0))
and (object)"2"?
objectin java.