• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Devaka Cooray
  • Ron McLeod
  • Jeanne Boyarsky
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Carey Brown
  • Tim Holloway
Bartenders:
  • Martijn Verburg
  • Frits Walraven
  • Himai Minh

Generic Type Hashtable(K,V) should be parameterized

 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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


 
Bartender
Posts: 4179
22
IntelliJ IDE Python Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
 
Marshal
Posts: 76861
366
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Welcome to JavaRanch
Have a look at the section in the Java™ Tutorials.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic