• Post Reply Bookmark Topic Watch Topic
  • New Topic

Generic Type Hashtable(K,V) should be parameterized  RSS feed

 
Manojkr Jadhav
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

my servlet working on local machin but not working on server machin
I have some error on servlets.

Type safety: The method put(Object, Object) belongs to the raw type Hashtable. References to
generic type Hashtable<K,V> should be parameterized


please reply me.

Thanks & Regards
Manoj Jadhav


 
Steve Luke
Bartender
Posts: 4181
22
IntelliJ IDE Java Python
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Manoj,

I moved this thread out of IDEs and into Java in General, because it is more of a general type of question.

The problem comes in part from your use of generics, and may have different versions of Java running between the server and the development machine. The first thing to do is to make sure your local development machine is set up exactly like the real server.

It would be useful if you showed us some of the code pertinent to the error. Lines of code that would be helpful would include:
1) Where (and around where) the error is occurring
2) Where the Map which is being used is created
 
Campbell Ritchie
Marshal
Posts: 56546
172
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to JavaRanch
Have a look at the section in the Java™ Tutorials.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!