equal
deleted
inserted
replaced
153 |
153 |
154 /** |
154 /** |
155 * The era value. |
155 * The era value. |
156 * @serial |
156 * @serial |
157 */ |
157 */ |
158 private final int eraValue; |
158 private final transient int eraValue; |
159 |
159 |
160 // the first day of the era |
160 // the first day of the era |
161 private final transient LocalDate since; |
161 private final transient LocalDate since; |
162 |
162 |
163 /** |
163 /** |
369 public String toString() { |
369 public String toString() { |
370 return getName(); |
370 return getName(); |
371 } |
371 } |
372 |
372 |
373 //----------------------------------------------------------------------- |
373 //----------------------------------------------------------------------- |
|
374 /** |
|
375 * Writes the object using a |
|
376 * <a href="../../../serialized-form.html#java.time.chrono.Ser">dedicated serialized form</a>. |
|
377 * @serialData |
|
378 * <pre> |
|
379 * out.writeByte(5); // identifies a JapaneseEra |
|
380 * out.writeInt(getValue()); |
|
381 * </pre> |
|
382 * |
|
383 * @return the instance of {@code Ser}, not null |
|
384 */ |
374 private Object writeReplace() { |
385 private Object writeReplace() { |
375 return new Ser(Ser.JAPANESE_ERA_TYPE, this); |
386 return new Ser(Ser.JAPANESE_ERA_TYPE, this); |
376 } |
387 } |
377 |
388 |
378 void writeExternal(DataOutput out) throws IOException { |
389 void writeExternal(DataOutput out) throws IOException { |