Fedora Linux Support Community & Resources Center
  #1  
Old 1st February 2007, 06:47 PM
Tux_in_Redhat Offline
Registered User
 
Join Date: Jan 2007
Posts: 166
Arrow Those annoying Java warnings...

I don't know if I need the code, but whenever I compile something with an inner class, or some sort of "extends," I get this warning message:
Code:
the serializable class <classname> does not declare a static final serialVersionUID field of type long
I figure the program will run despite the warnings, but I want to get rid of those pesky things. I found some instructions for Eclipse, but because of my small hard drive and little memory, it's too big to load, so I have to use the command line. I compile the project by saying
Code:
javac <folder with classes>
__________________
There's no such thing as a stupid computer...
...Just Widnows Vista.
:rolleyes:
Note: I have FC5 with no Internet and a small 5G hard drive( :( )
I would prefer to have .rpm packages, but for simple stuff (like tutorials), .tar.gz type files are good.
Reply With Quote
  #2  
Old 15th February 2007, 10:31 PM
Shakes Offline
Registered User
 
Join Date: Feb 2005
Location: Scotland
Posts: 445
Try

Code:
javac -nowarn blah
You might not want the disabling of all warnings though.
http://help.eclipse.org/help32/index...pi_compile.htm
Reply With Quote
  #3  
Old 16th February 2007, 10:06 PM
Tux_in_Redhat Offline
Registered User
 
Join Date: Jan 2007
Posts: 166
I suppose the program will run just fine without the warnings right?
My java libraries are pretty sparse anyway: I don't have any exception classes, or the applet class, or basically any helpful class
__________________
There's no such thing as a stupid computer...
...Just Widnows Vista.
:rolleyes:
Note: I have FC5 with no Internet and a small 5G hard drive( :( )
I would prefer to have .rpm packages, but for simple stuff (like tutorials), .tar.gz type files are good.
Reply With Quote
  #4  
Old 16th February 2007, 11:34 PM
giulix Offline
"Fixed" by (vague) request
 
Join Date: Oct 2005
Location: GMT+ 1
Posts: 2,950
Eclipse generates this line of code automatically for each new class, always the same:
Code:
private static final long serialVersionUID = 1L;
This will get rid of the warnings, too..
Reply With Quote
Reply

Tags
annoying, java, warnings

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
aannoying,annoying and annoying java phrgarek Using Fedora 6 29th August 2007 02:28 PM
CANNOT get java installed into core6 this is so annoying ! dak Installation, Upgrades and Live Media 4 2nd May 2007 02:24 PM
If it weren't for warnings, schwim Wibble 3 6th February 2007 12:55 PM
Sun java and tomcat warnings pedrobl Using Fedora 0 11th May 2006 02:58 AM
YUM Warnings Freddan Using Fedora 8 5th April 2005 03:58 PM


Current GMT-time: 08:12 (Wednesday, 01-10-2014)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat