src/java.base/share/classes/java/time/chrono/HijrahDate.java
changeset 57956 e0b8b019d2f5
parent 52078 4a63197816ce
equal deleted inserted replaced
57955:18863bf3501f 57956:e0b8b019d2f5
     1 /*
     1 /*
     2  * Copyright (c) 2012, 2018, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2012, 2019, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.  Oracle designates this
     7  * published by the Free Software Foundation.  Oracle designates this
   121         implements ChronoLocalDate, Serializable {
   121         implements ChronoLocalDate, Serializable {
   122 
   122 
   123     /**
   123     /**
   124      * Serialization version.
   124      * Serialization version.
   125      */
   125      */
       
   126     @java.io.Serial
   126     private static final long serialVersionUID = -5207853542612002020L;
   127     private static final long serialVersionUID = -5207853542612002020L;
   127     /**
   128     /**
   128      * The Chronology of this HijrahDate.
   129      * The Chronology of this HijrahDate.
   129      */
   130      */
   130     private final transient HijrahChronology chrono;
   131     private final transient HijrahChronology chrono;
   655      * Defend against malicious streams.
   656      * Defend against malicious streams.
   656      *
   657      *
   657      * @param s the stream to read
   658      * @param s the stream to read
   658      * @throws InvalidObjectException always
   659      * @throws InvalidObjectException always
   659      */
   660      */
       
   661     @java.io.Serial
   660     private void readObject(ObjectInputStream s) throws InvalidObjectException {
   662     private void readObject(ObjectInputStream s) throws InvalidObjectException {
   661         throw new InvalidObjectException("Deserialization via serialization delegate");
   663         throw new InvalidObjectException("Deserialization via serialization delegate");
   662     }
   664     }
   663 
   665 
   664     /**
   666     /**
   673      *  out.writeByte(get(DAY_OF_MONTH));
   675      *  out.writeByte(get(DAY_OF_MONTH));
   674      * </pre>
   676      * </pre>
   675      *
   677      *
   676      * @return the instance of {@code Ser}, not null
   678      * @return the instance of {@code Ser}, not null
   677      */
   679      */
       
   680     @java.io.Serial
   678     private Object writeReplace() {
   681     private Object writeReplace() {
   679         return new Ser(Ser.HIJRAH_DATE_TYPE, this);
   682         return new Ser(Ser.HIJRAH_DATE_TYPE, this);
   680     }
   683     }
   681 
   684 
   682     void writeExternal(ObjectOutput out) throws IOException {
   685     void writeExternal(ObjectOutput out) throws IOException {