• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

missing Integer class

 
Amrita Chaurasia
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
while trying to create an instance of Integer Class..the compiler says there in no such constructor
Integer i = new Integer(1);

but there is no problem with other wrapper classes..
what should i do
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You don't have a class called Integer somewhere in your classpath, do you ? One that you made yourself.
 
Vijitha Kumara
Bartender
Pie
Posts: 3930
21
Chrome Fedora Hibernate
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can you post your code?
 
Amrita Chaurasia
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
oh I got the mistake..
I had my own Integer Class that existed in classpath
so it dint take java.lang.Integer class
 
Consider Paul's rocket mass heater.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic