Annotation to mark serial-related fields and methods

XMLWordPrintable

    • Type: Enhancement
    • Resolution: Fixed
    • Priority: P3
    • 14
    • Affects Version/s: 11
    • Component/s: core-libs
    • b11

      The serialization related fields (serialVersionUID and serialPersistentFields) and methods (writeObject, writeReplace, readObject, readObjectNoData, readResolve), have names that are possible to misspell. The serialization mechanism will silently ignore misspelled (or otherwise misdeclared) fields and methods.

      Similar to how the java.lang.Override annotation type is used to signal the compiler should verify the method is in fact overridden, it would be helpful to some kind of "SerialRelated" annotation to facilitate automated checking of the declarations of serial fields and methods.

            Assignee:
            Joe Darcy
            Reporter:
            Joe Darcy
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: