From 56b8c6e7b79a688c07fc2f26bcfb383ea3de850f Mon Sep 17 00:00:00 2001 From: juh Date: Wed, 10 Jul 2013 18:01:22 -0700 Subject: [PATCH] 8020318: Fix doclint issues in java.net Reviewed-by: darcy, khazra --- src/share/classes/java/net/CookieStore.java | 4 +++- src/share/classes/java/net/HttpURLPermission.java | 14 ++++++++------ src/share/classes/java/net/Inet4Address.java | 4 ++-- src/share/classes/java/net/Inet6Address.java | 4 ++-- src/share/classes/java/net/InetAddress.java | 5 ++--- src/share/classes/java/net/ProtocolFamily.java | 4 +++- src/share/classes/java/net/SocketOption.java | 6 +++++- src/share/classes/java/net/URI.java | 14 +++++++------- 8 files changed, 32 insertions(+), 23 deletions(-) diff --git a/src/share/classes/java/net/CookieStore.java b/src/share/classes/java/net/CookieStore.java index a8232d293..89b9c41dd 100644 --- a/src/share/classes/java/net/CookieStore.java +++ b/src/share/classes/java/net/CookieStore.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2013, 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 @@ -75,6 +75,8 @@ public interface CookieStore { * @return an immutable list of HttpCookie, * return empty list if no cookies match the given URI * + * @param uri the uri associated with the cookies to be returned + * * @throws NullPointerException if uri is null * * @see #add diff --git a/src/share/classes/java/net/HttpURLPermission.java b/src/share/classes/java/net/HttpURLPermission.java index 55d37fda8..4e038bc73 100644 --- a/src/share/classes/java/net/HttpURLPermission.java +++ b/src/share/classes/java/net/HttpURLPermission.java @@ -47,6 +47,7 @@ import java.security.Permission; * in {@link java.io.FilePermission}. There are three different ways * as the following examples show: * + * * * * @@ -57,7 +58,7 @@ import java.security.Permission; * which only differ in the final path component, represented by the '*'. * * - * *
URL Examples
Example urlDescription
http://www.oracle.com/a/b/c.htmlA url which identifies a specific (single) resource
http://www.oracle.com/a/b/- + *
http://www.oracle.com/a/b/-The '-' character refers to all resources recursively below the * preceding path (eg. http://www.oracle.com/a/b/c/d/e.html matches this * example). @@ -164,6 +165,8 @@ public final class HttpURLPermission extends Permission { * methods and request headers by invoking the two argument * constructor as follows: HttpURLPermission(url, "*:*") * + * @param url the url string + * * @throws IllegalArgumentException if url does not result in a valid {@link URI} */ public HttpURLPermission(String url) { @@ -204,11 +207,10 @@ public final class HttpURLPermission extends Permission { *
  • if the path or paths specified by p's url are contained in the * set of paths specified by this's url, then return true *
  • otherwise, return false
  • - * - *

    - * Some examples of how paths are matched are shown below: - *

    - * + * + *

    Some examples of how paths are matched are shown below: + *

    + * * * * diff --git a/src/share/classes/java/net/Inet4Address.java b/src/share/classes/java/net/Inet4Address.java index 529257fa9..6c59a692f 100644 --- a/src/share/classes/java/net/Inet4Address.java +++ b/src/share/classes/java/net/Inet4Address.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2013, 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 @@ -36,7 +36,7 @@ import java.io.ObjectStreamException; * and RFC 2365: * Administratively Scoped IP Multicast * - *

    Textual representation of IP addresses

    + *

    Textual representation of IP addresses

    * * Textual representation of IPv4 address used as input to methods * takes one of the following forms: diff --git a/src/share/classes/java/net/Inet6Address.java b/src/share/classes/java/net/Inet6Address.java index 4a2d4e224..169a180de 100644 --- a/src/share/classes/java/net/Inet6Address.java +++ b/src/share/classes/java/net/Inet6Address.java @@ -35,7 +35,7 @@ import java.util.Enumeration; * Defined by * RFC 2373: IP Version 6 Addressing Architecture. * - *

    Textual representation of IP addresses

    + *

    Textual representation of IP addresses

    * * Textual representation of IPv6 address used as input to methods * takes one of the following forms: @@ -156,7 +156,7 @@ import java.util.Enumeration; * system. Usually, the numeric values can be determined through administration * tools on the system. Each interface may have multiple values, one for each * scope. If the scope is unspecified, then the default value used is zero. - *

  • As a string. This must be the exact string that is returned by + *
  • As a string. This must be the exact string that is returned by * {@link java.net.NetworkInterface#getName()} for the particular interface in * question. When an Inet6Address is created in this way, the numeric scope-id * is determined at the time the object is created by querying the relevant diff --git a/src/share/classes/java/net/InetAddress.java b/src/share/classes/java/net/InetAddress.java index 1154c9a80..aa5ef1670 100644 --- a/src/share/classes/java/net/InetAddress.java +++ b/src/share/classes/java/net/InetAddress.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2013, 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 @@ -65,7 +65,7 @@ import sun.net.spi.nameservice.*; * with a host name or whether it has already done reverse host name * resolution). * - *

    Address types

    + *

    Address types

    * *
  • Examples of Path Matching
    this's pathp's pathmatch
    /a/b/a/byes
    /a/b/*/a/b/cyes
    * @@ -165,7 +165,6 @@ import sun.net.spi.nameservice.*; *

    * A value of -1 indicates "cache forever". * - *

    *

    networkaddress.cache.negative.ttl (default: 10)
    *
    Indicates the caching policy for un-successful name lookups * from the name service. The value is specified as as integer to diff --git a/src/share/classes/java/net/ProtocolFamily.java b/src/share/classes/java/net/ProtocolFamily.java index c6aa95b18..5d02326db 100644 --- a/src/share/classes/java/net/ProtocolFamily.java +++ b/src/share/classes/java/net/ProtocolFamily.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2008, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2013, 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 @@ -34,6 +34,8 @@ package java.net; public interface ProtocolFamily { /** * Returns the name of the protocol family. + * + * @return the name of the protocol family */ String name(); } diff --git a/src/share/classes/java/net/SocketOption.java b/src/share/classes/java/net/SocketOption.java index cfa4616bc..2ccf57f5f 100644 --- a/src/share/classes/java/net/SocketOption.java +++ b/src/share/classes/java/net/SocketOption.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2013, 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 @@ -45,11 +45,15 @@ public interface SocketOption { /** * Returns the name of the socket option. + * + * @return the name of the socket option */ String name(); /** * Returns the type of the socket option value. + * + * @return the type of the socket option value */ Class type(); } diff --git a/src/share/classes/java/net/URI.java b/src/share/classes/java/net/URI.java index ed90f090c..643c8af8a 100644 --- a/src/share/classes/java/net/URI.java +++ b/src/share/classes/java/net/URI.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2013, 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 @@ -61,13 +61,13 @@ import java.lang.NullPointerException; // for javadoc * and relativizing URI instances. Instances of this class are immutable. * * - *

    URI syntax and components

    + *

    URI syntax and components

    * * At the highest level a URI reference (hereinafter simply "URI") in string * form has the syntax * *
    - * [scheme:]scheme-specific-part[#fragment] + * [scheme:]scheme-specific-part[#fragment] *
    * * where square brackets [...] delineate optional components and the characters @@ -334,14 +334,14 @@ import java.lang.NullPointerException; // for javadoc * *
      * - *
    • The {@link #URI(java.lang.String) single-argument - * constructor} requires any illegal characters in its argument to be + *

    • The {@linkplain #URI(java.lang.String) single-argument + * constructor} requires any illegal characters in its argument to be * quoted and preserves any escaped octets and other characters that * are present.

    • * - *
    • The {@link + *

    • The {@linkplain * #URI(java.lang.String,java.lang.String,java.lang.String,int,java.lang.String,java.lang.String,java.lang.String) - * multi-argument constructors} quote illegal characters as + * multi-argument constructors} quote illegal characters as * required by the components in which they appear. The percent character * ('%') is always quoted by these constructors. Any other * characters are preserved.

    • -- GitLab
    unicast