src/java.base/share/classes/java/net/SocketPermission.java
changeset 57956 e0b8b019d2f5
parent 53018 8bf9268df0e2
child 58242 94bb65cb37d3
--- a/src/java.base/share/classes/java/net/SocketPermission.java	Thu Aug 29 18:52:30 2019 -0400
+++ b/src/java.base/share/classes/java/net/SocketPermission.java	Thu Aug 29 16:31:34 2019 -0700
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2019, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -150,6 +150,7 @@
 public final class SocketPermission extends Permission
     implements java.io.Serializable
 {
+    @java.io.Serial
     private static final long serialVersionUID = -7204263841984476862L;
 
     /**
@@ -1186,6 +1187,7 @@
      * to a stream. The actions are serialized, and the superclass
      * takes care of the name.
      */
+    @java.io.Serial
     private synchronized void writeObject(java.io.ObjectOutputStream s)
         throws IOException
     {
@@ -1200,6 +1202,7 @@
      * readObject is called to restore the state of the SocketPermission from
      * a stream.
      */
+    @java.io.Serial
     private synchronized void readObject(java.io.ObjectInputStream s)
          throws IOException, ClassNotFoundException
     {
@@ -1448,6 +1451,7 @@
         return (Enumeration)Collections.enumeration(perms.values());
     }
 
+    @java.io.Serial
     private static final long serialVersionUID = 2787186408602843674L;
 
     // Need to maintain serialization interoperability with earlier releases,
@@ -1463,6 +1467,7 @@
      * @serialField permissions java.util.Vector
      *     A list of the SocketPermissions for this set.
      */
+    @java.io.Serial
     private static final ObjectStreamField[] serialPersistentFields = {
         new ObjectStreamField("permissions", Vector.class),
     };
@@ -1474,6 +1479,7 @@
      * Writes the contents of the perms field out as a Vector for
      * serialization compatibility with earlier releases.
      */
+    @java.io.Serial
     private void writeObject(ObjectOutputStream out) throws IOException {
         // Don't call out.defaultWriteObject()
 
@@ -1488,6 +1494,7 @@
     /*
      * Reads in a Vector of SocketPermissions and saves them in the perms field.
      */
+    @java.io.Serial
     private void readObject(ObjectInputStream in)
         throws IOException, ClassNotFoundException
     {