< prev index next >

src/java.base/share/classes/java/time/chrono/ChronoPeriodImpl.java

Print this page

        

@@ -96,10 +96,11 @@
     // this class is only used by JDK chronology implementations and makes assumptions based on that fact
 
     /**
      * Serialization version.
      */
+    @java.io.Serial
     private static final long serialVersionUID = 57387258289L;
 
     /**
      * The set of supported units.
      */

@@ -364,20 +365,22 @@
      *  out.writeInt(days);
      * </pre>
      *
      * @return the instance of {@code Ser}, not null
      */
+    @java.io.Serial
     protected Object writeReplace() {
         return new Ser(Ser.CHRONO_PERIOD_TYPE, this);
     }
 
     /**
      * Defend against malicious streams.
      *
      * @param s the stream to read
      * @throws InvalidObjectException always
      */
+    @java.io.Serial
     private void readObject(ObjectInputStream s) throws ObjectStreamException {
         throw new InvalidObjectException("Deserialization via serialization delegate");
     }
 
     void writeExternal(DataOutput out) throws IOException {
< prev index next >