Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
8250244: Address reliance on default constructors in java.net
Reviewed-by: alanb, vtewari
- Loading branch information
|
|
@@ -1,5 +1,5 @@ |
|
|
/* |
|
|
* Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. |
|
|
* Copyright (c) 1997, 2020, 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 |
|
@@ -74,6 +74,11 @@ |
|
|
private RequestorType requestingAuthType; |
|
|
private final String key = AuthenticatorKeys.computeKey(this); |
|
|
|
|
|
/** |
|
|
* Constructor for subclasses to call. |
|
|
*/ |
|
|
public Authenticator() {} |
|
|
|
|
|
/** |
|
|
* The type of the entity requesting authentication. |
|
|
* |
|
|
|
|
@@ -1,5 +1,5 @@ |
|
|
/* |
|
|
* Copyright (c) 2003, 2004, Oracle and/or its affiliates. All rights reserved. |
|
|
* Copyright (c) 2003, 2020, 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 |
|
@@ -43,6 +43,11 @@ |
|
|
*/ |
|
|
public abstract class CacheRequest { |
|
|
|
|
|
/** |
|
|
* Constructor for subclasses to call. |
|
|
*/ |
|
|
public CacheRequest() {} |
|
|
|
|
|
/** |
|
|
* Returns an OutputStream to which the response body can be |
|
|
* written. |
|
|
|
|
@@ -1,5 +1,5 @@ |
|
|
/* |
|
|
* Copyright (c) 2003, 2004, Oracle and/or its affiliates. All rights reserved. |
|
|
* Copyright (c) 2003, 2020, 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 |
|
@@ -41,6 +41,11 @@ |
|
|
*/ |
|
|
public abstract class CacheResponse { |
|
|
|
|
|
/** |
|
|
* Constructor for subclasses to call. |
|
|
*/ |
|
|
public CacheResponse() {} |
|
|
|
|
|
/** |
|
|
* Returns the response headers as a Map. |
|
|
* |
|
|
|
|
@@ -1,5 +1,5 @@ |
|
|
/* |
|
|
* Copyright (c) 1995, 2019, Oracle and/or its affiliates. All rights reserved. |
|
|
* Copyright (c) 1995, 2020, 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 |
|
@@ -83,6 +83,11 @@ |
|
|
*/ |
|
|
public abstract class ContentHandler { |
|
|
|
|
|
/** |
|
|
* Constructor for subclasses to call. |
|
|
*/ |
|
|
public ContentHandler() {} |
|
|
|
|
|
/** |
|
|
* Given a URL connect stream positioned at the beginning of the |
|
|
* representation of an object, this method reads that stream and |
|
|
|
|
@@ -1,5 +1,5 @@ |
|
|
/* |
|
|
* Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved. |
|
|
* Copyright (c) 2003, 2020, 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 |
|
@@ -50,6 +50,11 @@ |
|
|
* @since 1.5 |
|
|
*/ |
|
|
public abstract class CookieHandler { |
|
|
/** |
|
|
* Constructor for subclasses to call. |
|
|
*/ |
|
|
public CookieHandler() {} |
|
|
|
|
|
/** |
|
|
* The system-wide cookie handler that will apply cookies to the |
|
|
* request headers and manage cookies from the response headers. |
|
|
|
|
@@ -1,5 +1,5 @@ |
|
|
/* |
|
|
* Copyright (c) 1996, 2019, Oracle and/or its affiliates. All rights reserved. |
|
|
* Copyright (c) 1996, 2020, 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 |
|
@@ -57,6 +57,11 @@ |
|
|
|
|
|
public abstract class DatagramSocketImpl implements SocketOptions { |
|
|
|
|
|
/** |
|
|
* Constructor for subclasses to call. |
|
|
*/ |
|
|
public DatagramSocketImpl() {} |
|
|
|
|
|
/** |
|
|
* The local port number. |
|
|
*/ |
|
|
|
|
@@ -1,5 +1,5 @@ |
|
|
/* |
|
|
* Copyright (c) 2003, 2019, Oracle and/or its affiliates. All rights reserved. |
|
|
* Copyright (c) 2003, 2020, 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 |
|
@@ -80,6 +80,11 @@ |
|
|
} |
|
|
} |
|
|
|
|
|
/** |
|
|
* Constructor for subclasses to call. |
|
|
*/ |
|
|
public ProxySelector() {} |
|
|
|
|
|
/** |
|
|
* Gets the system-wide proxy selector. |
|
|
* |
|
|
|
|
@@ -1,5 +1,5 @@ |
|
|
/* |
|
|
* Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved. |
|
|
* Copyright (c) 2003, 2020, 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 |
|
@@ -60,6 +60,11 @@ |
|
|
*/ |
|
|
public abstract class ResponseCache { |
|
|
|
|
|
/** |
|
|
* Constructor for subclasses to call. |
|
|
*/ |
|
|
public ResponseCache() {} |
|
|
|
|
|
/** |
|
|
* The system wide cache that provides access to a url |
|
|
* caching mechanism. |
|
|
|
@@ -39,6 +39,11 @@ |
|
|
* @since 1.5 |
|
|
*/ |
|
|
public abstract class SecureCacheResponse extends CacheResponse { |
|
|
/** |
|
|
* Constructor for subclasses to call. |
|
|
*/ |
|
|
public SecureCacheResponse() {} |
|
|
|
|
|
/** |
|
|
* Returns the cipher suite in use on the original connection that |
|
|
* retrieved the network resource. |
|
|
|
|
@@ -1,5 +1,5 @@ |
|
|
/* |
|
|
* Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved. |
|
|
* Copyright (c) 2000, 2020, 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 |
|
@@ -43,4 +43,8 @@ |
|
|
@java.io.Serial |
|
|
static final long serialVersionUID = 5215720748342549866L; |
|
|
|
|
|
/** |
|
|
* Constructor for subclasses to call. |
|
|
*/ |
|
|
public SocketAddress() {} |
|
|
} |
|
|
@@ -1,5 +1,5 @@ |
|
|
/* |
|
|
* Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. |
|
|
* Copyright (c) 1998, 2020, 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 |
|
@@ -81,6 +81,12 @@ |
|
|
|
|
|
public class URLDecoder { |
|
|
|
|
|
/** |
|
|
* Do not call. |
|
|
*/ |
|
|
@Deprecated(since="16", forRemoval=true) |
|
|
public URLDecoder() {} |
|
|
|
|
|
// The platform default encoding |
|
|
static String dfltEncName = URLEncoder.dfltEncName; |
|
|
|
|
|
|
|
@@ -1,5 +1,5 @@ |
|
|
/* |
|
|
* Copyright (c) 1995, 2019, Oracle and/or its affiliates. All rights reserved. |
|
|
* Copyright (c) 1995, 2020, 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 |
|
@@ -51,6 +51,11 @@ |
|
|
* @since 1.0 |
|
|
*/ |
|
|
public abstract class URLStreamHandler { |
|
|
/** |
|
|
* Constructor for subclasses to call. |
|
|
*/ |
|
|
public URLStreamHandler() {} |
|
|
|
|
|
/** |
|
|
* Opens a connection to the object referenced by the |
|
|
* {@code URL} argument. |
|
|