serialVersionUID
Eclipse3.1をやっとこ使い始めました。J2SE1.4.2用のソースをEclipse3.1で開いてみたら、
The serializable class BankAccount does not declare a static final serialVersionUID
なんていうWarningが出ました。Compiler Compliance Levelを1.4に指定しているんだから5.0向けのメッセージは表示しないでほしいなー。
ちなみにPreferencesあるいはプロジェクトのPropertiesから、[Java Compiler]-[Errors/Warnings]-[Potential programming problems]-[Serializable class without serialVersionUID]でproblemsに表示するレベルを指定できます。
それからパッケージ名に5.0の予約語であるenumを含んだものがあると、こんなメッセージがでます。
'enum' should not be used as an identifier, since it is a reserved keyword from source level 5.0 on
こっちは、PreferencesあるいはプロジェクトのPropertiesから、[Java Compiler]の[JDK Compliance]の[Use default compliance settings]のチェックを外し、[Disallow identifiers called 'enum']で指定できます。