开发者

Problem in computing SerialversionUID from the command prompt

开发者 https://www.devze.com 2023-03-02 03:28 出处:网络
Whenever I am trying to compute serialversionUID from the command prompt, I am getting \"Exception in thread \"main\" java.lang.NoClassDefFoundError: javax.servlet.http.HttpS开发者_JAVA技巧ervletReque

Whenever I am trying to compute serialversionUID from the command prompt, I am getting "Exception in thread "main" java.lang.NoClassDefFoundError: javax.servlet.http.HttpS开发者_JAVA技巧ervletRequest".

classpath is set correctly.I have j2ee.jar in my classpath.

Can anyone help me out.


You only really need to do this if you have already-serialized instances of the class and you've changed it and want to maintain serialization-compatibility with the existing serializations. Otherwise just use 1L or -1L.


Make sure that the JAR file containing javax.servlet.* is in your CLASSPATH.

0

精彩评论

暂无评论...
验证码 换一张
取 消