提交 b62c6249 编写于 作者: J juh

8021833: javadoc cleanup in java.net

Summary: <code> and <tt> converted to {@code }; package.html to package-info.java
Reviewed-by: darcy, chegar
上级 36aa0306
/* /*
* Copyright (c) 1997, 2004, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -103,17 +103,17 @@ class Authenticator { ...@@ -103,17 +103,17 @@ class Authenticator {
* Sets the authenticator that will be used by the networking code * Sets the authenticator that will be used by the networking code
* when a proxy or an HTTP server asks for authentication. * when a proxy or an HTTP server asks for authentication.
* <p> * <p>
* First, if there is a security manager, its <code>checkPermission</code> * First, if there is a security manager, its {@code checkPermission}
* method is called with a * method is called with a
* <code>NetPermission("setDefaultAuthenticator")</code> permission. * {@code NetPermission("setDefaultAuthenticator")} permission.
* This may result in a java.lang.SecurityException. * This may result in a java.lang.SecurityException.
* *
* @param a The authenticator to be set. If a is <code>null</code> then * @param a The authenticator to be set. If a is {@code null} then
* any previously set authenticator is removed. * any previously set authenticator is removed.
* *
* @throws SecurityException * @throws SecurityException
* if a security manager exists and its * if a security manager exists and its
* <code>checkPermission</code> method doesn't allow * {@code checkPermission} method doesn't allow
* setting the default authenticator. * setting the default authenticator.
* *
* @see SecurityManager#checkPermission * @see SecurityManager#checkPermission
...@@ -134,9 +134,9 @@ class Authenticator { ...@@ -134,9 +134,9 @@ class Authenticator {
* Ask the authenticator that has been registered with the system * Ask the authenticator that has been registered with the system
* for a password. * for a password.
* <p> * <p>
* First, if there is a security manager, its <code>checkPermission</code> * First, if there is a security manager, its {@code checkPermission}
* method is called with a * method is called with a
* <code>NetPermission("requestPasswordAuthentication")</code> permission. * {@code NetPermission("requestPasswordAuthentication")} permission.
* This may result in a java.lang.SecurityException. * This may result in a java.lang.SecurityException.
* *
* @param addr The InetAddress of the site requesting authorization, * @param addr The InetAddress of the site requesting authorization,
...@@ -151,7 +151,7 @@ class Authenticator { ...@@ -151,7 +151,7 @@ class Authenticator {
* *
* @throws SecurityException * @throws SecurityException
* if a security manager exists and its * if a security manager exists and its
* <code>checkPermission</code> method doesn't allow * {@code checkPermission} method doesn't allow
* the password authentication request. * the password authentication request.
* *
* @see SecurityManager#checkPermission * @see SecurityManager#checkPermission
...@@ -193,9 +193,9 @@ class Authenticator { ...@@ -193,9 +193,9 @@ class Authenticator {
* because the hostname can be provided in cases where the InetAddress * because the hostname can be provided in cases where the InetAddress
* is not available. * is not available.
* <p> * <p>
* First, if there is a security manager, its <code>checkPermission</code> * First, if there is a security manager, its {@code checkPermission}
* method is called with a * method is called with a
* <code>NetPermission("requestPasswordAuthentication")</code> permission. * {@code NetPermission("requestPasswordAuthentication")} permission.
* This may result in a java.lang.SecurityException. * This may result in a java.lang.SecurityException.
* *
* @param host The hostname of the site requesting authentication. * @param host The hostname of the site requesting authentication.
...@@ -211,7 +211,7 @@ class Authenticator { ...@@ -211,7 +211,7 @@ class Authenticator {
* *
* @throws SecurityException * @throws SecurityException
* if a security manager exists and its * if a security manager exists and its
* <code>checkPermission</code> method doesn't allow * {@code checkPermission} method doesn't allow
* the password authentication request. * the password authentication request.
* *
* @see SecurityManager#checkPermission * @see SecurityManager#checkPermission
...@@ -254,9 +254,9 @@ class Authenticator { ...@@ -254,9 +254,9 @@ class Authenticator {
* Ask the authenticator that has been registered with the system * Ask the authenticator that has been registered with the system
* for a password. * for a password.
* <p> * <p>
* First, if there is a security manager, its <code>checkPermission</code> * First, if there is a security manager, its {@code checkPermission}
* method is called with a * method is called with a
* <code>NetPermission("requestPasswordAuthentication")</code> permission. * {@code NetPermission("requestPasswordAuthentication")} permission.
* This may result in a java.lang.SecurityException. * This may result in a java.lang.SecurityException.
* *
* @param host The hostname of the site requesting authentication. * @param host The hostname of the site requesting authentication.
...@@ -275,7 +275,7 @@ class Authenticator { ...@@ -275,7 +275,7 @@ class Authenticator {
* *
* @throws SecurityException * @throws SecurityException
* if a security manager exists and its * if a security manager exists and its
* <code>checkPermission</code> method doesn't allow * {@code checkPermission} method doesn't allow
* the password authentication request. * the password authentication request.
* *
* @see SecurityManager#checkPermission * @see SecurityManager#checkPermission
...@@ -320,8 +320,8 @@ class Authenticator { ...@@ -320,8 +320,8 @@ class Authenticator {
} }
/** /**
* Gets the <code>hostname</code> of the * Gets the {@code hostname} of the
* site or proxy requesting authentication, or <code>null</code> * site or proxy requesting authentication, or {@code null}
* if not available. * if not available.
* *
* @return the hostname of the connection requiring authentication, or null * @return the hostname of the connection requiring authentication, or null
...@@ -333,8 +333,8 @@ class Authenticator { ...@@ -333,8 +333,8 @@ class Authenticator {
} }
/** /**
* Gets the <code>InetAddress</code> of the * Gets the {@code InetAddress} of the
* site requesting authorization, or <code>null</code> * site requesting authorization, or {@code null}
* if not available. * if not available.
* *
* @return the InetAddress of the site requesting authorization, or null * @return the InetAddress of the site requesting authorization, or null
...@@ -346,7 +346,7 @@ class Authenticator { ...@@ -346,7 +346,7 @@ class Authenticator {
/** /**
* Gets the port number for the requested connection. * Gets the port number for the requested connection.
* @return an <code>int</code> indicating the * @return an {@code int} indicating the
* port for the requested connection. * port for the requested connection.
*/ */
protected final int getRequestingPort() { protected final int getRequestingPort() {
......
/* /*
* 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -28,21 +28,21 @@ package java.net; ...@@ -28,21 +28,21 @@ package java.net;
import java.io.IOException; import java.io.IOException;
/** /**
* The abstract class <code>ContentHandler</code> is the superclass * The abstract class {@code ContentHandler} is the superclass
* of all classes that read an <code>Object</code> from a * of all classes that read an {@code Object} from a
* <code>URLConnection</code>. * {@code URLConnection}.
* <p> * <p>
* An application does not generally call the * An application does not generally call the
* <code>getContent</code> method in this class directly. Instead, an * {@code getContent} method in this class directly. Instead, an
* application calls the <code>getContent</code> method in class * application calls the {@code getContent} method in class
* <code>URL</code> or in <code>URLConnection</code>. * {@code URL} or in {@code URLConnection}.
* The application's content handler factory (an instance of a class that * The application's content handler factory (an instance of a class that
* implements the interface <code>ContentHandlerFactory</code> set * implements the interface {@code ContentHandlerFactory} set
* up by a call to <code>setContentHandler</code>) is * up by a call to {@code setContentHandler}) is
* called with a <code>String</code> giving the MIME type of the * called with a {@code String} giving the MIME type of the
* object being received on the socket. The factory returns an * object being received on the socket. The factory returns an
* instance of a subclass of <code>ContentHandler</code>, and its * instance of a subclass of {@code ContentHandler}, and its
* <code>getContent</code> method is called to create the object. * {@code getContent} method is called to create the object.
* <p> * <p>
* If no content handler could be found, URLConnection will * If no content handler could be found, URLConnection will
* look for a content handler in a user-defineable set of places. * look for a content handler in a user-defineable set of places.
...@@ -75,7 +75,7 @@ abstract public class ContentHandler { ...@@ -75,7 +75,7 @@ abstract public class ContentHandler {
* creates an object from it. * creates an object from it.
* *
* @param urlc a URL connection. * @param urlc a URL connection.
* @return the object read by the <code>ContentHandler</code>. * @return the object read by the {@code ContentHandler}.
* @exception IOException if an I/O error occurs while reading the object. * @exception IOException if an I/O error occurs while reading the object.
*/ */
abstract public Object getContent(URLConnection urlc) throws IOException; abstract public Object getContent(URLConnection urlc) throws IOException;
...@@ -90,7 +90,7 @@ abstract public class ContentHandler { ...@@ -90,7 +90,7 @@ abstract public class ContentHandler {
* *
* @param urlc a URL connection. * @param urlc a URL connection.
* @param classes an array of types requested * @param classes an array of types requested
* @return the object read by the <code>ContentHandler</code> that is * @return the object read by the {@code ContentHandler} that is
* the first match of the suggested types. * the first match of the suggested types.
* null if none of the requested are supported. * null if none of the requested are supported.
* @exception IOException if an I/O error occurs while reading the object. * @exception IOException if an I/O error occurs while reading the object.
......
/* /*
* Copyright (c) 1995, 1997, 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -28,10 +28,10 @@ package java.net; ...@@ -28,10 +28,10 @@ package java.net;
/** /**
* This interface defines a factory for content handlers. An * This interface defines a factory for content handlers. An
* implementation of this interface should map a MIME type into an * implementation of this interface should map a MIME type into an
* instance of <code>ContentHandler</code>. * instance of {@code ContentHandler}.
* <p> * <p>
* This interface is used by the <code>URLStreamHandler</code> class * This interface is used by the {@code URLStreamHandler} class
* to create a <code>ContentHandler</code> for a MIME type. * to create a {@code ContentHandler} for a MIME type.
* *
* @author James Gosling * @author James Gosling
* @see java.net.ContentHandler * @see java.net.ContentHandler
...@@ -40,13 +40,13 @@ package java.net; ...@@ -40,13 +40,13 @@ package java.net;
*/ */
public interface ContentHandlerFactory { public interface ContentHandlerFactory {
/** /**
* Creates a new <code>ContentHandler</code> to read an object from * Creates a new {@code ContentHandler} to read an object from
* a <code>URLStreamHandler</code>. * a {@code URLStreamHandler}.
* *
* @param mimetype the MIME type for which a content handler is desired. * @param mimetype the MIME type for which a content handler is desired.
* @return a new <code>ContentHandler</code> to read an object from a * @return a new {@code ContentHandler} to read an object from a
* <code>URLStreamHandler</code>. * {@code URLStreamHandler}.
* @see java.net.ContentHandler * @see java.net.ContentHandler
* @see java.net.URLStreamHandler * @see java.net.URLStreamHandler
*/ */
......
/* /*
* Copyright (c) 2003, 2008, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -66,7 +66,7 @@ public abstract class CookieHandler { ...@@ -66,7 +66,7 @@ public abstract class CookieHandler {
* there is no system-wide cookie handler currently set. * there is no system-wide cookie handler currently set.
* @throws SecurityException * @throws SecurityException
* If a security manager has been installed and it denies * If a security manager has been installed and it denies
* {@link NetPermission}<tt>("getCookieHandler")</tt> * {@link NetPermission}{@code ("getCookieHandler")}
* @see #setDefault(CookieHandler) * @see #setDefault(CookieHandler)
*/ */
public synchronized static CookieHandler getDefault() { public synchronized static CookieHandler getDefault() {
...@@ -83,10 +83,10 @@ public abstract class CookieHandler { ...@@ -83,10 +83,10 @@ public abstract class CookieHandler {
* Note: non-standard http protocol handlers may ignore this setting. * Note: non-standard http protocol handlers may ignore this setting.
* *
* @param cHandler The HTTP cookie handler, or * @param cHandler The HTTP cookie handler, or
* <code>null</code> to unset. * {@code null} to unset.
* @throws SecurityException * @throws SecurityException
* If a security manager has been installed and it denies * If a security manager has been installed and it denies
* {@link NetPermission}<tt>("setCookieHandler")</tt> * {@link NetPermission}{@code ("setCookieHandler")}
* @see #getDefault() * @see #getDefault()
*/ */
public synchronized static void setDefault(CookieHandler cHandler) { public synchronized static void setDefault(CookieHandler cHandler) {
...@@ -114,7 +114,7 @@ public abstract class CookieHandler { ...@@ -114,7 +114,7 @@ public abstract class CookieHandler {
* called after all request headers related to choosing cookies * called after all request headers related to choosing cookies
* are added, and before the request is sent.</P> * are added, and before the request is sent.</P>
* *
* @param uri a <code>URI</code> representing the intended use for the * @param uri a {@code URI} representing the intended use for the
* cookies * cookies
* @param requestHeaders - a Map from request header * @param requestHeaders - a Map from request header
* field names to lists of field values representing * field names to lists of field values representing
...@@ -136,7 +136,7 @@ public abstract class CookieHandler { ...@@ -136,7 +136,7 @@ public abstract class CookieHandler {
* fields that are named Set-Cookie2, present in the response * fields that are named Set-Cookie2, present in the response
* headers into a cookie cache. * headers into a cookie cache.
* *
* @param uri a <code>URI</code> where the cookies come from * @param uri a {@code URI} where the cookies come from
* @param responseHeaders an immutable map from field names to * @param responseHeaders an immutable map from field names to
* lists of field values representing the response * lists of field values representing the response
* header fields returned * header fields returned
......
/* /*
* Copyright (c) 2005, 2011, 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -131,7 +131,7 @@ public class CookieManager extends CookieHandler ...@@ -131,7 +131,7 @@ public class CookieManager extends CookieHandler
* *
* <p>This constructor will create new cookie manager with default * <p>This constructor will create new cookie manager with default
* cookie store and accept policy. The effect is same as * cookie store and accept policy. The effect is same as
* <tt>CookieManager(null, null)</tt>. * {@code CookieManager(null, null)}.
*/ */
public CookieManager() { public CookieManager() {
this(null, null); this(null, null);
...@@ -141,12 +141,12 @@ public class CookieManager extends CookieHandler ...@@ -141,12 +141,12 @@ public class CookieManager extends CookieHandler
/** /**
* Create a new cookie manager with specified cookie store and cookie policy. * Create a new cookie manager with specified cookie store and cookie policy.
* *
* @param store a <tt>CookieStore</tt> to be used by cookie manager. * @param store a {@code CookieStore} to be used by cookie manager.
* if <tt>null</tt>, cookie manager will use a default one, * if {@code null}, cookie manager will use a default one,
* which is an in-memory CookieStore implmentation. * which is an in-memory CookieStore implmentation.
* @param cookiePolicy a <tt>CookiePolicy</tt> instance * @param cookiePolicy a {@code CookiePolicy} instance
* to be used by cookie manager as policy callback. * to be used by cookie manager as policy callback.
* if <tt>null</tt>, ACCEPT_ORIGINAL_SERVER will * if {@code null}, ACCEPT_ORIGINAL_SERVER will
* be used. * be used.
*/ */
public CookieManager(CookieStore store, public CookieManager(CookieStore store,
...@@ -170,11 +170,11 @@ public class CookieManager extends CookieHandler ...@@ -170,11 +170,11 @@ public class CookieManager extends CookieHandler
/** /**
* To set the cookie policy of this cookie manager. * To set the cookie policy of this cookie manager.
* *
* <p> A instance of <tt>CookieManager</tt> will have * <p> A instance of {@code CookieManager} will have
* cookie policy ACCEPT_ORIGINAL_SERVER by default. Users always * cookie policy ACCEPT_ORIGINAL_SERVER by default. Users always
* can call this method to set another cookie policy. * can call this method to set another cookie policy.
* *
* @param cookiePolicy the cookie policy. Can be <tt>null</tt>, which * @param cookiePolicy the cookie policy. Can be {@code null}, which
* has no effects on current cookie policy. * has no effects on current cookie policy.
*/ */
public void setCookiePolicy(CookiePolicy cookiePolicy) { public void setCookiePolicy(CookiePolicy cookiePolicy) {
......
/* /*
* 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -71,8 +71,8 @@ public interface CookiePolicy { ...@@ -71,8 +71,8 @@ public interface CookiePolicy {
* *
* @param uri the URI to consult accept policy with * @param uri the URI to consult accept policy with
* @param cookie the HttpCookie object in question * @param cookie the HttpCookie object in question
* @return <tt>true</tt> if this cookie should be accepted; * @return {@code true} if this cookie should be accepted;
* otherwise, <tt>false</tt> * otherwise, {@code false}
*/ */
public boolean shouldAccept(URI uri, HttpCookie cookie); public boolean shouldAccept(URI uri, HttpCookie cookie);
} }
...@@ -32,8 +32,8 @@ import java.util.Map; ...@@ -32,8 +32,8 @@ import java.util.Map;
* A CookieStore object represents a storage for cookie. Can store and retrieve * A CookieStore object represents a storage for cookie. Can store and retrieve
* cookies. * cookies.
* *
* <p>{@link CookieManager} will call <tt>CookieStore.add</tt> to save cookies * <p>{@link CookieManager} will call {@code CookieStore.add} to save cookies
* for every incoming HTTP response, and call <tt>CookieStore.get</tt> to * for every incoming HTTP response, and call {@code CookieStore.get} to
* retrieve cookie for every outgoing HTTP request. A CookieStore * retrieve cookie for every outgoing HTTP request. A CookieStore
* is responsible for removing HttpCookie instances which have expired. * is responsible for removing HttpCookie instances which have expired.
* *
...@@ -55,11 +55,11 @@ public interface CookieStore { ...@@ -55,11 +55,11 @@ public interface CookieStore {
* then it is replaced with the new one. * then it is replaced with the new one.
* *
* @param uri the uri this cookie associated with. * @param uri the uri this cookie associated with.
* if <tt>null</tt>, this cookie will not be associated * if {@code null}, this cookie will not be associated
* with an URI * with an URI
* @param cookie the cookie to store * @param cookie the cookie to store
* *
* @throws NullPointerException if <tt>cookie</tt> is <tt>null</tt> * @throws NullPointerException if {@code cookie} is {@code null}
* *
* @see #get * @see #get
* *
...@@ -77,7 +77,7 @@ public interface CookieStore { ...@@ -77,7 +77,7 @@ public interface CookieStore {
* *
* @param uri the uri associated with the cookies to be returned * @param uri the uri associated with the cookies to be returned
* *
* @throws NullPointerException if <tt>uri</tt> is <tt>null</tt> * @throws NullPointerException if {@code uri} is {@code null}
* *
* @see #add * @see #add
* *
...@@ -108,14 +108,14 @@ public interface CookieStore { ...@@ -108,14 +108,14 @@ public interface CookieStore {
* Remove a cookie from store. * Remove a cookie from store.
* *
* @param uri the uri this cookie associated with. * @param uri the uri this cookie associated with.
* if <tt>null</tt>, the cookie to be removed is not associated * if {@code null}, the cookie to be removed is not associated
* with an URI when added; if not <tt>null</tt>, the cookie * with an URI when added; if not {@code null}, the cookie
* to be removed is associated with the given URI when added. * to be removed is associated with the given URI when added.
* @param cookie the cookie to remove * @param cookie the cookie to remove
* *
* @return <tt>true</tt> if this store contained the specified cookie * @return {@code true} if this store contained the specified cookie
* *
* @throws NullPointerException if <tt>cookie</tt> is <tt>null</tt> * @throws NullPointerException if {@code cookie} is {@code null}
*/ */
public boolean remove(URI uri, HttpCookie cookie); public boolean remove(URI uri, HttpCookie cookie);
...@@ -123,7 +123,7 @@ public interface CookieStore { ...@@ -123,7 +123,7 @@ public interface CookieStore {
/** /**
* Remove all cookies in this cookie store. * Remove all cookies in this cookie store.
* *
* @return <tt>true</tt> if this store changed as a result of the call * @return {@code true} if this store changed as a result of the call
*/ */
public boolean removeAll(); public boolean removeAll();
} }
/* /*
* 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -68,11 +68,11 @@ class DatagramPacket { ...@@ -68,11 +68,11 @@ class DatagramPacket {
int port; int port;
/** /**
* Constructs a <code>DatagramPacket</code> for receiving packets of * Constructs a {@code DatagramPacket} for receiving packets of
* length <code>length</code>, specifying an offset into the buffer. * length {@code length}, specifying an offset into the buffer.
* <p> * <p>
* The <code>length</code> argument must be less than or equal to * The {@code length} argument must be less than or equal to
* <code>buf.length</code>. * {@code buf.length}.
* *
* @param buf buffer for holding the incoming datagram. * @param buf buffer for holding the incoming datagram.
* @param offset the offset for the buffer * @param offset the offset for the buffer
...@@ -87,11 +87,11 @@ class DatagramPacket { ...@@ -87,11 +87,11 @@ class DatagramPacket {
} }
/** /**
* Constructs a <code>DatagramPacket</code> for receiving packets of * Constructs a {@code DatagramPacket} for receiving packets of
* length <code>length</code>. * length {@code length}.
* <p> * <p>
* The <code>length</code> argument must be less than or equal to * The {@code length} argument must be less than or equal to
* <code>buf.length</code>. * {@code buf.length}.
* *
* @param buf buffer for holding the incoming datagram. * @param buf buffer for holding the incoming datagram.
* @param length the number of bytes to read. * @param length the number of bytes to read.
...@@ -102,10 +102,10 @@ class DatagramPacket { ...@@ -102,10 +102,10 @@ class DatagramPacket {
/** /**
* Constructs a datagram packet for sending packets of length * Constructs a datagram packet for sending packets of length
* <code>length</code> with offset <code>ioffset</code>to the * {@code length} with offset {@code ioffset}to the
* specified port number on the specified host. The * specified port number on the specified host. The
* <code>length</code> argument must be less than or equal to * {@code length} argument must be less than or equal to
* <code>buf.length</code>. * {@code buf.length}.
* *
* @param buf the packet data. * @param buf the packet data.
* @param offset the packet data offset. * @param offset the packet data offset.
...@@ -125,10 +125,10 @@ class DatagramPacket { ...@@ -125,10 +125,10 @@ class DatagramPacket {
/** /**
* Constructs a datagram packet for sending packets of length * Constructs a datagram packet for sending packets of length
* <code>length</code> with offset <code>ioffset</code>to the * {@code length} with offset {@code ioffset}to the
* specified port number on the specified host. The * specified port number on the specified host. The
* <code>length</code> argument must be less than or equal to * {@code length} argument must be less than or equal to
* <code>buf.length</code>. * {@code buf.length}.
* *
* @param buf the packet data. * @param buf the packet data.
* @param offset the packet data offset. * @param offset the packet data offset.
...@@ -147,9 +147,9 @@ class DatagramPacket { ...@@ -147,9 +147,9 @@ class DatagramPacket {
/** /**
* Constructs a datagram packet for sending packets of length * Constructs a datagram packet for sending packets of length
* <code>length</code> to the specified port number on the specified * {@code length} to the specified port number on the specified
* host. The <code>length</code> argument must be less than or equal * host. The {@code length} argument must be less than or equal
* to <code>buf.length</code>. * to {@code buf.length}.
* *
* @param buf the packet data. * @param buf the packet data.
* @param length the packet length. * @param length the packet length.
...@@ -164,9 +164,9 @@ class DatagramPacket { ...@@ -164,9 +164,9 @@ class DatagramPacket {
/** /**
* Constructs a datagram packet for sending packets of length * Constructs a datagram packet for sending packets of length
* <code>length</code> to the specified port number on the specified * {@code length} to the specified port number on the specified
* host. The <code>length</code> argument must be less than or equal * host. The {@code length} argument must be less than or equal
* to <code>buf.length</code>. * to {@code buf.length}.
* *
* @param buf the packet data. * @param buf the packet data.
* @param length the packet length. * @param length the packet length.
...@@ -207,8 +207,8 @@ class DatagramPacket { ...@@ -207,8 +207,8 @@ class DatagramPacket {
/** /**
* Returns the data buffer. The data received or the data to be sent * Returns the data buffer. The data received or the data to be sent
* starts from the <code>offset</code> in the buffer, * starts from the {@code offset} in the buffer,
* and runs for <code>length</code> long. * and runs for {@code length} long.
* *
* @return the buffer used to receive or send data * @return the buffer used to receive or send data
* @see #setData(byte[], int, int) * @see #setData(byte[], int, int)
...@@ -277,7 +277,7 @@ class DatagramPacket { ...@@ -277,7 +277,7 @@ class DatagramPacket {
/** /**
* Sets the IP address of the machine to which this datagram * Sets the IP address of the machine to which this datagram
* is being sent. * is being sent.
* @param iaddr the <code>InetAddress</code> * @param iaddr the {@code InetAddress}
* @since JDK1.1 * @since JDK1.1
* @see #getAddress() * @see #getAddress()
*/ */
...@@ -303,7 +303,7 @@ class DatagramPacket { ...@@ -303,7 +303,7 @@ class DatagramPacket {
* Sets the SocketAddress (usually IP address + port number) of the remote * Sets the SocketAddress (usually IP address + port number) of the remote
* host to which this datagram is being sent. * host to which this datagram is being sent.
* *
* @param address the <code>SocketAddress</code> * @param address the {@code SocketAddress}
* @throws IllegalArgumentException if address is null or is a * @throws IllegalArgumentException if address is null or is a
* SocketAddress subclass not supported by this socket * SocketAddress subclass not supported by this socket
* *
...@@ -324,7 +324,7 @@ class DatagramPacket { ...@@ -324,7 +324,7 @@ class DatagramPacket {
* Gets the SocketAddress (usually IP address + port number) of the remote * Gets the SocketAddress (usually IP address + port number) of the remote
* host that this packet is being sent to or is coming from. * host that this packet is being sent to or is coming from.
* *
* @return the <code>SocketAddress</code> * @return the {@code SocketAddress}
* @since 1.4 * @since 1.4
* @see #setSocketAddress * @see #setSocketAddress
*/ */
...@@ -335,7 +335,7 @@ class DatagramPacket { ...@@ -335,7 +335,7 @@ class DatagramPacket {
/** /**
* Set the data buffer for this packet. With the offset of * Set the data buffer for this packet. With the offset of
* this DatagramPacket set to 0, and the length set to * this DatagramPacket set to 0, and the length set to
* the length of <code>buf</code>. * the length of {@code buf}.
* *
* @param buf the buffer to set for this packet. * @param buf the buffer to set for this packet.
* *
......
/* /*
* Copyright (c) 1996, 2006, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -101,7 +101,7 @@ public abstract class DatagramSocketImpl implements SocketOptions { ...@@ -101,7 +101,7 @@ public abstract class DatagramSocketImpl implements SocketOptions {
protected void disconnect() {} protected void disconnect() {}
/** /**
* Peek at the packet to see who it is from. Updates the specified <code>InetAddress</code> * Peek at the packet to see who it is from. Updates the specified {@code InetAddress}
* to the address which the packet came from. * to the address which the packet came from.
* @param i an InetAddress object * @param i an InetAddress object
* @return the port number which the packet came from. * @return the port number which the packet came from.
...@@ -114,7 +114,7 @@ public abstract class DatagramSocketImpl implements SocketOptions { ...@@ -114,7 +114,7 @@ public abstract class DatagramSocketImpl implements SocketOptions {
/** /**
* Peek at the packet to see who it is from. The data is copied into the specified * Peek at the packet to see who it is from. The data is copied into the specified
* <code>DatagramPacket</code>. The data is returned, * {@code DatagramPacket}. The data is returned,
* but not consumed, so that a subsequent peekData/receive operation * but not consumed, so that a subsequent peekData/receive operation
* will see the same data. * will see the same data.
* @param p the Packet Received. * @param p the Packet Received.
...@@ -163,7 +163,7 @@ public abstract class DatagramSocketImpl implements SocketOptions { ...@@ -163,7 +163,7 @@ public abstract class DatagramSocketImpl implements SocketOptions {
/** /**
* Set the TTL (time-to-live) option. * Set the TTL (time-to-live) option.
* @param ttl an <tt>int</tt> specifying the time-to-live value * @param ttl an {@code int} specifying the time-to-live value
* @exception IOException if an I/O exception occurs * @exception IOException if an I/O exception occurs
* while setting the time-to-live option. * while setting the time-to-live option.
* @see #getTimeToLive() * @see #getTimeToLive()
...@@ -174,7 +174,7 @@ public abstract class DatagramSocketImpl implements SocketOptions { ...@@ -174,7 +174,7 @@ public abstract class DatagramSocketImpl implements SocketOptions {
* Retrieve the TTL (time-to-live) option. * Retrieve the TTL (time-to-live) option.
* @exception IOException if an I/O exception occurs * @exception IOException if an I/O exception occurs
* while retrieving the time-to-live option * while retrieving the time-to-live option
* @return an <tt>int</tt> representing the time-to-live value * @return an {@code int} representing the time-to-live value
* @see #setTimeToLive(int) * @see #setTimeToLive(int)
*/ */
protected abstract int getTimeToLive() throws IOException; protected abstract int getTimeToLive() throws IOException;
...@@ -227,7 +227,7 @@ public abstract class DatagramSocketImpl implements SocketOptions { ...@@ -227,7 +227,7 @@ public abstract class DatagramSocketImpl implements SocketOptions {
/** /**
* Gets the local port. * Gets the local port.
* @return an <tt>int</tt> representing the local port value * @return an {@code int} representing the local port value
*/ */
protected int getLocalPort() { protected int getLocalPort() {
return localPort; return localPort;
...@@ -235,7 +235,7 @@ public abstract class DatagramSocketImpl implements SocketOptions { ...@@ -235,7 +235,7 @@ public abstract class DatagramSocketImpl implements SocketOptions {
/** /**
* Gets the datagram socket file descriptor. * Gets the datagram socket file descriptor.
* @return a <tt>FileDescriptor</tt> object representing the datagram socket * @return a {@code FileDescriptor} object representing the datagram socket
* file descriptor * file descriptor
*/ */
protected FileDescriptor getFileDescriptor() { protected FileDescriptor getFileDescriptor() {
......
/* /*
* Copyright (c) 1999, 2002, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -27,7 +27,7 @@ package java.net; ...@@ -27,7 +27,7 @@ package java.net;
/** /**
* This interface defines a factory for datagram socket implementations. It * This interface defines a factory for datagram socket implementations. It
* is used by the classes <code>DatagramSocket</code> to create actual socket * is used by the classes {@code DatagramSocket} to create actual socket
* implementations. * implementations.
* *
* @author Yingxian Wang * @author Yingxian Wang
...@@ -37,9 +37,9 @@ package java.net; ...@@ -37,9 +37,9 @@ package java.net;
public public
interface DatagramSocketImplFactory { interface DatagramSocketImplFactory {
/** /**
* Creates a new <code>DatagramSocketImpl</code> instance. * Creates a new {@code DatagramSocketImpl} instance.
* *
* @return a new instance of <code>DatagramSocketImpl</code>. * @return a new instance of {@code DatagramSocketImpl}.
* @see java.net.DatagramSocketImpl * @see java.net.DatagramSocketImpl
*/ */
DatagramSocketImpl createDatagramSocketImpl(); DatagramSocketImpl createDatagramSocketImpl();
......
/* /*
* Copyright (c) 1996, 1999, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -37,7 +37,7 @@ public interface FileNameMap { ...@@ -37,7 +37,7 @@ public interface FileNameMap {
/** /**
* Gets the MIME type for the specified file name. * Gets the MIME type for the specified file name.
* @param fileName the specified file name * @param fileName the specified file name
* @return a <code>String</code> indicating the MIME * @return a {@code String} indicating the MIME
* type for the specified file name. * type for the specified file name.
*/ */
public String getContentTypeFor(String fileName); public String getContentTypeFor(String fileName);
......
/* /*
* Copyright (c) 2005, 2012, 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -470,7 +470,7 @@ public final class HttpCookie implements Cloneable { ...@@ -470,7 +470,7 @@ public final class HttpCookie implements Cloneable {
* protocol. * protocol.
* *
* @return {@code false} if the cookie can be sent over any standard * @return {@code false} if the cookie can be sent over any standard
* protocol; otherwise, <code>true</code> * protocol; otherwise, {@code true}
* *
* @see #setSecure * @see #setSecure
*/ */
......
/* /*
* Copyright (c) 2004, 2008, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2004, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -43,7 +43,7 @@ class HttpRetryException extends IOException { ...@@ -43,7 +43,7 @@ class HttpRetryException extends IOException {
private String location; private String location;
/** /**
* Constructs a new <code>HttpRetryException</code> from the * Constructs a new {@code HttpRetryException} from the
* specified response code and exception detail message * specified response code and exception detail message
* *
* @param detail the detail message. * @param detail the detail message.
...@@ -55,7 +55,7 @@ class HttpRetryException extends IOException { ...@@ -55,7 +55,7 @@ class HttpRetryException extends IOException {
} }
/** /**
* Constructs a new <code>HttpRetryException</code> with detail message * Constructs a new {@code HttpRetryException} with detail message
* responseCode and the contents of the Location response header field. * responseCode and the contents of the Location response header field.
* *
* @param detail the detail message. * @param detail the detail message.
......
/* /*
* Copyright (c) 1996, 2011, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -76,14 +76,14 @@ abstract public class HttpURLConnection extends URLConnection { ...@@ -76,14 +76,14 @@ abstract public class HttpURLConnection extends URLConnection {
/** /**
* The chunk-length when using chunked encoding streaming mode for output. * The chunk-length when using chunked encoding streaming mode for output.
* A value of <code>-1</code> means chunked encoding is disabled for output. * A value of {@code -1} means chunked encoding is disabled for output.
* @since 1.5 * @since 1.5
*/ */
protected int chunkLength = -1; protected int chunkLength = -1;
/** /**
* The fixed content-length when using fixed-length streaming mode. * The fixed content-length when using fixed-length streaming mode.
* A value of <code>-1</code> means fixed-length streaming mode is disabled * A value of {@code -1} means fixed-length streaming mode is disabled
* for output. * for output.
* *
* <P> <B>NOTE:</B> {@link #fixedContentLengthLong} is recommended instead * <P> <B>NOTE:</B> {@link #fixedContentLengthLong} is recommended instead
...@@ -103,15 +103,15 @@ abstract public class HttpURLConnection extends URLConnection { ...@@ -103,15 +103,15 @@ abstract public class HttpURLConnection extends URLConnection {
protected long fixedContentLengthLong = -1; protected long fixedContentLengthLong = -1;
/** /**
* Returns the key for the <code>n</code><sup>th</sup> header field. * Returns the key for the {@code n}<sup>th</sup> header field.
* Some implementations may treat the <code>0</code><sup>th</sup> * Some implementations may treat the {@code 0}<sup>th</sup>
* header field as special, i.e. as the status line returned by the HTTP * header field as special, i.e. as the status line returned by the HTTP
* server. In this case, {@link #getHeaderField(int) getHeaderField(0)} returns the status * server. In this case, {@link #getHeaderField(int) getHeaderField(0)} returns the status
* line, but <code>getHeaderFieldKey(0)</code> returns null. * line, but {@code getHeaderFieldKey(0)} returns null.
* *
* @param n an index, where {@code n >=0}. * @param n an index, where {@code n >=0}.
* @return the key for the <code>n</code><sup>th</sup> header field, * @return the key for the {@code n}<sup>th</sup> header field,
* or <code>null</code> if the key does not exist. * or {@code null} if the key does not exist.
*/ */
public String getHeaderFieldKey (int n) { public String getHeaderFieldKey (int n) {
return null; return null;
...@@ -251,8 +251,8 @@ abstract public class HttpURLConnection extends URLConnection { ...@@ -251,8 +251,8 @@ abstract public class HttpURLConnection extends URLConnection {
} }
/** /**
* Returns the value for the <code>n</code><sup>th</sup> header field. * Returns the value for the {@code n}<sup>th</sup> header field.
* Some implementations may treat the <code>0</code><sup>th</sup> * Some implementations may treat the {@code 0}<sup>th</sup>
* header field as special, i.e. as the status line returned by the HTTP * header field as special, i.e. as the status line returned by the HTTP
* server. * server.
* <p> * <p>
...@@ -261,8 +261,8 @@ abstract public class HttpURLConnection extends URLConnection { ...@@ -261,8 +261,8 @@ abstract public class HttpURLConnection extends URLConnection {
* the headers in the message. * the headers in the message.
* *
* @param n an index, where {@code n>=0}. * @param n an index, where {@code n>=0}.
* @return the value of the <code>n</code><sup>th</sup> header field, * @return the value of the {@code n}<sup>th</sup> header field,
* or <code>null</code> if the value does not exist. * or {@code null} if the value does not exist.
* @see java.net.HttpURLConnection#getHeaderFieldKey(int) * @see java.net.HttpURLConnection#getHeaderFieldKey(int)
*/ */
public String getHeaderField(int n) { public String getHeaderField(int n) {
...@@ -270,7 +270,7 @@ abstract public class HttpURLConnection extends URLConnection { ...@@ -270,7 +270,7 @@ abstract public class HttpURLConnection extends URLConnection {
} }
/** /**
* An <code>int</code> representing the three digit HTTP Status-Code. * An {@code int} representing the three digit HTTP Status-Code.
* <ul> * <ul>
* <li> 1xx: Informational * <li> 1xx: Informational
* <li> 2xx: Success * <li> 2xx: Success
...@@ -292,12 +292,12 @@ abstract public class HttpURLConnection extends URLConnection { ...@@ -292,12 +292,12 @@ abstract public class HttpURLConnection extends URLConnection {
private static boolean followRedirects = true; private static boolean followRedirects = true;
/** /**
* If <code>true</code>, the protocol will automatically follow redirects. * If {@code true}, the protocol will automatically follow redirects.
* If <code>false</code>, the protocol will not automatically follow * If {@code false}, the protocol will not automatically follow
* redirects. * redirects.
* <p> * <p>
* This field is set by the <code>setInstanceFollowRedirects</code> * This field is set by the {@code setInstanceFollowRedirects}
* method. Its value is returned by the <code>getInstanceFollowRedirects</code> * method. Its value is returned by the {@code getInstanceFollowRedirects}
* method. * method.
* <p> * <p>
* Its default value is based on the value of the static followRedirects * Its default value is based on the value of the static followRedirects
...@@ -328,14 +328,14 @@ abstract public class HttpURLConnection extends URLConnection { ...@@ -328,14 +328,14 @@ abstract public class HttpURLConnection extends URLConnection {
* cannot change this variable. * cannot change this variable.
* <p> * <p>
* If there is a security manager, this method first calls * If there is a security manager, this method first calls
* the security manager's <code>checkSetFactory</code> method * the security manager's {@code checkSetFactory} method
* to ensure the operation is allowed. * to ensure the operation is allowed.
* This could result in a SecurityException. * This could result in a SecurityException.
* *
* @param set a <code>boolean</code> indicating whether or not * @param set a {@code boolean} indicating whether or not
* to follow HTTP redirects. * to follow HTTP redirects.
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* <code>checkSetFactory</code> method doesn't * {@code checkSetFactory} method doesn't
* allow the operation. * allow the operation.
* @see SecurityManager#checkSetFactory * @see SecurityManager#checkSetFactory
* @see #getFollowRedirects() * @see #getFollowRedirects()
...@@ -350,12 +350,12 @@ abstract public class HttpURLConnection extends URLConnection { ...@@ -350,12 +350,12 @@ abstract public class HttpURLConnection extends URLConnection {
} }
/** /**
* Returns a <code>boolean</code> indicating * Returns a {@code boolean} indicating
* whether or not HTTP redirects (3xx) should * whether or not HTTP redirects (3xx) should
* be automatically followed. * be automatically followed.
* *
* @return <code>true</code> if HTTP redirects should * @return {@code true} if HTTP redirects should
* be automatically followed, <tt>false</tt> if not. * be automatically followed, {@code false} if not.
* @see #setFollowRedirects(boolean) * @see #setFollowRedirects(boolean)
*/ */
public static boolean getFollowRedirects() { public static boolean getFollowRedirects() {
...@@ -364,13 +364,13 @@ abstract public class HttpURLConnection extends URLConnection { ...@@ -364,13 +364,13 @@ abstract public class HttpURLConnection extends URLConnection {
/** /**
* Sets whether HTTP redirects (requests with response code 3xx) should * Sets whether HTTP redirects (requests with response code 3xx) should
* be automatically followed by this <code>HttpURLConnection</code> * be automatically followed by this {@code HttpURLConnection}
* instance. * instance.
* <p> * <p>
* The default value comes from followRedirects, which defaults to * The default value comes from followRedirects, which defaults to
* true. * true.
* *
* @param followRedirects a <code>boolean</code> indicating * @param followRedirects a {@code boolean} indicating
* whether or not to follow HTTP redirects. * whether or not to follow HTTP redirects.
* *
* @see java.net.HttpURLConnection#instanceFollowRedirects * @see java.net.HttpURLConnection#instanceFollowRedirects
...@@ -382,11 +382,11 @@ abstract public class HttpURLConnection extends URLConnection { ...@@ -382,11 +382,11 @@ abstract public class HttpURLConnection extends URLConnection {
} }
/** /**
* Returns the value of this <code>HttpURLConnection</code>'s * Returns the value of this {@code HttpURLConnection}'s
* <code>instanceFollowRedirects</code> field. * {@code instanceFollowRedirects} field.
* *
* @return the value of this <code>HttpURLConnection</code>'s * @return the value of this {@code HttpURLConnection}'s
* <code>instanceFollowRedirects</code> field. * {@code instanceFollowRedirects} field.
* @see java.net.HttpURLConnection#instanceFollowRedirects * @see java.net.HttpURLConnection#instanceFollowRedirects
* @see #setInstanceFollowRedirects(boolean) * @see #setInstanceFollowRedirects(boolean)
* @since 1.3 * @since 1.3
...@@ -540,7 +540,7 @@ abstract public class HttpURLConnection extends URLConnection { ...@@ -540,7 +540,7 @@ abstract public class HttpURLConnection extends URLConnection {
* Returns null if none could be discerned from the responses * Returns null if none could be discerned from the responses
* (the result was not valid HTTP). * (the result was not valid HTTP).
* @throws IOException if an error occurred connecting to the server. * @throws IOException if an error occurred connecting to the server.
* @return the HTTP response message, or <code>null</code> * @return the HTTP response message, or {@code null}
*/ */
public String getResponseMessage() throws IOException { public String getResponseMessage() throws IOException {
getResponseCode(); getResponseCode();
...@@ -583,7 +583,7 @@ abstract public class HttpURLConnection extends URLConnection { ...@@ -583,7 +583,7 @@ abstract public class HttpURLConnection extends URLConnection {
* @exception IOException if an error occurs while computing * @exception IOException if an error occurs while computing
* the permission. * the permission.
* *
* @return a <code>SocketPermission</code> object representing the * @return a {@code SocketPermission} object representing the
* permission necessary to connect to the destination * permission necessary to connect to the destination
* host and port. * host and port.
*/ */
......
/* /*
* 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -104,7 +104,7 @@ public final class IDN { ...@@ -104,7 +104,7 @@ public final class IDN {
* @param input the string to be processed * @param input the string to be processed
* @param flag process flag; can be 0 or any logical OR of possible flags * @param flag process flag; can be 0 or any logical OR of possible flags
* *
* @return the translated <tt>String</tt> * @return the translated {@code String}
* *
* @throws IllegalArgumentException if the input string doesn't conform to RFC 3490 specification * @throws IllegalArgumentException if the input string doesn't conform to RFC 3490 specification
*/ */
...@@ -130,13 +130,13 @@ public final class IDN { ...@@ -130,13 +130,13 @@ public final class IDN {
* *
* <p> This convenience method works as if by invoking the * <p> This convenience method works as if by invoking the
* two-argument counterpart as follows: * two-argument counterpart as follows:
* <blockquote><tt> * <blockquote>
* {@link #toASCII(String, int) toASCII}(input,&nbsp;0); * {@link #toASCII(String, int) toASCII}(input,&nbsp;0);
* </tt></blockquote> * </blockquote>
* *
* @param input the string to be processed * @param input the string to be processed
* *
* @return the translated <tt>String</tt> * @return the translated {@code String}
* *
* @throws IllegalArgumentException if the input string doesn't conform to RFC 3490 specification * @throws IllegalArgumentException if the input string doesn't conform to RFC 3490 specification
*/ */
...@@ -161,7 +161,7 @@ public final class IDN { ...@@ -161,7 +161,7 @@ public final class IDN {
* @param input the string to be processed * @param input the string to be processed
* @param flag process flag; can be 0 or any logical OR of possible flags * @param flag process flag; can be 0 or any logical OR of possible flags
* *
* @return the translated <tt>String</tt> * @return the translated {@code String}
*/ */
public static String toUnicode(String input, int flag) { public static String toUnicode(String input, int flag) {
int p = 0, q = 0; int p = 0, q = 0;
...@@ -184,13 +184,13 @@ public final class IDN { ...@@ -184,13 +184,13 @@ public final class IDN {
* *
* <p> This convenience method works as if by invoking the * <p> This convenience method works as if by invoking the
* two-argument counterpart as follows: * two-argument counterpart as follows:
* <blockquote><tt> * <blockquote>
* {@link #toUnicode(String, int) toUnicode}(input,&nbsp;0); * {@link #toUnicode(String, int) toUnicode}(input,&nbsp;0);
* </tt></blockquote> * </blockquote>
* *
* @param input the string to be processed * @param input the string to be processed
* *
* @return the translated <tt>String</tt> * @return the translated {@code String}
*/ */
public static String toUnicode(String input) { public static String toUnicode(String input) {
return toUnicode(input, 0); return toUnicode(input, 0);
......
...@@ -42,10 +42,10 @@ import java.io.ObjectStreamException; ...@@ -42,10 +42,10 @@ import java.io.ObjectStreamException;
* takes one of the following forms: * takes one of the following forms:
* *
* <blockquote><table cellpadding=0 cellspacing=0 summary="layout"> * <blockquote><table cellpadding=0 cellspacing=0 summary="layout">
* <tr><td><tt>d.d.d.d</tt></td></tr> * <tr><td>{@code d.d.d.d}</td></tr>
* <tr><td><tt>d.d.d</tt></td></tr> * <tr><td>{@code d.d.d}</td></tr>
* <tr><td><tt>d.d</tt></td></tr> * <tr><td>{@code d.d}</td></tr>
* <tr><td><tt>d</tt></td></tr> * <tr><td>{@code d}</td></tr>
* </table></blockquote> * </table></blockquote>
* *
* <p> When four parts are specified, each is interpreted as a byte of * <p> When four parts are specified, each is interpreted as a byte of
...@@ -153,7 +153,7 @@ class Inet4Address extends InetAddress { ...@@ -153,7 +153,7 @@ class Inet4Address extends InetAddress {
* Utility routine to check if the InetAddress is an * Utility routine to check if the InetAddress is an
* IP multicast address. IP multicast address is a Class D * IP multicast address. IP multicast address is a Class D
* address i.e first four bits of the address are 1110. * address i.e first four bits of the address are 1110.
* @return a <code>boolean</code> indicating if the InetAddress is * @return a {@code boolean} indicating if the InetAddress is
* an IP multicast address * an IP multicast address
* @since JDK1.1 * @since JDK1.1
*/ */
...@@ -163,7 +163,7 @@ class Inet4Address extends InetAddress { ...@@ -163,7 +163,7 @@ class Inet4Address extends InetAddress {
/** /**
* Utility routine to check if the InetAddress in a wildcard address. * Utility routine to check if the InetAddress in a wildcard address.
* @return a <code>boolean</code> indicating if the Inetaddress is * @return a {@code boolean} indicating if the Inetaddress is
* a wildcard address. * a wildcard address.
* @since 1.4 * @since 1.4
*/ */
...@@ -174,7 +174,7 @@ class Inet4Address extends InetAddress { ...@@ -174,7 +174,7 @@ class Inet4Address extends InetAddress {
/** /**
* Utility routine to check if the InetAddress is a loopback address. * Utility routine to check if the InetAddress is a loopback address.
* *
* @return a <code>boolean</code> indicating if the InetAddress is * @return a {@code boolean} indicating if the InetAddress is
* a loopback address; or false otherwise. * a loopback address; or false otherwise.
* @since 1.4 * @since 1.4
*/ */
...@@ -187,7 +187,7 @@ class Inet4Address extends InetAddress { ...@@ -187,7 +187,7 @@ class Inet4Address extends InetAddress {
/** /**
* Utility routine to check if the InetAddress is an link local address. * Utility routine to check if the InetAddress is an link local address.
* *
* @return a <code>boolean</code> indicating if the InetAddress is * @return a {@code boolean} indicating if the InetAddress is
* a link local address; or false if address is not a link local unicast address. * a link local address; or false if address is not a link local unicast address.
* @since 1.4 * @since 1.4
*/ */
...@@ -204,7 +204,7 @@ class Inet4Address extends InetAddress { ...@@ -204,7 +204,7 @@ class Inet4Address extends InetAddress {
/** /**
* Utility routine to check if the InetAddress is a site local address. * Utility routine to check if the InetAddress is a site local address.
* *
* @return a <code>boolean</code> indicating if the InetAddress is * @return a {@code boolean} indicating if the InetAddress is
* a site local address; or false if address is not a site local unicast address. * a site local address; or false if address is not a site local unicast address.
* @since 1.4 * @since 1.4
*/ */
...@@ -224,7 +224,7 @@ class Inet4Address extends InetAddress { ...@@ -224,7 +224,7 @@ class Inet4Address extends InetAddress {
/** /**
* Utility routine to check if the multicast address has global scope. * Utility routine to check if the multicast address has global scope.
* *
* @return a <code>boolean</code> indicating if the address has * @return a {@code boolean} indicating if the address has
* is a multicast address of global scope, false if it is not * is a multicast address of global scope, false if it is not
* of global scope or it is not a multicast address * of global scope or it is not a multicast address
* @since 1.4 * @since 1.4
...@@ -240,7 +240,7 @@ class Inet4Address extends InetAddress { ...@@ -240,7 +240,7 @@ class Inet4Address extends InetAddress {
/** /**
* Utility routine to check if the multicast address has node scope. * Utility routine to check if the multicast address has node scope.
* *
* @return a <code>boolean</code> indicating if the address has * @return a {@code boolean} indicating if the address has
* is a multicast address of node-local scope, false if it is not * is a multicast address of node-local scope, false if it is not
* of node-local scope or it is not a multicast address * of node-local scope or it is not a multicast address
* @since 1.4 * @since 1.4
...@@ -253,7 +253,7 @@ class Inet4Address extends InetAddress { ...@@ -253,7 +253,7 @@ class Inet4Address extends InetAddress {
/** /**
* Utility routine to check if the multicast address has link scope. * Utility routine to check if the multicast address has link scope.
* *
* @return a <code>boolean</code> indicating if the address has * @return a {@code boolean} indicating if the address has
* is a multicast address of link-local scope, false if it is not * is a multicast address of link-local scope, false if it is not
* of link-local scope or it is not a multicast address * of link-local scope or it is not a multicast address
* @since 1.4 * @since 1.4
...@@ -269,7 +269,7 @@ class Inet4Address extends InetAddress { ...@@ -269,7 +269,7 @@ class Inet4Address extends InetAddress {
/** /**
* Utility routine to check if the multicast address has site scope. * Utility routine to check if the multicast address has site scope.
* *
* @return a <code>boolean</code> indicating if the address has * @return a {@code boolean} indicating if the address has
* is a multicast address of site-local scope, false if it is not * is a multicast address of site-local scope, false if it is not
* of site-local scope or it is not a multicast address * of site-local scope or it is not a multicast address
* @since 1.4 * @since 1.4
...@@ -284,7 +284,7 @@ class Inet4Address extends InetAddress { ...@@ -284,7 +284,7 @@ class Inet4Address extends InetAddress {
/** /**
* Utility routine to check if the multicast address has organization scope. * Utility routine to check if the multicast address has organization scope.
* *
* @return a <code>boolean</code> indicating if the address has * @return a {@code boolean} indicating if the address has
* is a multicast address of organization-local scope, * is a multicast address of organization-local scope,
* false if it is not of organization-local scope * false if it is not of organization-local scope
* or it is not a multicast address * or it is not a multicast address
...@@ -299,9 +299,9 @@ class Inet4Address extends InetAddress { ...@@ -299,9 +299,9 @@ class Inet4Address extends InetAddress {
} }
/** /**
* Returns the raw IP address of this <code>InetAddress</code> * Returns the raw IP address of this {@code InetAddress}
* object. The result is in network byte order: the highest order * object. The result is in network byte order: the highest order
* byte of the address is in <code>getAddress()[0]</code>. * byte of the address is in {@code getAddress()[0]}.
* *
* @return the raw IP address of this object. * @return the raw IP address of this object.
*/ */
...@@ -337,18 +337,18 @@ class Inet4Address extends InetAddress { ...@@ -337,18 +337,18 @@ class Inet4Address extends InetAddress {
/** /**
* Compares this object against the specified object. * Compares this object against the specified object.
* The result is <code>true</code> if and only if the argument is * The result is {@code true} if and only if the argument is
* not <code>null</code> and it represents the same IP address as * not {@code null} and it represents the same IP address as
* this object. * this object.
* <p> * <p>
* Two instances of <code>InetAddress</code> represent the same IP * Two instances of {@code InetAddress} represent the same IP
* address if the length of the byte arrays returned by * address if the length of the byte arrays returned by
* <code>getAddress</code> is the same for both, and each of the * {@code getAddress} is the same for both, and each of the
* array components is the same for the byte arrays. * array components is the same for the byte arrays.
* *
* @param obj the object to compare against. * @param obj the object to compare against.
* @return <code>true</code> if the objects are the same; * @return {@code true} if the objects are the same;
* <code>false</code> otherwise. * {@code false} otherwise.
* @see java.net.InetAddress#getAddress() * @see java.net.InetAddress#getAddress()
*/ */
public boolean equals(Object obj) { public boolean equals(Object obj) {
......
...@@ -47,7 +47,7 @@ import java.util.Enumeration; ...@@ -47,7 +47,7 @@ import java.util.Enumeration;
* address. This is the full form. For example, * address. This is the full form. For example,
* *
* <blockquote><table cellpadding=0 cellspacing=0 summary="layout"> * <blockquote><table cellpadding=0 cellspacing=0 summary="layout">
* <tr><td><tt>1080:0:0:0:8:800:200C:417A</tt><td></tr> * <tr><td>{@code 1080:0:0:0:8:800:200C:417A}<td></tr>
* </table></blockquote> * </table></blockquote>
* *
* <p> Note that it is not necessary to write the leading zeros in * <p> Note that it is not necessary to write the leading zeros in
...@@ -64,7 +64,7 @@ import java.util.Enumeration; ...@@ -64,7 +64,7 @@ import java.util.Enumeration;
* zeros in an address. For example, * zeros in an address. For example,
* *
* <blockquote><table cellpadding=0 cellspacing=0 summary="layout"> * <blockquote><table cellpadding=0 cellspacing=0 summary="layout">
* <tr><td><tt>1080::8:800:200C:417A</tt><td></tr> * <tr><td>{@code 1080::8:800:200C:417A}<td></tr>
* </table></blockquote> * </table></blockquote>
* *
* <li><p> An alternative form that is sometimes more convenient * <li><p> An alternative form that is sometimes more convenient
...@@ -75,8 +75,8 @@ import java.util.Enumeration; ...@@ -75,8 +75,8 @@ import java.util.Enumeration;
* standard IPv4 representation address, for example, * standard IPv4 representation address, for example,
* *
* <blockquote><table cellpadding=0 cellspacing=0 summary="layout"> * <blockquote><table cellpadding=0 cellspacing=0 summary="layout">
* <tr><td><tt>::FFFF:129.144.52.38</tt><td></tr> * <tr><td>{@code ::FFFF:129.144.52.38}<td></tr>
* <tr><td><tt>::129.144.52.38</tt><td></tr> * <tr><td>{@code ::129.144.52.38}<td></tr>
* </table></blockquote> * </table></blockquote>
* *
* <p> where "::FFFF:d.d.d.d" and "::d.d.d.d" are, respectively, the * <p> where "::FFFF:d.d.d.d" and "::d.d.d.d" are, respectively, the
...@@ -85,23 +85,23 @@ import java.util.Enumeration; ...@@ -85,23 +85,23 @@ import java.util.Enumeration;
* in the "d.d.d.d" form. The following forms are invalid: * in the "d.d.d.d" form. The following forms are invalid:
* *
* <blockquote><table cellpadding=0 cellspacing=0 summary="layout"> * <blockquote><table cellpadding=0 cellspacing=0 summary="layout">
* <tr><td><tt>::FFFF:d.d.d</tt><td></tr> * <tr><td>{@code ::FFFF:d.d.d}<td></tr>
* <tr><td><tt>::FFFF:d.d</tt><td></tr> * <tr><td>{@code ::FFFF:d.d}<td></tr>
* <tr><td><tt>::d.d.d</tt><td></tr> * <tr><td>{@code ::d.d.d}<td></tr>
* <tr><td><tt>::d.d</tt><td></tr> * <tr><td>{@code ::d.d}<td></tr>
* </table></blockquote> * </table></blockquote>
* *
* <p> The following form: * <p> The following form:
* *
* <blockquote><table cellpadding=0 cellspacing=0 summary="layout"> * <blockquote><table cellpadding=0 cellspacing=0 summary="layout">
* <tr><td><tt>::FFFF:d</tt><td></tr> * <tr><td>{@code ::FFFF:d}<td></tr>
* </table></blockquote> * </table></blockquote>
* *
* <p> is valid, however it is an unconventional representation of * <p> is valid, however it is an unconventional representation of
* the IPv4-compatible IPv6 address, * the IPv4-compatible IPv6 address,
* *
* <blockquote><table cellpadding=0 cellspacing=0 summary="layout"> * <blockquote><table cellpadding=0 cellspacing=0 summary="layout">
* <tr><td><tt>::255.255.0.d</tt><td></tr> * <tr><td>{@code ::255.255.0.d}<td></tr>
* </table></blockquote> * </table></blockquote>
* *
* <p> while "::d" corresponds to the general IPv6 address * <p> while "::d" corresponds to the general IPv6 address
...@@ -258,7 +258,7 @@ class Inet6Address extends InetAddress { ...@@ -258,7 +258,7 @@ class Inet6Address extends InetAddress {
* Create an Inet6Address in the exact manner of {@link * Create an Inet6Address in the exact manner of {@link
* InetAddress#getByAddress(String,byte[])} except that the IPv6 scope_id is * InetAddress#getByAddress(String,byte[])} except that the IPv6 scope_id is
* set to the value corresponding to the given interface for the address * set to the value corresponding to the given interface for the address
* type specified in <code>addr</code>. The call will fail with an * type specified in {@code addr}. The call will fail with an
* UnknownHostException if the given interface does not have a numeric * UnknownHostException if the given interface does not have a numeric
* scope_id assigned for the given address type (eg. link-local or site-local). * scope_id assigned for the given address type (eg. link-local or site-local).
* See <a href="Inet6Address.html#scoped">here</a> for a description of IPv6 * See <a href="Inet6Address.html#scoped">here</a> for a description of IPv6
......
...@@ -296,7 +296,7 @@ class InetAddress implements java.io.Serializable { ...@@ -296,7 +296,7 @@ class InetAddress implements java.io.Serializable {
/** /**
* Utility routine to check if the InetAddress is an * Utility routine to check if the InetAddress is an
* IP multicast address. * IP multicast address.
* @return a <code>boolean</code> indicating if the InetAddress is * @return a {@code boolean} indicating if the InetAddress is
* an IP multicast address * an IP multicast address
* @since JDK1.1 * @since JDK1.1
*/ */
...@@ -306,7 +306,7 @@ class InetAddress implements java.io.Serializable { ...@@ -306,7 +306,7 @@ class InetAddress implements java.io.Serializable {
/** /**
* Utility routine to check if the InetAddress in a wildcard address. * Utility routine to check if the InetAddress in a wildcard address.
* @return a <code>boolean</code> indicating if the Inetaddress is * @return a {@code boolean} indicating if the Inetaddress is
* a wildcard address. * a wildcard address.
* @since 1.4 * @since 1.4
*/ */
...@@ -317,7 +317,7 @@ class InetAddress implements java.io.Serializable { ...@@ -317,7 +317,7 @@ class InetAddress implements java.io.Serializable {
/** /**
* Utility routine to check if the InetAddress is a loopback address. * Utility routine to check if the InetAddress is a loopback address.
* *
* @return a <code>boolean</code> indicating if the InetAddress is * @return a {@code boolean} indicating if the InetAddress is
* a loopback address; or false otherwise. * a loopback address; or false otherwise.
* @since 1.4 * @since 1.4
*/ */
...@@ -328,7 +328,7 @@ class InetAddress implements java.io.Serializable { ...@@ -328,7 +328,7 @@ class InetAddress implements java.io.Serializable {
/** /**
* Utility routine to check if the InetAddress is an link local address. * Utility routine to check if the InetAddress is an link local address.
* *
* @return a <code>boolean</code> indicating if the InetAddress is * @return a {@code boolean} indicating if the InetAddress is
* a link local address; or false if address is not a link local unicast address. * a link local address; or false if address is not a link local unicast address.
* @since 1.4 * @since 1.4
*/ */
...@@ -339,7 +339,7 @@ class InetAddress implements java.io.Serializable { ...@@ -339,7 +339,7 @@ class InetAddress implements java.io.Serializable {
/** /**
* Utility routine to check if the InetAddress is a site local address. * Utility routine to check if the InetAddress is a site local address.
* *
* @return a <code>boolean</code> indicating if the InetAddress is * @return a {@code boolean} indicating if the InetAddress is
* a site local address; or false if address is not a site local unicast address. * a site local address; or false if address is not a site local unicast address.
* @since 1.4 * @since 1.4
*/ */
...@@ -350,7 +350,7 @@ class InetAddress implements java.io.Serializable { ...@@ -350,7 +350,7 @@ class InetAddress implements java.io.Serializable {
/** /**
* Utility routine to check if the multicast address has global scope. * Utility routine to check if the multicast address has global scope.
* *
* @return a <code>boolean</code> indicating if the address has * @return a {@code boolean} indicating if the address has
* is a multicast address of global scope, false if it is not * is a multicast address of global scope, false if it is not
* of global scope or it is not a multicast address * of global scope or it is not a multicast address
* @since 1.4 * @since 1.4
...@@ -362,7 +362,7 @@ class InetAddress implements java.io.Serializable { ...@@ -362,7 +362,7 @@ class InetAddress implements java.io.Serializable {
/** /**
* Utility routine to check if the multicast address has node scope. * Utility routine to check if the multicast address has node scope.
* *
* @return a <code>boolean</code> indicating if the address has * @return a {@code boolean} indicating if the address has
* is a multicast address of node-local scope, false if it is not * is a multicast address of node-local scope, false if it is not
* of node-local scope or it is not a multicast address * of node-local scope or it is not a multicast address
* @since 1.4 * @since 1.4
...@@ -374,7 +374,7 @@ class InetAddress implements java.io.Serializable { ...@@ -374,7 +374,7 @@ class InetAddress implements java.io.Serializable {
/** /**
* Utility routine to check if the multicast address has link scope. * Utility routine to check if the multicast address has link scope.
* *
* @return a <code>boolean</code> indicating if the address has * @return a {@code boolean} indicating if the address has
* is a multicast address of link-local scope, false if it is not * is a multicast address of link-local scope, false if it is not
* of link-local scope or it is not a multicast address * of link-local scope or it is not a multicast address
* @since 1.4 * @since 1.4
...@@ -386,7 +386,7 @@ class InetAddress implements java.io.Serializable { ...@@ -386,7 +386,7 @@ class InetAddress implements java.io.Serializable {
/** /**
* Utility routine to check if the multicast address has site scope. * Utility routine to check if the multicast address has site scope.
* *
* @return a <code>boolean</code> indicating if the address has * @return a {@code boolean} indicating if the address has
* is a multicast address of site-local scope, false if it is not * is a multicast address of site-local scope, false if it is not
* of site-local scope or it is not a multicast address * of site-local scope or it is not a multicast address
* @since 1.4 * @since 1.4
...@@ -398,7 +398,7 @@ class InetAddress implements java.io.Serializable { ...@@ -398,7 +398,7 @@ class InetAddress implements java.io.Serializable {
/** /**
* Utility routine to check if the multicast address has organization scope. * Utility routine to check if the multicast address has organization scope.
* *
* @return a <code>boolean</code> indicating if the address has * @return a {@code boolean} indicating if the address has
* is a multicast address of organization-local scope, * is a multicast address of organization-local scope,
* false if it is not of organization-local scope * false if it is not of organization-local scope
* or it is not a multicast address * or it is not a multicast address
...@@ -424,9 +424,9 @@ class InetAddress implements java.io.Serializable { ...@@ -424,9 +424,9 @@ class InetAddress implements java.io.Serializable {
* in an IllegalArgumentException being thrown. * in an IllegalArgumentException being thrown.
* *
* @param timeout the time, in milliseconds, before the call aborts * @param timeout the time, in milliseconds, before the call aborts
* @return a <code>boolean</code> indicating if the address is reachable. * @return a {@code boolean} indicating if the address is reachable.
* @throws IOException if a network error occurs * @throws IOException if a network error occurs
* @throws IllegalArgumentException if <code>timeout</code> is negative. * @throws IllegalArgumentException if {@code timeout} is negative.
* @since 1.5 * @since 1.5
*/ */
public boolean isReachable(int timeout) throws IOException { public boolean isReachable(int timeout) throws IOException {
...@@ -442,10 +442,10 @@ class InetAddress implements java.io.Serializable { ...@@ -442,10 +442,10 @@ class InetAddress implements java.io.Serializable {
* privilege can be obtained, otherwise it will try to establish * privilege can be obtained, otherwise it will try to establish
* a TCP connection on port 7 (Echo) of the destination host. * a TCP connection on port 7 (Echo) of the destination host.
* <p> * <p>
* The <code>network interface</code> and <code>ttl</code> parameters * The {@code network interface} and {@code ttl} parameters
* let the caller specify which network interface the test will go through * let the caller specify which network interface the test will go through
* and the maximum number of hops the packets should go through. * and the maximum number of hops the packets should go through.
* A negative value for the <code>ttl</code> will result in an * A negative value for the {@code ttl} will result in an
* IllegalArgumentException being thrown. * IllegalArgumentException being thrown.
* <p> * <p>
* The timeout value, in milliseconds, indicates the maximum amount of time * The timeout value, in milliseconds, indicates the maximum amount of time
...@@ -458,9 +458,9 @@ class InetAddress implements java.io.Serializable { ...@@ -458,9 +458,9 @@ class InetAddress implements java.io.Serializable {
* @param ttl the maximum numbers of hops to try or 0 for the * @param ttl the maximum numbers of hops to try or 0 for the
* default * default
* @param timeout the time, in milliseconds, before the call aborts * @param timeout the time, in milliseconds, before the call aborts
* @throws IllegalArgumentException if either <code>timeout</code> * @throws IllegalArgumentException if either {@code timeout}
* or <code>ttl</code> are negative. * or {@code ttl} are negative.
* @return a <code>boolean</code>indicating if the address is reachable. * @return a {@code boolean}indicating if the address is reachable.
* @throws IOException if a network error occurs * @throws IOException if a network error occurs
* @since 1.5 * @since 1.5
*/ */
...@@ -486,8 +486,8 @@ class InetAddress implements java.io.Serializable { ...@@ -486,8 +486,8 @@ class InetAddress implements java.io.Serializable {
* {@link #getCanonicalHostName() getCanonicalHostName}. * {@link #getCanonicalHostName() getCanonicalHostName}.
* *
* <p>If there is a security manager, its * <p>If there is a security manager, its
* <code>checkConnect</code> method is first called * {@code checkConnect} method is first called
* with the hostname and <code>-1</code> * with the hostname and {@code -1}
* as its arguments to see if the operation is allowed. * as its arguments to see if the operation is allowed.
* If the operation is not allowed, it will return * If the operation is not allowed, it will return
* the textual representation of the IP address. * the textual representation of the IP address.
...@@ -511,8 +511,8 @@ class InetAddress implements java.io.Serializable { ...@@ -511,8 +511,8 @@ class InetAddress implements java.io.Serializable {
* here without a security check. * here without a security check.
* *
* <p>If there is a security manager, this method first * <p>If there is a security manager, this method first
* calls its <code>checkConnect</code> method * calls its {@code checkConnect} method
* with the hostname and <code>-1</code> * with the hostname and {@code -1}
* as its arguments to see if the calling code is allowed to know * as its arguments to see if the calling code is allowed to know
* the hostname for this IP address, i.e., to connect to the host. * the hostname for this IP address, i.e., to connect to the host.
* If the operation is not allowed, it will return * If the operation is not allowed, it will return
...@@ -539,8 +539,8 @@ class InetAddress implements java.io.Serializable { ...@@ -539,8 +539,8 @@ class InetAddress implements java.io.Serializable {
* the FQDN depending on the underlying system configuration. * the FQDN depending on the underlying system configuration.
* *
* <p>If there is a security manager, this method first * <p>If there is a security manager, this method first
* calls its <code>checkConnect</code> method * calls its {@code checkConnect} method
* with the hostname and <code>-1</code> * with the hostname and {@code -1}
* as its arguments to see if the calling code is allowed to know * as its arguments to see if the calling code is allowed to know
* the hostname for this IP address, i.e., to connect to the host. * the hostname for this IP address, i.e., to connect to the host.
* If the operation is not allowed, it will return * If the operation is not allowed, it will return
...@@ -566,8 +566,8 @@ class InetAddress implements java.io.Serializable { ...@@ -566,8 +566,8 @@ class InetAddress implements java.io.Serializable {
* Returns the hostname for this address. * Returns the hostname for this address.
* *
* <p>If there is a security manager, this method first * <p>If there is a security manager, this method first
* calls its <code>checkConnect</code> method * calls its {@code checkConnect} method
* with the hostname and <code>-1</code> * with the hostname and {@code -1}
* as its arguments to see if the calling code is allowed to know * as its arguments to see if the calling code is allowed to know
* the hostname for this IP address, i.e., to connect to the host. * the hostname for this IP address, i.e., to connect to the host.
* If the operation is not allowed, it will return * If the operation is not allowed, it will return
...@@ -633,9 +633,9 @@ class InetAddress implements java.io.Serializable { ...@@ -633,9 +633,9 @@ class InetAddress implements java.io.Serializable {
} }
/** /**
* Returns the raw IP address of this <code>InetAddress</code> * Returns the raw IP address of this {@code InetAddress}
* object. The result is in network byte order: the highest order * object. The result is in network byte order: the highest order
* byte of the address is in <code>getAddress()[0]</code>. * byte of the address is in {@code getAddress()[0]}.
* *
* @return the raw IP address of this object. * @return the raw IP address of this object.
*/ */
...@@ -664,18 +664,18 @@ class InetAddress implements java.io.Serializable { ...@@ -664,18 +664,18 @@ class InetAddress implements java.io.Serializable {
/** /**
* Compares this object against the specified object. * Compares this object against the specified object.
* The result is <code>true</code> if and only if the argument is * The result is {@code true} if and only if the argument is
* not <code>null</code> and it represents the same IP address as * not {@code null} and it represents the same IP address as
* this object. * this object.
* <p> * <p>
* Two instances of <code>InetAddress</code> represent the same IP * Two instances of {@code InetAddress} represent the same IP
* address if the length of the byte arrays returned by * address if the length of the byte arrays returned by
* <code>getAddress</code> is the same for both, and each of the * {@code getAddress} is the same for both, and each of the
* array components is the same for the byte arrays. * array components is the same for the byte arrays.
* *
* @param obj the object to compare against. * @param obj the object to compare against.
* @return <code>true</code> if the objects are the same; * @return {@code true} if the objects are the same;
* <code>false</code> otherwise. * {@code false} otherwise.
* @see java.net.InetAddress#getAddress() * @see java.net.InetAddress#getAddress()
*/ */
public boolean equals(Object obj) { public boolean equals(Object obj) {
...@@ -683,7 +683,7 @@ class InetAddress implements java.io.Serializable { ...@@ -683,7 +683,7 @@ class InetAddress implements java.io.Serializable {
} }
/** /**
* Converts this IP address to a <code>String</code>. The * Converts this IP address to a {@code String}. The
* string returned is of the form: hostname / literal IP * string returned is of the form: hostname / literal IP
* address. * address.
* *
...@@ -974,7 +974,7 @@ class InetAddress implements java.io.Serializable { ...@@ -974,7 +974,7 @@ class InetAddress implements java.io.Serializable {
* No name service is checked for the validity of the address. * No name service is checked for the validity of the address.
* *
* <p> The host name can either be a machine name, such as * <p> The host name can either be a machine name, such as
* "<code>java.sun.com</code>", or a textual representation of its IP * "{@code java.sun.com}", or a textual representation of its IP
* address. * address.
* <p> No validity checking is done on the host name either. * <p> No validity checking is done on the host name either.
* *
...@@ -1019,26 +1019,26 @@ class InetAddress implements java.io.Serializable { ...@@ -1019,26 +1019,26 @@ class InetAddress implements java.io.Serializable {
* Determines the IP address of a host, given the host's name. * Determines the IP address of a host, given the host's name.
* *
* <p> The host name can either be a machine name, such as * <p> The host name can either be a machine name, such as
* "<code>java.sun.com</code>", or a textual representation of its * "{@code java.sun.com}", or a textual representation of its
* IP address. If a literal IP address is supplied, only the * IP address. If a literal IP address is supplied, only the
* validity of the address format is checked. * validity of the address format is checked.
* *
* <p> For <code>host</code> specified in literal IPv6 address, * <p> For {@code host} specified in literal IPv6 address,
* either the form defined in RFC 2732 or the literal IPv6 address * either the form defined in RFC 2732 or the literal IPv6 address
* format defined in RFC 2373 is accepted. IPv6 scoped addresses are also * format defined in RFC 2373 is accepted. IPv6 scoped addresses are also
* supported. See <a href="Inet6Address.html#scoped">here</a> for a description of IPv6 * supported. See <a href="Inet6Address.html#scoped">here</a> for a description of IPv6
* scoped addresses. * scoped addresses.
* *
* <p> If the host is <tt>null</tt> then an <tt>InetAddress</tt> * <p> If the host is {@code null} then an {@code InetAddress}
* representing an address of the loopback interface is returned. * representing an address of the loopback interface is returned.
* See <a href="http://www.ietf.org/rfc/rfc3330.txt">RFC&nbsp;3330</a> * See <a href="http://www.ietf.org/rfc/rfc3330.txt">RFC&nbsp;3330</a>
* section&nbsp;2 and <a href="http://www.ietf.org/rfc/rfc2373.txt">RFC&nbsp;2373</a> * section&nbsp;2 and <a href="http://www.ietf.org/rfc/rfc2373.txt">RFC&nbsp;2373</a>
* section&nbsp;2.5.3. </p> * section&nbsp;2.5.3. </p>
* *
* @param host the specified host, or <code>null</code>. * @param host the specified host, or {@code null}.
* @return an IP address for the given host name. * @return an IP address for the given host name.
* @exception UnknownHostException if no IP address for the * @exception UnknownHostException if no IP address for the
* <code>host</code> could be found, or if a scope_id was specified * {@code host} could be found, or if a scope_id was specified
* for a global IPv6 address. * for a global IPv6 address.
* @exception SecurityException if a security manager exists * @exception SecurityException if a security manager exists
* and its checkConnect method doesn't allow the operation * and its checkConnect method doesn't allow the operation
...@@ -1059,37 +1059,37 @@ class InetAddress implements java.io.Serializable { ...@@ -1059,37 +1059,37 @@ class InetAddress implements java.io.Serializable {
* based on the configured name service on the system. * based on the configured name service on the system.
* *
* <p> The host name can either be a machine name, such as * <p> The host name can either be a machine name, such as
* "<code>java.sun.com</code>", or a textual representation of its IP * "{@code java.sun.com}", or a textual representation of its IP
* address. If a literal IP address is supplied, only the * address. If a literal IP address is supplied, only the
* validity of the address format is checked. * validity of the address format is checked.
* *
* <p> For <code>host</code> specified in <i>literal IPv6 address</i>, * <p> For {@code host} specified in <i>literal IPv6 address</i>,
* either the form defined in RFC 2732 or the literal IPv6 address * either the form defined in RFC 2732 or the literal IPv6 address
* format defined in RFC 2373 is accepted. A literal IPv6 address may * format defined in RFC 2373 is accepted. A literal IPv6 address may
* also be qualified by appending a scoped zone identifier or scope_id. * also be qualified by appending a scoped zone identifier or scope_id.
* The syntax and usage of scope_ids is described * The syntax and usage of scope_ids is described
* <a href="Inet6Address.html#scoped">here</a>. * <a href="Inet6Address.html#scoped">here</a>.
* <p> If the host is <tt>null</tt> then an <tt>InetAddress</tt> * <p> If the host is {@code null} then an {@code InetAddress}
* representing an address of the loopback interface is returned. * representing an address of the loopback interface is returned.
* See <a href="http://www.ietf.org/rfc/rfc3330.txt">RFC&nbsp;3330</a> * See <a href="http://www.ietf.org/rfc/rfc3330.txt">RFC&nbsp;3330</a>
* section&nbsp;2 and <a href="http://www.ietf.org/rfc/rfc2373.txt">RFC&nbsp;2373</a> * section&nbsp;2 and <a href="http://www.ietf.org/rfc/rfc2373.txt">RFC&nbsp;2373</a>
* section&nbsp;2.5.3. </p> * section&nbsp;2.5.3. </p>
* *
* <p> If there is a security manager and <code>host</code> is not * <p> If there is a security manager and {@code host} is not
* null and <code>host.length() </code> is not equal to zero, the * null and {@code host.length() } is not equal to zero, the
* security manager's * security manager's
* <code>checkConnect</code> method is called * {@code checkConnect} method is called
* with the hostname and <code>-1</code> * with the hostname and {@code -1}
* as its arguments to see if the operation is allowed. * as its arguments to see if the operation is allowed.
* *
* @param host the name of the host, or <code>null</code>. * @param host the name of the host, or {@code null}.
* @return an array of all the IP addresses for a given host name. * @return an array of all the IP addresses for a given host name.
* *
* @exception UnknownHostException if no IP address for the * @exception UnknownHostException if no IP address for the
* <code>host</code> could be found, or if a scope_id was specified * {@code host} could be found, or if a scope_id was specified
* for a global IPv6 address. * for a global IPv6 address.
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* <code>checkConnect</code> method doesn't allow the operation. * {@code checkConnect} method doesn't allow the operation.
* *
* @see SecurityManager#checkConnect * @see SecurityManager#checkConnect
*/ */
...@@ -1389,9 +1389,9 @@ class InetAddress implements java.io.Serializable { ...@@ -1389,9 +1389,9 @@ class InetAddress implements java.io.Serializable {
} }
/** /**
* Returns an <code>InetAddress</code> object given the raw IP address . * Returns an {@code InetAddress} object given the raw IP address .
* The argument is in network byte order: the highest order * The argument is in network byte order: the highest order
* byte of the address is in <code>getAddress()[0]</code>. * byte of the address is in {@code getAddress()[0]}.
* *
* <p> This method doesn't block, i.e. no reverse name service lookup * <p> This method doesn't block, i.e. no reverse name service lookup
* is performed. * is performed.
...@@ -1417,14 +1417,14 @@ class InetAddress implements java.io.Serializable { ...@@ -1417,14 +1417,14 @@ class InetAddress implements java.io.Serializable {
/** /**
* Returns the address of the local host. This is achieved by retrieving * Returns the address of the local host. This is achieved by retrieving
* the name of the host from the system, then resolving that name into * the name of the host from the system, then resolving that name into
* an <code>InetAddress</code>. * an {@code InetAddress}.
* *
* <P>Note: The resolved address may be cached for a short period of time. * <P>Note: The resolved address may be cached for a short period of time.
* </P> * </P>
* *
* <p>If there is a security manager, its * <p>If there is a security manager, its
* <code>checkConnect</code> method is called * {@code checkConnect} method is called
* with the local host name and <code>-1</code> * with the local host name and {@code -1}
* as its arguments to see if the operation is allowed. * as its arguments to see if the operation is allowed.
* If the operation is not allowed, an InetAddress representing * If the operation is not allowed, an InetAddress representing
* the loopback address is returned. * the loopback address is returned.
......
/* /*
* 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -43,7 +43,7 @@ import java.io.ObjectStreamField; ...@@ -43,7 +43,7 @@ import java.io.ObjectStreamField;
* as returned values. * as returned values.
* <p> * <p>
* The <i>wildcard</i> is a special local IP address. It usually means "any" * The <i>wildcard</i> is a special local IP address. It usually means "any"
* and can only be used for <code>bind</code> operations. * and can only be used for {@code bind} operations.
* *
* @see java.net.Socket * @see java.net.Socket
* @see java.net.ServerSocket * @see java.net.ServerSocket
...@@ -155,8 +155,8 @@ public class InetSocketAddress ...@@ -155,8 +155,8 @@ public class InetSocketAddress
* and the port number a specified value. * and the port number a specified value.
* <p> * <p>
* A valid port value is between 0 and 65535. * A valid port value is between 0 and 65535.
* A port number of <code>zero</code> will let the system pick up an * A port number of {@code zero} will let the system pick up an
* ephemeral port in a <code>bind</code> operation. * ephemeral port in a {@code bind} operation.
* <p> * <p>
* @param port The port number * @param port The port number
* @throws IllegalArgumentException if the port parameter is outside the specified * @throws IllegalArgumentException if the port parameter is outside the specified
...@@ -171,10 +171,10 @@ public class InetSocketAddress ...@@ -171,10 +171,10 @@ public class InetSocketAddress
* Creates a socket address from an IP address and a port number. * Creates a socket address from an IP address and a port number.
* <p> * <p>
* A valid port value is between 0 and 65535. * A valid port value is between 0 and 65535.
* A port number of <code>zero</code> will let the system pick up an * A port number of {@code zero} will let the system pick up an
* ephemeral port in a <code>bind</code> operation. * ephemeral port in a {@code bind} operation.
* <P> * <P>
* A <code>null</code> address will assign the <i>wildcard</i> address. * A {@code null} address will assign the <i>wildcard</i> address.
* <p> * <p>
* @param addr The IP address * @param addr The IP address
* @param port The port number * @param port The port number
...@@ -195,13 +195,13 @@ public class InetSocketAddress ...@@ -195,13 +195,13 @@ public class InetSocketAddress
* An attempt will be made to resolve the hostname into an InetAddress. * An attempt will be made to resolve the hostname into an InetAddress.
* If that attempt fails, the address will be flagged as <I>unresolved</I>. * If that attempt fails, the address will be flagged as <I>unresolved</I>.
* <p> * <p>
* If there is a security manager, its <code>checkConnect</code> method * If there is a security manager, its {@code checkConnect} method
* is called with the host name as its argument to check the permissiom * is called with the host name as its argument to check the permissiom
* to resolve it. This could result in a SecurityException. * to resolve it. This could result in a SecurityException.
* <P> * <P>
* A valid port value is between 0 and 65535. * A valid port value is between 0 and 65535.
* A port number of <code>zero</code> will let the system pick up an * A port number of {@code zero} will let the system pick up an
* ephemeral port in a <code>bind</code> operation. * ephemeral port in a {@code bind} operation.
* <P> * <P>
* @param hostname the Host name * @param hostname the Host name
* @param port The port number * @param port The port number
...@@ -237,8 +237,8 @@ public class InetSocketAddress ...@@ -237,8 +237,8 @@ public class InetSocketAddress
* The address will be flagged as <I>unresolved</I>. * The address will be flagged as <I>unresolved</I>.
* <p> * <p>
* A valid port value is between 0 and 65535. * A valid port value is between 0 and 65535.
* A port number of <code>zero</code> will let the system pick up an * A port number of {@code zero} will let the system pick up an
* ephemeral port in a <code>bind</code> operation. * ephemeral port in a {@code bind} operation.
* <P> * <P>
* @param host the Host name * @param host the Host name
* @param port The port number * @param port The port number
...@@ -246,7 +246,7 @@ public class InetSocketAddress ...@@ -246,7 +246,7 @@ public class InetSocketAddress
* the range of valid port values, or if the hostname * the range of valid port values, or if the hostname
* parameter is <TT>null</TT>. * parameter is <TT>null</TT>.
* @see #isUnresolved() * @see #isUnresolved()
* @return a <code>InetSocketAddress</code> representing the unresolved * @return a {@code InetSocketAddress} representing the unresolved
* socket address * socket address
* @since 1.5 * @since 1.5
*/ */
...@@ -326,16 +326,16 @@ public class InetSocketAddress ...@@ -326,16 +326,16 @@ public class InetSocketAddress
/** /**
* *
* Gets the <code>InetAddress</code>. * Gets the {@code InetAddress}.
* *
* @return the InetAdress or <code>null</code> if it is unresolved. * @return the InetAdress or {@code null} if it is unresolved.
*/ */
public final InetAddress getAddress() { public final InetAddress getAddress() {
return holder.getAddress(); return holder.getAddress();
} }
/** /**
* Gets the <code>hostname</code>. * Gets the {@code hostname}.
* Note: This method may trigger a name service reverse lookup if the * Note: This method may trigger a name service reverse lookup if the
* address was created with a literal IP address. * address was created with a literal IP address.
* *
...@@ -360,8 +360,8 @@ public class InetSocketAddress ...@@ -360,8 +360,8 @@ public class InetSocketAddress
/** /**
* Checks whether the address has been resolved or not. * Checks whether the address has been resolved or not.
* *
* @return <code>true</code> if the hostname couldn't be resolved into * @return {@code true} if the hostname couldn't be resolved into
* an <code>InetAddress</code>. * an {@code InetAddress}.
*/ */
public final boolean isUnresolved() { public final boolean isUnresolved() {
return holder.isUnresolved(); return holder.isUnresolved();
...@@ -382,11 +382,11 @@ public class InetSocketAddress ...@@ -382,11 +382,11 @@ public class InetSocketAddress
/** /**
* Compares this object against the specified object. * Compares this object against the specified object.
* The result is <code>true</code> if and only if the argument is * The result is {@code true} if and only if the argument is
* not <code>null</code> and it represents the same address as * not {@code null} and it represents the same address as
* this object. * this object.
* <p> * <p>
* Two instances of <code>InetSocketAddress</code> represent the same * Two instances of {@code InetSocketAddress} represent the same
* address if both the InetAddresses (or hostnames if it is unresolved) and port * address if both the InetAddresses (or hostnames if it is unresolved) and port
* numbers are equal. * numbers are equal.
* If both addresses are unresolved, then the hostname and the port number * If both addresses are unresolved, then the hostname and the port number
...@@ -396,8 +396,8 @@ public class InetSocketAddress ...@@ -396,8 +396,8 @@ public class InetSocketAddress
* considered equal. * considered equal.
* *
* @param obj the object to compare against. * @param obj the object to compare against.
* @return <code>true</code> if the objects are the same; * @return {@code true} if the objects are the same;
* <code>false</code> otherwise. * {@code false} otherwise.
* @see java.net.InetAddress#equals(java.lang.Object) * @see java.net.InetAddress#equals(java.lang.Object)
*/ */
@Override @Override
......
/* /*
* Copyright (c) 2005, 2008, 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -47,23 +47,23 @@ public class InterfaceAddress { ...@@ -47,23 +47,23 @@ public class InterfaceAddress {
} }
/** /**
* Returns an <code>InetAddress</code> for this address. * Returns an {@code InetAddress} for this address.
* *
* @return the <code>InetAddress</code> for this address. * @return the {@code InetAddress} for this address.
*/ */
public InetAddress getAddress() { public InetAddress getAddress() {
return address; return address;
} }
/** /**
* Returns an <code>InetAddress</code> for the brodcast address * Returns an {@code InetAddress} for the brodcast address
* for this InterfaceAddress. * for this InterfaceAddress.
* <p> * <p>
* Only IPv4 networks have broadcast address therefore, in the case * Only IPv4 networks have broadcast address therefore, in the case
* of an IPv6 network, <code>null</code> will be returned. * of an IPv6 network, {@code null} will be returned.
* *
* @return the <code>InetAddress</code> representing the broadcast * @return the {@code InetAddress} representing the broadcast
* address or <code>null</code> if there is no broadcast address. * address or {@code null} if there is no broadcast address.
*/ */
public InetAddress getBroadcast() { public InetAddress getBroadcast() {
return broadcast; return broadcast;
...@@ -76,7 +76,7 @@ public class InterfaceAddress { ...@@ -76,7 +76,7 @@ public class InterfaceAddress {
* or 24 (255.255.255.0). <p> * or 24 (255.255.255.0). <p>
* Typical IPv6 values would be 128 (::1/128) or 10 (fe80::203:baff:fe27:1243/10) * Typical IPv6 values would be 128 (::1/128) or 10 (fe80::203:baff:fe27:1243/10)
* *
* @return a <code>short</code> representing the prefix length for the * @return a {@code short} representing the prefix length for the
* subnet of that address. * subnet of that address.
*/ */
public short getNetworkPrefixLength() { public short getNetworkPrefixLength() {
...@@ -85,17 +85,17 @@ public class InterfaceAddress { ...@@ -85,17 +85,17 @@ public class InterfaceAddress {
/** /**
* Compares this object against the specified object. * Compares this object against the specified object.
* The result is <code>true</code> if and only if the argument is * The result is {@code true} if and only if the argument is
* not <code>null</code> and it represents the same interface address as * not {@code null} and it represents the same interface address as
* this object. * this object.
* <p> * <p>
* Two instances of <code>InterfaceAddress</code> represent the same * Two instances of {@code InterfaceAddress} represent the same
* address if the InetAddress, the prefix length and the broadcast are * address if the InetAddress, the prefix length and the broadcast are
* the same for both. * the same for both.
* *
* @param obj the object to compare against. * @param obj the object to compare against.
* @return <code>true</code> if the objects are the same; * @return {@code true} if the objects are the same;
* <code>false</code> otherwise. * {@code false} otherwise.
* @see java.net.InterfaceAddress#hashCode() * @see java.net.InterfaceAddress#hashCode()
*/ */
public boolean equals(Object obj) { public boolean equals(Object obj) {
...@@ -122,7 +122,7 @@ public class InterfaceAddress { ...@@ -122,7 +122,7 @@ public class InterfaceAddress {
} }
/** /**
* Converts this Interface address to a <code>String</code>. The * Converts this Interface address to a {@code String}. The
* string returned is of the form: InetAddress / prefix length [ broadcast address ]. * string returned is of the form: InetAddress / prefix length [ broadcast address ].
* *
* @return a string representation of this Interface address. * @return a string representation of this Interface address.
......
/* /*
* Copyright (c) 1997, 2006, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -45,18 +45,14 @@ import sun.net.www.ParseUtil; ...@@ -45,18 +45,14 @@ import sun.net.www.ParseUtil;
* *
* <p>for example: * <p>for example:
* *
* <p><code> * <p>{@code jar:http://www.foo.com/bar/baz.jar!/COM/foo/Quux.class}
* jar:http://www.foo.com/bar/baz.jar!/COM/foo/Quux.class<br>
* </code>
* *
* <p>Jar URLs should be used to refer to a JAR file or entries in * <p>Jar URLs should be used to refer to a JAR file or entries in
* a JAR file. The example above is a JAR URL which refers to a JAR * a JAR file. The example above is a JAR URL which refers to a JAR
* entry. If the entry name is omitted, the URL refers to the whole * entry. If the entry name is omitted, the URL refers to the whole
* JAR file: * JAR file:
* *
* <code> * {@code jar:http://www.foo.com/bar/baz.jar!/}
* jar:http://www.foo.com/bar/baz.jar!/
* </code>
* *
* <p>Users should cast the generic URLConnection to a * <p>Users should cast the generic URLConnection to a
* JarURLConnection when they know that the URL they created is a JAR * JarURLConnection when they know that the URL they created is a JAR
...@@ -76,19 +72,19 @@ import sun.net.www.ParseUtil; ...@@ -76,19 +72,19 @@ import sun.net.www.ParseUtil;
* <dl> * <dl>
* *
* <dt>A Jar entry * <dt>A Jar entry
* <dd><code>jar:http://www.foo.com/bar/baz.jar!/COM/foo/Quux.class</code> * <dd>{@code jar:http://www.foo.com/bar/baz.jar!/COM/foo/Quux.class}
* *
* <dt>A Jar file * <dt>A Jar file
* <dd><code>jar:http://www.foo.com/bar/baz.jar!/</code> * <dd>{@code jar:http://www.foo.com/bar/baz.jar!/}
* *
* <dt>A Jar directory * <dt>A Jar directory
* <dd><code>jar:http://www.foo.com/bar/baz.jar!/COM/foo/</code> * <dd>{@code jar:http://www.foo.com/bar/baz.jar!/COM/foo/}
* *
* </dl> * </dl>
* *
* <p><code>!/</code> is refered to as the <em>separator</em>. * <p>{@code !/} is refered to as the <em>separator</em>.
* *
* <p>When constructing a JAR url via <code>new URL(context, spec)</code>, * <p>When constructing a JAR url via {@code new URL(context, spec)},
* the following rules apply: * the following rules apply:
* *
* <ul> * <ul>
...@@ -294,7 +290,7 @@ public abstract class JarURLConnection extends URLConnection { ...@@ -294,7 +290,7 @@ public abstract class JarURLConnection extends URLConnection {
* can only be called once * can only be called once
* the connection has been completely verified by reading * the connection has been completely verified by reading
* from the input stream until the end of the stream has been * from the input stream until the end of the stream has been
* reached. Otherwise, this method will return <code>null</code> * reached. Otherwise, this method will return {@code null}
* *
* @return the Certificate object for this connection if the URL * @return the Certificate object for this connection if the URL
* for it points to a JAR file entry, null otherwise. * for it points to a JAR file entry, null otherwise.
......
/* /*
* Copyright (c) 1995, 2008, 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -39,13 +39,13 @@ public class MalformedURLException extends IOException { ...@@ -39,13 +39,13 @@ public class MalformedURLException extends IOException {
private static final long serialVersionUID = -182787522200415866L; private static final long serialVersionUID = -182787522200415866L;
/** /**
* Constructs a <code>MalformedURLException</code> with no detail message. * Constructs a {@code MalformedURLException} with no detail message.
*/ */
public MalformedURLException() { public MalformedURLException() {
} }
/** /**
* Constructs a <code>MalformedURLException</code> with the * Constructs a {@code MalformedURLException} with the
* specified detail message. * specified detail message.
* *
* @param msg the detail message. * @param msg the detail message.
......
/* /*
* 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -92,7 +92,7 @@ class MulticastSocket extends DatagramSocket { ...@@ -92,7 +92,7 @@ class MulticastSocket extends DatagramSocket {
* Create a multicast socket. * Create a multicast socket.
* *
* <p>If there is a security manager, * <p>If there is a security manager,
* its <code>checkListen</code> method is first called * its {@code checkListen} method is first called
* with 0 as its argument to ensure the operation is allowed. * with 0 as its argument to ensure the operation is allowed.
* This could result in a SecurityException. * This could result in a SecurityException.
* <p> * <p>
...@@ -103,7 +103,7 @@ class MulticastSocket extends DatagramSocket { ...@@ -103,7 +103,7 @@ class MulticastSocket extends DatagramSocket {
* @exception IOException if an I/O exception occurs * @exception IOException if an I/O exception occurs
* while creating the MulticastSocket * while creating the MulticastSocket
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* <code>checkListen</code> method doesn't allow the operation. * {@code checkListen} method doesn't allow the operation.
* @see SecurityManager#checkListen * @see SecurityManager#checkListen
* @see java.net.DatagramSocket#setReuseAddress(boolean) * @see java.net.DatagramSocket#setReuseAddress(boolean)
*/ */
...@@ -115,8 +115,8 @@ class MulticastSocket extends DatagramSocket { ...@@ -115,8 +115,8 @@ class MulticastSocket extends DatagramSocket {
* Create a multicast socket and bind it to a specific port. * Create a multicast socket and bind it to a specific port.
* *
* <p>If there is a security manager, * <p>If there is a security manager,
* its <code>checkListen</code> method is first called * its {@code checkListen} method is first called
* with the <code>port</code> argument * with the {@code port} argument
* as its argument to ensure the operation is allowed. * as its argument to ensure the operation is allowed.
* This could result in a SecurityException. * This could result in a SecurityException.
* <p> * <p>
...@@ -128,7 +128,7 @@ class MulticastSocket extends DatagramSocket { ...@@ -128,7 +128,7 @@ class MulticastSocket extends DatagramSocket {
* @exception IOException if an I/O exception occurs * @exception IOException if an I/O exception occurs
* while creating the MulticastSocket * while creating the MulticastSocket
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* <code>checkListen</code> method doesn't allow the operation. * {@code checkListen} method doesn't allow the operation.
* @see SecurityManager#checkListen * @see SecurityManager#checkListen
* @see java.net.DatagramSocket#setReuseAddress(boolean) * @see java.net.DatagramSocket#setReuseAddress(boolean)
*/ */
...@@ -139,10 +139,10 @@ class MulticastSocket extends DatagramSocket { ...@@ -139,10 +139,10 @@ class MulticastSocket extends DatagramSocket {
/** /**
* Create a MulticastSocket bound to the specified socket address. * Create a MulticastSocket bound to the specified socket address.
* <p> * <p>
* Or, if the address is <code>null</code>, create an unbound socket. * Or, if the address is {@code null}, create an unbound socket.
* <p> * <p>
* <p>If there is a security manager, * <p>If there is a security manager,
* its <code>checkListen</code> method is first called * its {@code checkListen} method is first called
* with the SocketAddress port as its argument to ensure the operation is allowed. * with the SocketAddress port as its argument to ensure the operation is allowed.
* This could result in a SecurityException. * This could result in a SecurityException.
* <p> * <p>
...@@ -150,12 +150,12 @@ class MulticastSocket extends DatagramSocket { ...@@ -150,12 +150,12 @@ class MulticastSocket extends DatagramSocket {
* {@link DatagramSocket#setReuseAddress(boolean)} method is * {@link DatagramSocket#setReuseAddress(boolean)} method is
* called to enable the SO_REUSEADDR socket option. * called to enable the SO_REUSEADDR socket option.
* *
* @param bindaddr Socket address to bind to, or <code>null</code> for * @param bindaddr Socket address to bind to, or {@code null} for
* an unbound socket. * an unbound socket.
* @exception IOException if an I/O exception occurs * @exception IOException if an I/O exception occurs
* while creating the MulticastSocket * while creating the MulticastSocket
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* <code>checkListen</code> method doesn't allow the operation. * {@code checkListen} method doesn't allow the operation.
* @see SecurityManager#checkListen * @see SecurityManager#checkListen
* @see java.net.DatagramSocket#setReuseAddress(boolean) * @see java.net.DatagramSocket#setReuseAddress(boolean)
* *
...@@ -197,7 +197,7 @@ class MulticastSocket extends DatagramSocket { ...@@ -197,7 +197,7 @@ class MulticastSocket extends DatagramSocket {
/** /**
* Set the default time-to-live for multicast packets sent out * Set the default time-to-live for multicast packets sent out
* on this <code>MulticastSocket</code> in order to control the * on this {@code MulticastSocket} in order to control the
* scope of the multicasts. * scope of the multicasts.
* *
* <p>The ttl is an <b>unsigned</b> 8-bit quantity, and so <B>must</B> be * <p>The ttl is an <b>unsigned</b> 8-bit quantity, and so <B>must</B> be
...@@ -279,11 +279,11 @@ class MulticastSocket extends DatagramSocket { ...@@ -279,11 +279,11 @@ class MulticastSocket extends DatagramSocket {
/** /**
* Joins a multicast group. Its behavior may be affected by * Joins a multicast group. Its behavior may be affected by
* <code>setInterface</code> or <code>setNetworkInterface</code>. * {@code setInterface} or {@code setNetworkInterface}.
* *
* <p>If there is a security manager, this method first * <p>If there is a security manager, this method first
* calls its <code>checkMulticast</code> method * calls its {@code checkMulticast} method
* with the <code>mcastaddr</code> argument * with the {@code mcastaddr} argument
* as its argument. * as its argument.
* *
* @param mcastaddr is the multicast address to join * @param mcastaddr is the multicast address to join
...@@ -291,7 +291,7 @@ class MulticastSocket extends DatagramSocket { ...@@ -291,7 +291,7 @@ class MulticastSocket extends DatagramSocket {
* @exception IOException if there is an error joining * @exception IOException if there is an error joining
* or when the address is not a multicast address. * or when the address is not a multicast address.
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* <code>checkMulticast</code> method doesn't allow the join. * {@code checkMulticast} method doesn't allow the join.
* *
* @see SecurityManager#checkMulticast(InetAddress) * @see SecurityManager#checkMulticast(InetAddress)
*/ */
...@@ -325,18 +325,18 @@ class MulticastSocket extends DatagramSocket { ...@@ -325,18 +325,18 @@ class MulticastSocket extends DatagramSocket {
/** /**
* Leave a multicast group. Its behavior may be affected by * Leave a multicast group. Its behavior may be affected by
* <code>setInterface</code> or <code>setNetworkInterface</code>. * {@code setInterface} or {@code setNetworkInterface}.
* *
* <p>If there is a security manager, this method first * <p>If there is a security manager, this method first
* calls its <code>checkMulticast</code> method * calls its {@code checkMulticast} method
* with the <code>mcastaddr</code> argument * with the {@code mcastaddr} argument
* as its argument. * as its argument.
* *
* @param mcastaddr is the multicast address to leave * @param mcastaddr is the multicast address to leave
* @exception IOException if there is an error leaving * @exception IOException if there is an error leaving
* or when the address is not a multicast address. * or when the address is not a multicast address.
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* <code>checkMulticast</code> method doesn't allow the operation. * {@code checkMulticast} method doesn't allow the operation.
* *
* @see SecurityManager#checkMulticast(InetAddress) * @see SecurityManager#checkMulticast(InetAddress)
*/ */
...@@ -362,8 +362,8 @@ class MulticastSocket extends DatagramSocket { ...@@ -362,8 +362,8 @@ class MulticastSocket extends DatagramSocket {
* Joins the specified multicast group at the specified interface. * Joins the specified multicast group at the specified interface.
* *
* <p>If there is a security manager, this method first * <p>If there is a security manager, this method first
* calls its <code>checkMulticast</code> method * calls its {@code checkMulticast} method
* with the <code>mcastaddr</code> argument * with the {@code mcastaddr} argument
* as its argument. * as its argument.
* *
* @param mcastaddr is the multicast address to join * @param mcastaddr is the multicast address to join
...@@ -375,7 +375,7 @@ class MulticastSocket extends DatagramSocket { ...@@ -375,7 +375,7 @@ class MulticastSocket extends DatagramSocket {
* @exception IOException if there is an error joining * @exception IOException if there is an error joining
* or when the address is not a multicast address. * or when the address is not a multicast address.
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* <code>checkMulticast</code> method doesn't allow the join. * {@code checkMulticast} method doesn't allow the join.
* @throws IllegalArgumentException if mcastaddr is null or is a * @throws IllegalArgumentException if mcastaddr is null or is a
* SocketAddress subclass not supported by this socket * SocketAddress subclass not supported by this socket
* *
...@@ -410,8 +410,8 @@ class MulticastSocket extends DatagramSocket { ...@@ -410,8 +410,8 @@ class MulticastSocket extends DatagramSocket {
* Leave a multicast group on a specified local interface. * Leave a multicast group on a specified local interface.
* *
* <p>If there is a security manager, this method first * <p>If there is a security manager, this method first
* calls its <code>checkMulticast</code> method * calls its {@code checkMulticast} method
* with the <code>mcastaddr</code> argument * with the {@code mcastaddr} argument
* as its argument. * as its argument.
* *
* @param mcastaddr is the multicast address to leave * @param mcastaddr is the multicast address to leave
...@@ -422,7 +422,7 @@ class MulticastSocket extends DatagramSocket { ...@@ -422,7 +422,7 @@ class MulticastSocket extends DatagramSocket {
* @exception IOException if there is an error leaving * @exception IOException if there is an error leaving
* or when the address is not a multicast address. * or when the address is not a multicast address.
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* <code>checkMulticast</code> method doesn't allow the operation. * {@code checkMulticast} method doesn't allow the operation.
* @throws IllegalArgumentException if mcastaddr is null or is a * @throws IllegalArgumentException if mcastaddr is null or is a
* SocketAddress subclass not supported by this socket * SocketAddress subclass not supported by this socket
* *
...@@ -478,7 +478,7 @@ class MulticastSocket extends DatagramSocket { ...@@ -478,7 +478,7 @@ class MulticastSocket extends DatagramSocket {
* Retrieve the address of the network interface used for * Retrieve the address of the network interface used for
* multicast packets. * multicast packets.
* *
* @return An <code>InetAddress</code> representing * @return An {@code InetAddress} representing
* the address of the network interface used for * the address of the network interface used for
* multicast packets. * multicast packets.
* *
...@@ -562,7 +562,7 @@ class MulticastSocket extends DatagramSocket { ...@@ -562,7 +562,7 @@ class MulticastSocket extends DatagramSocket {
* *
* @exception SocketException if there is an error in * @exception SocketException if there is an error in
* the underlying protocol, such as a TCP error. * the underlying protocol, such as a TCP error.
* @return the multicast <code>NetworkInterface</code> currently set * @return the multicast {@code NetworkInterface} currently set
* @see #setNetworkInterface(NetworkInterface) * @see #setNetworkInterface(NetworkInterface)
* @since 1.4 * @since 1.4
*/ */
...@@ -587,7 +587,7 @@ class MulticastSocket extends DatagramSocket { ...@@ -587,7 +587,7 @@ class MulticastSocket extends DatagramSocket {
* <p>Because this option is a hint, applications that want to * <p>Because this option is a hint, applications that want to
* verify what loopback mode is set to should call * verify what loopback mode is set to should call
* {@link #getLoopbackMode()} * {@link #getLoopbackMode()}
* @param disable <code>true</code> to disable the LoopbackMode * @param disable {@code true} to disable the LoopbackMode
* @throws SocketException if an error occurs while setting the value * @throws SocketException if an error occurs while setting the value
* @since 1.4 * @since 1.4
* @see #getLoopbackMode * @see #getLoopbackMode
...@@ -615,18 +615,18 @@ class MulticastSocket extends DatagramSocket { ...@@ -615,18 +615,18 @@ class MulticastSocket extends DatagramSocket {
* otherwise it is preferable to set a TTL once on the socket, and * otherwise it is preferable to set a TTL once on the socket, and
* use that default TTL for all packets. This method does <B>not * use that default TTL for all packets. This method does <B>not
* </B> alter the default TTL for the socket. Its behavior may be * </B> alter the default TTL for the socket. Its behavior may be
* affected by <code>setInterface</code>. * affected by {@code setInterface}.
* *
* <p>If there is a security manager, this method first performs some * <p>If there is a security manager, this method first performs some
* security checks. First, if <code>p.getAddress().isMulticastAddress()</code> * security checks. First, if {@code p.getAddress().isMulticastAddress()}
* is true, this method calls the * is true, this method calls the
* security manager's <code>checkMulticast</code> method * security manager's {@code checkMulticast} method
* with <code>p.getAddress()</code> and <code>ttl</code> as its arguments. * with {@code p.getAddress()} and {@code ttl} as its arguments.
* If the evaluation of that expression is false, * If the evaluation of that expression is false,
* this method instead calls the security manager's * this method instead calls the security manager's
* <code>checkConnect</code> method with arguments * {@code checkConnect} method with arguments
* <code>p.getAddress().getHostAddress()</code> and * {@code p.getAddress().getHostAddress()} and
* <code>p.getPort()</code>. Each call to a security manager method * {@code p.getPort()}. Each call to a security manager method
* could result in a SecurityException if the operation is not allowed. * could result in a SecurityException if the operation is not allowed.
* *
* @param p is the packet to be sent. The packet should contain * @param p is the packet to be sent. The packet should contain
...@@ -639,7 +639,7 @@ class MulticastSocket extends DatagramSocket { ...@@ -639,7 +639,7 @@ class MulticastSocket extends DatagramSocket {
* @exception IOException is raised if an error occurs i.e * @exception IOException is raised if an error occurs i.e
* error while setting ttl. * error while setting ttl.
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* <code>checkMulticast</code> or <code>checkConnect</code> * {@code checkMulticast} or {@code checkConnect}
* method doesn't allow the send. * method doesn't allow the send.
* *
* @deprecated Use the following code or its equivalent instead: * @deprecated Use the following code or its equivalent instead:
......
/* /*
* Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -177,8 +177,8 @@ public final class NetPermission extends BasicPermission { ...@@ -177,8 +177,8 @@ public final class NetPermission extends BasicPermission {
* *
* @param name the name of the NetPermission. * @param name the name of the NetPermission.
* *
* @throws NullPointerException if <code>name</code> is <code>null</code>. * @throws NullPointerException if {@code name} is {@code null}.
* @throws IllegalArgumentException if <code>name</code> is empty. * @throws IllegalArgumentException if {@code name} is empty.
*/ */
public NetPermission(String name) public NetPermission(String name)
...@@ -194,8 +194,8 @@ public final class NetPermission extends BasicPermission { ...@@ -194,8 +194,8 @@ public final class NetPermission extends BasicPermission {
* @param name the name of the NetPermission. * @param name the name of the NetPermission.
* @param actions should be null. * @param actions should be null.
* *
* @throws NullPointerException if <code>name</code> is <code>null</code>. * @throws NullPointerException if {@code name} is {@code null}.
* @throws IllegalArgumentException if <code>name</code> is empty. * @throws IllegalArgumentException if {@code name} is empty.
*/ */
public NetPermission(String name, String actions) public NetPermission(String name, String actions)
......
/* /*
* 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -98,9 +98,9 @@ public final class NetworkInterface { ...@@ -98,9 +98,9 @@ public final class NetworkInterface {
* Convenience method to return an Enumeration with all or a * Convenience method to return an Enumeration with all or a
* subset of the InetAddresses bound to this network interface. * subset of the InetAddresses bound to this network interface.
* <p> * <p>
* If there is a security manager, its <code>checkConnect</code> * If there is a security manager, its {@code checkConnect}
* method is called for each InetAddress. Only InetAddresses where * method is called for each InetAddress. Only InetAddresses where
* the <code>checkConnect</code> doesn't throw a SecurityException * the {@code checkConnect} doesn't throw a SecurityException
* will be returned in the Enumeration. However, if the caller has the * will be returned in the Enumeration. However, if the caller has the
* {@link NetPermission}("getNetworkInformation") permission, then all * {@link NetPermission}("getNetworkInformation") permission, then all
* InetAddresses are returned. * InetAddresses are returned.
...@@ -154,15 +154,15 @@ public final class NetworkInterface { ...@@ -154,15 +154,15 @@ public final class NetworkInterface {
} }
/** /**
* Get a List of all or a subset of the <code>InterfaceAddresses</code> * Get a List of all or a subset of the {@code InterfaceAddresses}
* of this network interface. * of this network interface.
* <p> * <p>
* If there is a security manager, its <code>checkConnect</code> * If there is a security manager, its {@code checkConnect}
* method is called with the InetAddress for each InterfaceAddress. * method is called with the InetAddress for each InterfaceAddress.
* Only InterfaceAddresses where the <code>checkConnect</code> doesn't throw * Only InterfaceAddresses where the {@code checkConnect} doesn't throw
* a SecurityException will be returned in the List. * a SecurityException will be returned in the List.
* *
* @return a <code>List</code> object with all or a subset of the * @return a {@code List} object with all or a subset of the
* InterfaceAddresss of this network interface * InterfaceAddresss of this network interface
* @since 1.6 * @since 1.6
*/ */
...@@ -216,10 +216,10 @@ public final class NetworkInterface { ...@@ -216,10 +216,10 @@ public final class NetworkInterface {
/** /**
* Returns the parent NetworkInterface of this interface if this is * Returns the parent NetworkInterface of this interface if this is
* a subinterface, or <code>null</code> if it is a physical * a subinterface, or {@code null} if it is a physical
* (non virtual) interface or has no parent. * (non virtual) interface or has no parent.
* *
* @return The <code>NetworkInterface</code> this interface is attached to. * @return The {@code NetworkInterface} this interface is attached to.
* @since 1.6 * @since 1.6
*/ */
public NetworkInterface getParent() { public NetworkInterface getParent() {
...@@ -260,15 +260,15 @@ public final class NetworkInterface { ...@@ -260,15 +260,15 @@ public final class NetworkInterface {
* @param name * @param name
* The name of the network interface. * The name of the network interface.
* *
* @return A <tt>NetworkInterface</tt> with the specified name, * @return A {@code NetworkInterface} with the specified name,
* or <tt>null</tt> if there is no network interface * or {@code null} if there is no network interface
* with the specified name. * with the specified name.
* *
* @throws SocketException * @throws SocketException
* If an I/O error occurs. * If an I/O error occurs.
* *
* @throws NullPointerException * @throws NullPointerException
* If the specified name is <tt>null</tt>. * If the specified name is {@code null}.
*/ */
public static NetworkInterface getByName(String name) throws SocketException { public static NetworkInterface getByName(String name) throws SocketException {
if (name == null) if (name == null)
...@@ -303,17 +303,17 @@ public final class NetworkInterface { ...@@ -303,17 +303,17 @@ public final class NetworkInterface {
* returned. * returned.
* *
* @param addr * @param addr
* The <tt>InetAddress</tt> to search with. * The {@code InetAddress} to search with.
* *
* @return A <tt>NetworkInterface</tt> * @return A {@code NetworkInterface}
* or <tt>null</tt> if there is no network interface * or {@code null} if there is no network interface
* with the specified IP address. * with the specified IP address.
* *
* @throws SocketException * @throws SocketException
* If an I/O error occurs. * If an I/O error occurs.
* *
* @throws NullPointerException * @throws NullPointerException
* If the specified address is <tt>null</tt>. * If the specified address is {@code null}.
*/ */
public static NetworkInterface getByInetAddress(InetAddress addr) throws SocketException { public static NetworkInterface getByInetAddress(InetAddress addr) throws SocketException {
if (addr == null) { if (addr == null) {
...@@ -378,7 +378,7 @@ public final class NetworkInterface { ...@@ -378,7 +378,7 @@ public final class NetworkInterface {
/** /**
* Returns whether a network interface is up and running. * Returns whether a network interface is up and running.
* *
* @return <code>true</code> if the interface is up and running. * @return {@code true} if the interface is up and running.
* @exception SocketException if an I/O error occurs. * @exception SocketException if an I/O error occurs.
* @since 1.6 * @since 1.6
*/ */
...@@ -390,7 +390,7 @@ public final class NetworkInterface { ...@@ -390,7 +390,7 @@ public final class NetworkInterface {
/** /**
* Returns whether a network interface is a loopback interface. * Returns whether a network interface is a loopback interface.
* *
* @return <code>true</code> if the interface is a loopback interface. * @return {@code true} if the interface is a loopback interface.
* @exception SocketException if an I/O error occurs. * @exception SocketException if an I/O error occurs.
* @since 1.6 * @since 1.6
*/ */
...@@ -404,7 +404,7 @@ public final class NetworkInterface { ...@@ -404,7 +404,7 @@ public final class NetworkInterface {
* A typical point to point interface would be a PPP connection through * A typical point to point interface would be a PPP connection through
* a modem. * a modem.
* *
* @return <code>true</code> if the interface is a point to point * @return {@code true} if the interface is a point to point
* interface. * interface.
* @exception SocketException if an I/O error occurs. * @exception SocketException if an I/O error occurs.
* @since 1.6 * @since 1.6
...@@ -417,7 +417,7 @@ public final class NetworkInterface { ...@@ -417,7 +417,7 @@ public final class NetworkInterface {
/** /**
* Returns whether a network interface supports multicasting or not. * Returns whether a network interface supports multicasting or not.
* *
* @return <code>true</code> if the interface supports Multicasting. * @return {@code true} if the interface supports Multicasting.
* @exception SocketException if an I/O error occurs. * @exception SocketException if an I/O error occurs.
* @since 1.6 * @since 1.6
*/ */
...@@ -432,7 +432,7 @@ public final class NetworkInterface { ...@@ -432,7 +432,7 @@ public final class NetworkInterface {
* If a security manager is set, then the caller must have * If a security manager is set, then the caller must have
* the permission {@link NetPermission}("getNetworkInformation"). * the permission {@link NetPermission}("getNetworkInformation").
* *
* @return a byte array containing the address, or <code>null</code> if * @return a byte array containing the address, or {@code null} if
* the address doesn't exist, is not accessible or a security * the address doesn't exist, is not accessible or a security
* manager is set and the caller does not have the permission * manager is set and the caller does not have the permission
* NetPermission("getNetworkInformation") * NetPermission("getNetworkInformation")
...@@ -481,7 +481,7 @@ public final class NetworkInterface { ...@@ -481,7 +481,7 @@ public final class NetworkInterface {
* can be several virtual interfaces attached to a single physical * can be several virtual interfaces attached to a single physical
* interface. * interface.
* *
* @return <code>true</code> if this interface is a virtual interface. * @return {@code true} if this interface is a virtual interface.
* @since 1.6 * @since 1.6
*/ */
public boolean isVirtual() { public boolean isVirtual() {
...@@ -497,16 +497,16 @@ public final class NetworkInterface { ...@@ -497,16 +497,16 @@ public final class NetworkInterface {
/** /**
* Compares this object against the specified object. * Compares this object against the specified object.
* The result is <code>true</code> if and only if the argument is * The result is {@code true} if and only if the argument is
* not <code>null</code> and it represents the same NetworkInterface * not {@code null} and it represents the same NetworkInterface
* as this object. * as this object.
* <p> * <p>
* Two instances of <code>NetworkInterface</code> represent the same * Two instances of {@code NetworkInterface} represent the same
* NetworkInterface if both name and addrs are the same for both. * NetworkInterface if both name and addrs are the same for both.
* *
* @param obj the object to compare against. * @param obj the object to compare against.
* @return <code>true</code> if the objects are the same; * @return {@code true} if the objects are the same;
* <code>false</code> otherwise. * {@code false} otherwise.
* @see java.net.InetAddress#getAddress() * @see java.net.InetAddress#getAddress()
*/ */
public boolean equals(Object obj) { public boolean equals(Object obj) {
......
/* /*
* Copyright (c) 1997, 2001, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -43,11 +43,11 @@ public final class PasswordAuthentication { ...@@ -43,11 +43,11 @@ public final class PasswordAuthentication {
private char[] password; private char[] password;
/** /**
* Creates a new <code>PasswordAuthentication</code> object from the given * Creates a new {@code PasswordAuthentication} object from the given
* user name and password. * user name and password.
* *
* <p> Note that the given user password is cloned before it is stored in * <p> Note that the given user password is cloned before it is stored in
* the new <code>PasswordAuthentication</code> object. * the new {@code PasswordAuthentication} object.
* *
* @param userName the user name * @param userName the user name
* @param password the user's password * @param password the user's password
......
/* /*
* Copyright (c) 2001, 2008, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2001, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -36,7 +36,7 @@ public class PortUnreachableException extends SocketException { ...@@ -36,7 +36,7 @@ public class PortUnreachableException extends SocketException {
private static final long serialVersionUID = 8462541992376507323L; private static final long serialVersionUID = 8462541992376507323L;
/** /**
* Constructs a new <code>PortUnreachableException</code> with a * Constructs a new {@code PortUnreachableException} with a
* detail message. * detail message.
* @param msg the detail message * @param msg the detail message
*/ */
...@@ -45,7 +45,7 @@ public class PortUnreachableException extends SocketException { ...@@ -45,7 +45,7 @@ public class PortUnreachableException extends SocketException {
} }
/** /**
* Construct a new <code>PortUnreachableException</code> with no * Construct a new {@code PortUnreachableException} with no
* detailed message. * detailed message.
*/ */
public PortUnreachableException() {} public PortUnreachableException() {}
......
/* /*
* Copyright (c) 1995, 2008, 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -39,7 +39,7 @@ class ProtocolException extends IOException { ...@@ -39,7 +39,7 @@ class ProtocolException extends IOException {
private static final long serialVersionUID = -6098449442062388080L; private static final long serialVersionUID = -6098449442062388080L;
/** /**
* Constructs a new <code>ProtocolException</code> with the * Constructs a new {@code ProtocolException} with the
* specified detail message. * specified detail message.
* *
* @param host the detail message. * @param host the detail message.
...@@ -49,7 +49,7 @@ class ProtocolException extends IOException { ...@@ -49,7 +49,7 @@ class ProtocolException extends IOException {
} }
/** /**
* Constructs a new <code>ProtocolException</code> with no detail message. * Constructs a new {@code ProtocolException} with no detail message.
*/ */
public ProtocolException() { public ProtocolException() {
} }
......
/* /*
* Copyright (c) 2003, 2011, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -28,7 +28,7 @@ package java.net; ...@@ -28,7 +28,7 @@ package java.net;
/** /**
* This class represents a proxy setting, typically a type (http, socks) and * This class represents a proxy setting, typically a type (http, socks) and
* a socket address. * a socket address.
* A <code>Proxy</code> is an immutable object. * A {@code Proxy} is an immutable object.
* *
* @see java.net.ProxySelector * @see java.net.ProxySelector
* @author Yingxian Wang * @author Yingxian Wang
...@@ -61,17 +61,17 @@ public class Proxy { ...@@ -61,17 +61,17 @@ public class Proxy {
private SocketAddress sa; private SocketAddress sa;
/** /**
* A proxy setting that represents a <code>DIRECT</code> connection, * A proxy setting that represents a {@code DIRECT} connection,
* basically telling the protocol handler not to use any proxying. * basically telling the protocol handler not to use any proxying.
* Used, for instance, to create sockets bypassing any other global * Used, for instance, to create sockets bypassing any other global
* proxy settings (like SOCKS): * proxy settings (like SOCKS):
* <P> * <P>
* <code>Socket s = new Socket(Proxy.NO_PROXY);</code><br> * {@code Socket s = new Socket(Proxy.NO_PROXY);}<br>
* <P> * <P>
*/ */
public final static Proxy NO_PROXY = new Proxy(); public final static Proxy NO_PROXY = new Proxy();
// Creates the proxy that represents a <code>DIRECT</code> connection. // Creates the proxy that represents a {@code DIRECT} connection.
private Proxy() { private Proxy() {
type = Type.DIRECT; type = Type.DIRECT;
sa = null; sa = null;
...@@ -82,11 +82,11 @@ public class Proxy { ...@@ -82,11 +82,11 @@ public class Proxy {
* Certain combinations are illegal. For instance, for types Http, and * Certain combinations are illegal. For instance, for types Http, and
* Socks, a SocketAddress <b>must</b> be provided. * Socks, a SocketAddress <b>must</b> be provided.
* <P> * <P>
* Use the <code>Proxy.NO_PROXY</code> constant * Use the {@code Proxy.NO_PROXY} constant
* for representing a direct connection. * for representing a direct connection.
* *
* @param type the <code>Type</code> of the proxy * @param type the {@code Type} of the proxy
* @param sa the <code>SocketAddress</code> for that proxy * @param sa the {@code SocketAddress} for that proxy
* @throws IllegalArgumentException when the type and the address are * @throws IllegalArgumentException when the type and the address are
* incompatible * incompatible
*/ */
...@@ -108,9 +108,9 @@ public class Proxy { ...@@ -108,9 +108,9 @@ public class Proxy {
/** /**
* Returns the socket address of the proxy, or * Returns the socket address of the proxy, or
* <code>null</code> if its a direct connection. * {@code null} if its a direct connection.
* *
* @return a <code>SocketAddress</code> representing the socket end * @return a {@code SocketAddress} representing the socket end
* point of the proxy * point of the proxy
*/ */
public SocketAddress address() { public SocketAddress address() {
...@@ -121,7 +121,7 @@ public class Proxy { ...@@ -121,7 +121,7 @@ public class Proxy {
* Constructs a string representation of this Proxy. * Constructs a string representation of this Proxy.
* This String is constructed by calling toString() on its type * This String is constructed by calling toString() on its type
* and concatenating " @ " and the toString() result from its address * and concatenating " @ " and the toString() result from its address
* if its type is not <code>DIRECT</code>. * if its type is not {@code DIRECT}.
* *
* @return a string representation of this object. * @return a string representation of this object.
*/ */
...@@ -133,16 +133,16 @@ public class Proxy { ...@@ -133,16 +133,16 @@ public class Proxy {
/** /**
* Compares this object against the specified object. * Compares this object against the specified object.
* The result is <code>true</code> if and only if the argument is * The result is {@code true} if and only if the argument is
* not <code>null</code> and it represents the same proxy as * not {@code null} and it represents the same proxy as
* this object. * this object.
* <p> * <p>
* Two instances of <code>Proxy</code> represent the same * Two instances of {@code Proxy} represent the same
* address if both the SocketAddresses and type are equal. * address if both the SocketAddresses and type are equal.
* *
* @param obj the object to compare against. * @param obj the object to compare against.
* @return <code>true</code> if the objects are the same; * @return {@code true} if the objects are the same;
* <code>false</code> otherwise. * {@code false} otherwise.
* @see java.net.InetSocketAddress#equals(java.lang.Object) * @see java.net.InetSocketAddress#equals(java.lang.Object)
*/ */
public final boolean equals(Object obj) { public final boolean equals(Object obj) {
......
/* /*
* Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -83,9 +83,9 @@ public abstract class ProxySelector { ...@@ -83,9 +83,9 @@ public abstract class ProxySelector {
* *
* @throws SecurityException * @throws SecurityException
* If a security manager has been installed and it denies * If a security manager has been installed and it denies
* {@link NetPermission}<tt>("getProxySelector")</tt> * {@link NetPermission}{@code ("getProxySelector")}
* @see #setDefault(ProxySelector) * @see #setDefault(ProxySelector)
* @return the system-wide <code>ProxySelector</code> * @return the system-wide {@code ProxySelector}
* @since 1.5 * @since 1.5
*/ */
public static ProxySelector getDefault() { public static ProxySelector getDefault() {
...@@ -102,11 +102,11 @@ public abstract class ProxySelector { ...@@ -102,11 +102,11 @@ public abstract class ProxySelector {
* Note: non-standard protocol handlers may ignore this setting. * Note: non-standard protocol handlers may ignore this setting.
* *
* @param ps The HTTP proxy selector, or * @param ps The HTTP proxy selector, or
* <code>null</code> to unset the proxy selector. * {@code null} to unset the proxy selector.
* *
* @throws SecurityException * @throws SecurityException
* If a security manager has been installed and it denies * If a security manager has been installed and it denies
* {@link NetPermission}<tt>("setProxySelector")</tt> * {@link NetPermission}{@code ("setProxySelector")}
* *
* @see #getDefault() * @see #getDefault()
* @since 1.5 * @since 1.5
...@@ -127,7 +127,7 @@ public abstract class ProxySelector { ...@@ -127,7 +127,7 @@ public abstract class ProxySelector {
* <UL> * <UL>
* <LI>http URI for http connections</LI> * <LI>http URI for http connections</LI>
* <LI>https URI for https connections * <LI>https URI for https connections
* <LI><code>socket://host:port</code><br> * <LI>{@code socket://host:port}<br>
* for tcp client sockets connections</LI> * for tcp client sockets connections</LI>
* </UL> * </UL>
* *
......
/* /*
* Copyright (c) 2003, 2008, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -74,10 +74,10 @@ public abstract class ResponseCache { ...@@ -74,10 +74,10 @@ public abstract class ResponseCache {
* *
* @throws SecurityException * @throws SecurityException
* If a security manager has been installed and it denies * If a security manager has been installed and it denies
* {@link NetPermission}<tt>("getResponseCache")</tt> * {@link NetPermission}{@code ("getResponseCache")}
* *
* @see #setDefault(ResponseCache) * @see #setDefault(ResponseCache)
* @return the system-wide <code>ResponseCache</code> * @return the system-wide {@code ResponseCache}
* @since 1.5 * @since 1.5
*/ */
public synchronized static ResponseCache getDefault() { public synchronized static ResponseCache getDefault() {
...@@ -94,11 +94,11 @@ public abstract class ResponseCache { ...@@ -94,11 +94,11 @@ public abstract class ResponseCache {
* Note: non-standard procotol handlers may ignore this setting. * Note: non-standard procotol handlers may ignore this setting.
* *
* @param responseCache The response cache, or * @param responseCache The response cache, or
* <code>null</code> to unset the cache. * {@code null} to unset the cache.
* *
* @throws SecurityException * @throws SecurityException
* If a security manager has been installed and it denies * If a security manager has been installed and it denies
* {@link NetPermission}<tt>("setResponseCache")</tt> * {@link NetPermission}{@code ("setResponseCache")}
* *
* @see #getDefault() * @see #getDefault()
* @since 1.5 * @since 1.5
...@@ -118,14 +118,14 @@ public abstract class ResponseCache { ...@@ -118,14 +118,14 @@ public abstract class ResponseCache {
* to get the network resource. If a cached response is returned, * to get the network resource. If a cached response is returned,
* that resource is used instead. * that resource is used instead.
* *
* @param uri a <code>URI</code> used to reference the requested * @param uri a {@code URI} used to reference the requested
* network resource * network resource
* @param rqstMethod a <code>String</code> representing the request * @param rqstMethod a {@code String} representing the request
* method * method
* @param rqstHeaders - a Map from request header * @param rqstHeaders - a Map from request header
* field names to lists of field values representing * field names to lists of field values representing
* the current request headers * the current request headers
* @return a <code>CacheResponse</code> instance if available * @return a {@code CacheResponse} instance if available
* from cache, or null otherwise * from cache, or null otherwise
* @throws IOException if an I/O error occurs * @throws IOException if an I/O error occurs
* @throws IllegalArgumentException if any one of the arguments is null * @throws IllegalArgumentException if any one of the arguments is null
...@@ -148,11 +148,11 @@ public abstract class ResponseCache { ...@@ -148,11 +148,11 @@ public abstract class ResponseCache {
* use to write the resource into the cache. If the resource is * use to write the resource into the cache. If the resource is
* not to be cached, then put must return null. * not to be cached, then put must return null.
* *
* @param uri a <code>URI</code> used to reference the requested * @param uri a {@code URI} used to reference the requested
* network resource * network resource
* @param conn - a URLConnection instance that is used to fetch * @param conn - a URLConnection instance that is used to fetch
* the response to be cached * the response to be cached
* @return a <code>CacheRequest</code> for recording the * @return a {@code CacheRequest} for recording the
* response to be cached. Null return indicates that * response to be cached. Null return indicates that
* the caller does not intend to cache the response. * the caller does not intend to cache the response.
* @throws IOException if an I/O error occurs * @throws IOException if an I/O error occurs
......
/* /*
* Copyright (c) 1995, 2011, 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -37,7 +37,7 @@ import java.security.PrivilegedExceptionAction; ...@@ -37,7 +37,7 @@ import java.security.PrivilegedExceptionAction;
* based on that request, and then possibly returns a result to the requester. * based on that request, and then possibly returns a result to the requester.
* <p> * <p>
* The actual work of the server socket is performed by an instance * The actual work of the server socket is performed by an instance
* of the <code>SocketImpl</code> class. An application can * of the {@code SocketImpl} class. An application can
* change the socket factory that creates the socket * change the socket factory that creates the socket
* implementation to configure itself to create sockets * implementation to configure itself to create sockets
* appropriate to the local firewall. * appropriate to the local firewall.
...@@ -89,31 +89,31 @@ class ServerSocket implements java.io.Closeable { ...@@ -89,31 +89,31 @@ class ServerSocket implements java.io.Closeable {
/** /**
* Creates a server socket, bound to the specified port. A port number * Creates a server socket, bound to the specified port. A port number
* of <code>0</code> means that the port number is automatically * of {@code 0} means that the port number is automatically
* allocated, typically from an ephemeral port range. This port * allocated, typically from an ephemeral port range. This port
* number can then be retrieved by calling {@link #getLocalPort getLocalPort}. * number can then be retrieved by calling {@link #getLocalPort getLocalPort}.
* <p> * <p>
* The maximum queue length for incoming connection indications (a * The maximum queue length for incoming connection indications (a
* request to connect) is set to <code>50</code>. If a connection * request to connect) is set to {@code 50}. If a connection
* indication arrives when the queue is full, the connection is refused. * indication arrives when the queue is full, the connection is refused.
* <p> * <p>
* If the application has specified a server socket factory, that * If the application has specified a server socket factory, that
* factory's <code>createSocketImpl</code> method is called to create * factory's {@code createSocketImpl} method is called to create
* the actual socket implementation. Otherwise a "plain" socket is created. * the actual socket implementation. Otherwise a "plain" socket is created.
* <p> * <p>
* If there is a security manager, * If there is a security manager,
* its <code>checkListen</code> method is called * its {@code checkListen} method is called
* with the <code>port</code> argument * with the {@code port} argument
* as its argument to ensure the operation is allowed. * as its argument to ensure the operation is allowed.
* This could result in a SecurityException. * This could result in a SecurityException.
* *
* *
* @param port the port number, or <code>0</code> to use a port * @param port the port number, or {@code 0} to use a port
* number that is automatically allocated. * number that is automatically allocated.
* *
* @exception IOException if an I/O error occurs when opening the socket. * @exception IOException if an I/O error occurs when opening the socket.
* @exception SecurityException * @exception SecurityException
* if a security manager exists and its <code>checkListen</code> * if a security manager exists and its {@code checkListen}
* method doesn't allow the operation. * method doesn't allow the operation.
* @exception IllegalArgumentException if the port parameter is outside * @exception IllegalArgumentException if the port parameter is outside
* the specified range of valid port values, which is between * the specified range of valid port values, which is between
...@@ -131,42 +131,42 @@ class ServerSocket implements java.io.Closeable { ...@@ -131,42 +131,42 @@ class ServerSocket implements java.io.Closeable {
/** /**
* Creates a server socket and binds it to the specified local port * Creates a server socket and binds it to the specified local port
* number, with the specified backlog. * number, with the specified backlog.
* A port number of <code>0</code> means that the port number is * A port number of {@code 0} means that the port number is
* automatically allocated, typically from an ephemeral port range. * automatically allocated, typically from an ephemeral port range.
* This port number can then be retrieved by calling * This port number can then be retrieved by calling
* {@link #getLocalPort getLocalPort}. * {@link #getLocalPort getLocalPort}.
* <p> * <p>
* The maximum queue length for incoming connection indications (a * The maximum queue length for incoming connection indications (a
* request to connect) is set to the <code>backlog</code> parameter. If * request to connect) is set to the {@code backlog} parameter. If
* a connection indication arrives when the queue is full, the * a connection indication arrives when the queue is full, the
* connection is refused. * connection is refused.
* <p> * <p>
* If the application has specified a server socket factory, that * If the application has specified a server socket factory, that
* factory's <code>createSocketImpl</code> method is called to create * factory's {@code createSocketImpl} method is called to create
* the actual socket implementation. Otherwise a "plain" socket is created. * the actual socket implementation. Otherwise a "plain" socket is created.
* <p> * <p>
* If there is a security manager, * If there is a security manager,
* its <code>checkListen</code> method is called * its {@code checkListen} method is called
* with the <code>port</code> argument * with the {@code port} argument
* as its argument to ensure the operation is allowed. * as its argument to ensure the operation is allowed.
* This could result in a SecurityException. * This could result in a SecurityException.
* *
* The <code>backlog</code> argument is the requested maximum number of * The {@code backlog} argument is the requested maximum number of
* pending connections on the socket. Its exact semantics are implementation * pending connections on the socket. Its exact semantics are implementation
* specific. In particular, an implementation may impose a maximum length * specific. In particular, an implementation may impose a maximum length
* or may choose to ignore the parameter altogther. The value provided * or may choose to ignore the parameter altogther. The value provided
* should be greater than <code>0</code>. If it is less than or equal to * should be greater than {@code 0}. If it is less than or equal to
* <code>0</code>, then an implementation specific default will be used. * {@code 0}, then an implementation specific default will be used.
* <P> * <P>
* *
* @param port the port number, or <code>0</code> to use a port * @param port the port number, or {@code 0} to use a port
* number that is automatically allocated. * number that is automatically allocated.
* @param backlog requested maximum length of the queue of incoming * @param backlog requested maximum length of the queue of incoming
* connections. * connections.
* *
* @exception IOException if an I/O error occurs when opening the socket. * @exception IOException if an I/O error occurs when opening the socket.
* @exception SecurityException * @exception SecurityException
* if a security manager exists and its <code>checkListen</code> * if a security manager exists and its {@code checkListen}
* method doesn't allow the operation. * method doesn't allow the operation.
* @exception IllegalArgumentException if the port parameter is outside * @exception IllegalArgumentException if the port parameter is outside
* the specified range of valid port values, which is between * the specified range of valid port values, which is between
...@@ -189,32 +189,32 @@ class ServerSocket implements java.io.Closeable { ...@@ -189,32 +189,32 @@ class ServerSocket implements java.io.Closeable {
* If <i>bindAddr</i> is null, it will default accepting * If <i>bindAddr</i> is null, it will default accepting
* connections on any/all local addresses. * connections on any/all local addresses.
* The port must be between 0 and 65535, inclusive. * The port must be between 0 and 65535, inclusive.
* A port number of <code>0</code> means that the port number is * A port number of {@code 0} means that the port number is
* automatically allocated, typically from an ephemeral port range. * automatically allocated, typically from an ephemeral port range.
* This port number can then be retrieved by calling * This port number can then be retrieved by calling
* {@link #getLocalPort getLocalPort}. * {@link #getLocalPort getLocalPort}.
* *
* <P>If there is a security manager, this method * <P>If there is a security manager, this method
* calls its <code>checkListen</code> method * calls its {@code checkListen} method
* with the <code>port</code> argument * with the {@code port} argument
* as its argument to ensure the operation is allowed. * as its argument to ensure the operation is allowed.
* This could result in a SecurityException. * This could result in a SecurityException.
* *
* The <code>backlog</code> argument is the requested maximum number of * The {@code backlog} argument is the requested maximum number of
* pending connections on the socket. Its exact semantics are implementation * pending connections on the socket. Its exact semantics are implementation
* specific. In particular, an implementation may impose a maximum length * specific. In particular, an implementation may impose a maximum length
* or may choose to ignore the parameter altogther. The value provided * or may choose to ignore the parameter altogther. The value provided
* should be greater than <code>0</code>. If it is less than or equal to * should be greater than {@code 0}. If it is less than or equal to
* <code>0</code>, then an implementation specific default will be used. * {@code 0}, then an implementation specific default will be used.
* <P> * <P>
* @param port the port number, or <code>0</code> to use a port * @param port the port number, or {@code 0} to use a port
* number that is automatically allocated. * number that is automatically allocated.
* @param backlog requested maximum length of the queue of incoming * @param backlog requested maximum length of the queue of incoming
* connections. * connections.
* @param bindAddr the local InetAddress the server will bind to * @param bindAddr the local InetAddress the server will bind to
* *
* @throws SecurityException if a security manager exists and * @throws SecurityException if a security manager exists and
* its <code>checkListen</code> method doesn't allow the operation. * its {@code checkListen} method doesn't allow the operation.
* *
* @throws IOException if an I/O error occurs when opening the socket. * @throws IOException if an I/O error occurs when opening the socket.
* @exception IllegalArgumentException if the port parameter is outside * @exception IllegalArgumentException if the port parameter is outside
...@@ -245,10 +245,10 @@ class ServerSocket implements java.io.Closeable { ...@@ -245,10 +245,10 @@ class ServerSocket implements java.io.Closeable {
} }
/** /**
* Get the <code>SocketImpl</code> attached to this socket, creating * Get the {@code SocketImpl} attached to this socket, creating
* it if necessary. * it if necessary.
* *
* @return the <code>SocketImpl</code> attached to that ServerSocket. * @return the {@code SocketImpl} attached to that ServerSocket.
* @throws SocketException if creation fails. * @throws SocketException if creation fails.
* @since 1.4 * @since 1.4
*/ */
...@@ -310,17 +310,17 @@ class ServerSocket implements java.io.Closeable { ...@@ -310,17 +310,17 @@ class ServerSocket implements java.io.Closeable {
/** /**
* *
* Binds the <code>ServerSocket</code> to a specific address * Binds the {@code ServerSocket} to a specific address
* (IP address and port number). * (IP address and port number).
* <p> * <p>
* If the address is <code>null</code>, then the system will pick up * If the address is {@code null}, then the system will pick up
* an ephemeral port and a valid local address to bind the socket. * an ephemeral port and a valid local address to bind the socket.
* <p> * <p>
* @param endpoint The IP address and port number to bind to. * @param endpoint The IP address and port number to bind to.
* @throws IOException if the bind operation fails, or if the socket * @throws IOException if the bind operation fails, or if the socket
* is already bound. * is already bound.
* @throws SecurityException if a <code>SecurityManager</code> is present and * @throws SecurityException if a {@code SecurityManager} is present and
* its <code>checkListen</code> method doesn't allow the operation. * its {@code checkListen} method doesn't allow the operation.
* @throws IllegalArgumentException if endpoint is a * @throws IllegalArgumentException if endpoint is a
* SocketAddress subclass not supported by this socket * SocketAddress subclass not supported by this socket
* @since 1.4 * @since 1.4
...@@ -331,25 +331,25 @@ class ServerSocket implements java.io.Closeable { ...@@ -331,25 +331,25 @@ class ServerSocket implements java.io.Closeable {
/** /**
* *
* Binds the <code>ServerSocket</code> to a specific address * Binds the {@code ServerSocket} to a specific address
* (IP address and port number). * (IP address and port number).
* <p> * <p>
* If the address is <code>null</code>, then the system will pick up * If the address is {@code null}, then the system will pick up
* an ephemeral port and a valid local address to bind the socket. * an ephemeral port and a valid local address to bind the socket.
* <P> * <P>
* The <code>backlog</code> argument is the requested maximum number of * The {@code backlog} argument is the requested maximum number of
* pending connections on the socket. Its exact semantics are implementation * pending connections on the socket. Its exact semantics are implementation
* specific. In particular, an implementation may impose a maximum length * specific. In particular, an implementation may impose a maximum length
* or may choose to ignore the parameter altogther. The value provided * or may choose to ignore the parameter altogther. The value provided
* should be greater than <code>0</code>. If it is less than or equal to * should be greater than {@code 0}. If it is less than or equal to
* <code>0</code>, then an implementation specific default will be used. * {@code 0}, then an implementation specific default will be used.
* @param endpoint The IP address and port number to bind to. * @param endpoint The IP address and port number to bind to.
* @param backlog requested maximum length of the queue of * @param backlog requested maximum length of the queue of
* incoming connections. * incoming connections.
* @throws IOException if the bind operation fails, or if the socket * @throws IOException if the bind operation fails, or if the socket
* is already bound. * is already bound.
* @throws SecurityException if a <code>SecurityManager</code> is present and * @throws SecurityException if a {@code SecurityManager} is present and
* its <code>checkListen</code> method doesn't allow the operation. * its {@code checkListen} method doesn't allow the operation.
* @throws IllegalArgumentException if endpoint is a * @throws IllegalArgumentException if endpoint is a
* SocketAddress subclass not supported by this socket * SocketAddress subclass not supported by this socket
* @since 1.4 * @since 1.4
...@@ -480,18 +480,18 @@ class ServerSocket implements java.io.Closeable { ...@@ -480,18 +480,18 @@ class ServerSocket implements java.io.Closeable {
* Listens for a connection to be made to this socket and accepts * Listens for a connection to be made to this socket and accepts
* it. The method blocks until a connection is made. * it. The method blocks until a connection is made.
* *
* <p>A new Socket <code>s</code> is created and, if there * <p>A new Socket {@code s} is created and, if there
* is a security manager, * is a security manager,
* the security manager's <code>checkAccept</code> method is called * the security manager's {@code checkAccept} method is called
* with <code>s.getInetAddress().getHostAddress()</code> and * with {@code s.getInetAddress().getHostAddress()} and
* <code>s.getPort()</code> * {@code s.getPort()}
* as its arguments to ensure the operation is allowed. * as its arguments to ensure the operation is allowed.
* This could result in a SecurityException. * This could result in a SecurityException.
* *
* @exception IOException if an I/O error occurs when waiting for a * @exception IOException if an I/O error occurs when waiting for a
* connection. * connection.
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* <code>checkAccept</code> method doesn't allow the operation. * {@code checkAccept} method doesn't allow the operation.
* @exception SocketTimeoutException if a timeout was previously set with setSoTimeout and * @exception SocketTimeoutException if a timeout was previously set with setSoTimeout and
* the timeout has been reached. * the timeout has been reached.
* @exception java.nio.channels.IllegalBlockingModeException * @exception java.nio.channels.IllegalBlockingModeException
...@@ -597,7 +597,7 @@ class ServerSocket implements java.io.Closeable { ...@@ -597,7 +597,7 @@ class ServerSocket implements java.io.Closeable {
* method. * method.
* *
* @return the server-socket channel associated with this socket, * @return the server-socket channel associated with this socket,
* or <tt>null</tt> if this socket was not created * or {@code null} if this socket was not created
* for a channel * for a channel
* *
* @since 1.4 * @since 1.4
...@@ -678,18 +678,18 @@ class ServerSocket implements java.io.Closeable { ...@@ -678,18 +678,18 @@ class ServerSocket implements java.io.Closeable {
* <p> * <p>
* When a TCP connection is closed the connection may remain * When a TCP connection is closed the connection may remain
* in a timeout state for a period of time after the connection * in a timeout state for a period of time after the connection
* is closed (typically known as the <tt>TIME_WAIT</tt> state * is closed (typically known as the {@code TIME_WAIT} state
* or <tt>2MSL</tt> wait state). * or {@code 2MSL} wait state).
* For applications using a well known socket address or port * For applications using a well known socket address or port
* it may not be possible to bind a socket to the required * it may not be possible to bind a socket to the required
* <tt>SocketAddress</tt> if there is a connection in the * {@code SocketAddress} if there is a connection in the
* timeout state involving the socket address or port. * timeout state involving the socket address or port.
* <p> * <p>
* Enabling {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} prior to * Enabling {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} prior to
* binding the socket using {@link #bind(SocketAddress)} allows the socket * binding the socket using {@link #bind(SocketAddress)} allows the socket
* to be bound even though a previous connection is in a timeout state. * to be bound even though a previous connection is in a timeout state.
* <p> * <p>
* When a <tt>ServerSocket</tt> is created the initial setting * When a {@code ServerSocket} is created the initial setting
* of {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} is not defined. * of {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} is not defined.
* Applications can use {@link #getReuseAddress()} to determine the initial * Applications can use {@link #getReuseAddress()} to determine the initial
* setting of {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR}. * setting of {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR}.
...@@ -717,7 +717,7 @@ class ServerSocket implements java.io.Closeable { ...@@ -717,7 +717,7 @@ class ServerSocket implements java.io.Closeable {
/** /**
* Tests if {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} is enabled. * Tests if {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} is enabled.
* *
* @return a <code>boolean</code> indicating whether or not * @return a {@code boolean} indicating whether or not
* {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} is enabled. * {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} is enabled.
* @exception SocketException if there is an error * @exception SocketException if there is an error
* in the underlying protocol, such as a TCP error. * in the underlying protocol, such as a TCP error.
...@@ -732,7 +732,7 @@ class ServerSocket implements java.io.Closeable { ...@@ -732,7 +732,7 @@ class ServerSocket implements java.io.Closeable {
/** /**
* Returns the implementation address and implementation port of * Returns the implementation address and implementation port of
* this socket as a <code>String</code>. * this socket as a {@code String}.
* <p> * <p>
* If there is a security manager set, its {@code checkConnect} method is * If there is a security manager set, its {@code checkConnect} method is
* called with the local address and {@code -1} as its arguments to see * called with the local address and {@code -1} as its arguments to see
...@@ -773,14 +773,14 @@ class ServerSocket implements java.io.Closeable { ...@@ -773,14 +773,14 @@ class ServerSocket implements java.io.Closeable {
* application. The factory can be specified only once. * application. The factory can be specified only once.
* <p> * <p>
* When an application creates a new server socket, the socket * When an application creates a new server socket, the socket
* implementation factory's <code>createSocketImpl</code> method is * implementation factory's {@code createSocketImpl} method is
* called to create the actual socket implementation. * called to create the actual socket implementation.
* <p> * <p>
* Passing <code>null</code> to the method is a no-op unless the factory * Passing {@code null} to the method is a no-op unless the factory
* was already set. * was already set.
* <p> * <p>
* If there is a security manager, this method first calls * If there is a security manager, this method first calls
* the security manager's <code>checkSetFactory</code> method * the security manager's {@code checkSetFactory} method
* to ensure the operation is allowed. * to ensure the operation is allowed.
* This could result in a SecurityException. * This could result in a SecurityException.
* *
...@@ -789,7 +789,7 @@ class ServerSocket implements java.io.Closeable { ...@@ -789,7 +789,7 @@ class ServerSocket implements java.io.Closeable {
* socket factory. * socket factory.
* @exception SocketException if the factory has already been defined. * @exception SocketException if the factory has already been defined.
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* <code>checkSetFactory</code> method doesn't allow the operation. * {@code checkSetFactory} method doesn't allow the operation.
* @see java.net.SocketImplFactory#createSocketImpl() * @see java.net.SocketImplFactory#createSocketImpl()
* @see SecurityManager#checkSetFactory * @see SecurityManager#checkSetFactory
*/ */
...@@ -807,7 +807,7 @@ class ServerSocket implements java.io.Closeable { ...@@ -807,7 +807,7 @@ class ServerSocket implements java.io.Closeable {
/** /**
* Sets a default proposed value for the * Sets a default proposed value for the
* {@link SocketOptions#SO_RCVBUF SO_RCVBUF} option for sockets * {@link SocketOptions#SO_RCVBUF SO_RCVBUF} option for sockets
* accepted from this <tt>ServerSocket</tt>. The value actually set * accepted from this {@code ServerSocket}. The value actually set
* in the accepted socket must be determined by calling * in the accepted socket must be determined by calling
* {@link Socket#getReceiveBufferSize()} after the socket * {@link Socket#getReceiveBufferSize()} after the socket
* is returned by {@link #accept()}. * is returned by {@link #accept()}.
...@@ -851,13 +851,13 @@ class ServerSocket implements java.io.Closeable { ...@@ -851,13 +851,13 @@ class ServerSocket implements java.io.Closeable {
/** /**
* Gets the value of the {@link SocketOptions#SO_RCVBUF SO_RCVBUF} option * Gets the value of the {@link SocketOptions#SO_RCVBUF SO_RCVBUF} option
* for this <tt>ServerSocket</tt>, that is the proposed buffer size that * for this {@code ServerSocket}, that is the proposed buffer size that
* will be used for Sockets accepted from this <tt>ServerSocket</tt>. * will be used for Sockets accepted from this {@code ServerSocket}.
* *
* <p>Note, the value actually set in the accepted socket is determined by * <p>Note, the value actually set in the accepted socket is determined by
* calling {@link Socket#getReceiveBufferSize()}. * calling {@link Socket#getReceiveBufferSize()}.
* @return the value of the {@link SocketOptions#SO_RCVBUF SO_RCVBUF} * @return the value of the {@link SocketOptions#SO_RCVBUF SO_RCVBUF}
* option for this <tt>Socket</tt>. * option for this {@code Socket}.
* @exception SocketException if there is an error * @exception SocketException if there is an error
* in the underlying protocol, such as a TCP error. * in the underlying protocol, such as a TCP error.
* @see #setReceiveBufferSize(int) * @see #setReceiveBufferSize(int)
...@@ -891,24 +891,24 @@ class ServerSocket implements java.io.Closeable { ...@@ -891,24 +891,24 @@ class ServerSocket implements java.io.Closeable {
* compared, with larger values indicating stronger preferences. If the * compared, with larger values indicating stronger preferences. If the
* application prefers short connection time over both low latency and high * application prefers short connection time over both low latency and high
* bandwidth, for example, then it could invoke this method with the values * bandwidth, for example, then it could invoke this method with the values
* <tt>(1, 0, 0)</tt>. If the application prefers high bandwidth above low * {@code (1, 0, 0)}. If the application prefers high bandwidth above low
* latency, and low latency above short connection time, then it could * latency, and low latency above short connection time, then it could
* invoke this method with the values <tt>(0, 1, 2)</tt>. * invoke this method with the values {@code (0, 1, 2)}.
* *
* <p> Invoking this method after this socket has been bound * <p> Invoking this method after this socket has been bound
* will have no effect. This implies that in order to use this capability * will have no effect. This implies that in order to use this capability
* requires the socket to be created with the no-argument constructor. * requires the socket to be created with the no-argument constructor.
* *
* @param connectionTime * @param connectionTime
* An <tt>int</tt> expressing the relative importance of a short * An {@code int} expressing the relative importance of a short
* connection time * connection time
* *
* @param latency * @param latency
* An <tt>int</tt> expressing the relative importance of low * An {@code int} expressing the relative importance of low
* latency * latency
* *
* @param bandwidth * @param bandwidth
* An <tt>int</tt> expressing the relative importance of high * An {@code int} expressing the relative importance of high
* bandwidth * bandwidth
* *
* @since 1.5 * @since 1.5
......
/* /*
* Copyright (c) 1995, 2008, 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -38,7 +38,7 @@ class SocketException extends IOException { ...@@ -38,7 +38,7 @@ class SocketException extends IOException {
private static final long serialVersionUID = -5935874303556886934L; private static final long serialVersionUID = -5935874303556886934L;
/** /**
* Constructs a new <code>SocketException</code> with the * Constructs a new {@code SocketException} with the
* specified detail message. * specified detail message.
* *
* @param msg the detail message. * @param msg the detail message.
...@@ -48,7 +48,7 @@ class SocketException extends IOException { ...@@ -48,7 +48,7 @@ class SocketException extends IOException {
} }
/** /**
* Constructs a new <code>SocketException</code> with no detail message. * Constructs a new {@code SocketException} with no detail message.
*/ */
public SocketException() { public SocketException() {
} }
......
/* /*
* Copyright (c) 1995, 2011, 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -31,7 +31,7 @@ import java.io.OutputStream; ...@@ -31,7 +31,7 @@ import java.io.OutputStream;
import java.io.FileDescriptor; import java.io.FileDescriptor;
/** /**
* The abstract class <code>SocketImpl</code> is a common superclass * The abstract class {@code SocketImpl} is a common superclass
* of all classes that actually implement sockets. It is used to * of all classes that actually implement sockets. It is used to
* create both client and server sockets. * create both client and server sockets.
* <p> * <p>
...@@ -71,7 +71,7 @@ public abstract class SocketImpl implements SocketOptions { ...@@ -71,7 +71,7 @@ public abstract class SocketImpl implements SocketOptions {
/** /**
* Creates either a stream or a datagram socket. * Creates either a stream or a datagram socket.
* *
* @param stream if <code>true</code>, create a stream socket; * @param stream if {@code true}, create a stream socket;
* otherwise, create a datagram socket. * otherwise, create a datagram socket.
* @exception IOException if an I/O error occurs while creating the * @exception IOException if an I/O error occurs while creating the
* socket. * socket.
...@@ -122,7 +122,7 @@ public abstract class SocketImpl implements SocketOptions { ...@@ -122,7 +122,7 @@ public abstract class SocketImpl implements SocketOptions {
/** /**
* Sets the maximum queue length for incoming connection indications * Sets the maximum queue length for incoming connection indications
* (a request to connect) to the <code>count</code> argument. If a * (a request to connect) to the {@code count} argument. If a
* connection indication arrives when the queue is full, the * connection indication arrives when the queue is full, the
* connection is refused. * connection is refused.
* *
...@@ -217,9 +217,9 @@ public abstract class SocketImpl implements SocketOptions { ...@@ -217,9 +217,9 @@ public abstract class SocketImpl implements SocketOptions {
} }
/** /**
* Returns the value of this socket's <code>fd</code> field. * Returns the value of this socket's {@code fd} field.
* *
* @return the value of this socket's <code>fd</code> field. * @return the value of this socket's {@code fd} field.
* @see java.net.SocketImpl#fd * @see java.net.SocketImpl#fd
*/ */
protected FileDescriptor getFileDescriptor() { protected FileDescriptor getFileDescriptor() {
...@@ -227,9 +227,9 @@ public abstract class SocketImpl implements SocketOptions { ...@@ -227,9 +227,9 @@ public abstract class SocketImpl implements SocketOptions {
} }
/** /**
* Returns the value of this socket's <code>address</code> field. * Returns the value of this socket's {@code address} field.
* *
* @return the value of this socket's <code>address</code> field. * @return the value of this socket's {@code address} field.
* @see java.net.SocketImpl#address * @see java.net.SocketImpl#address
*/ */
protected InetAddress getInetAddress() { protected InetAddress getInetAddress() {
...@@ -237,9 +237,9 @@ public abstract class SocketImpl implements SocketOptions { ...@@ -237,9 +237,9 @@ public abstract class SocketImpl implements SocketOptions {
} }
/** /**
* Returns the value of this socket's <code>port</code> field. * Returns the value of this socket's {@code port} field.
* *
* @return the value of this socket's <code>port</code> field. * @return the value of this socket's {@code port} field.
* @see java.net.SocketImpl#port * @see java.net.SocketImpl#port
*/ */
protected int getPort() { protected int getPort() {
...@@ -270,9 +270,9 @@ public abstract class SocketImpl implements SocketOptions { ...@@ -270,9 +270,9 @@ public abstract class SocketImpl implements SocketOptions {
protected abstract void sendUrgentData (int data) throws IOException; protected abstract void sendUrgentData (int data) throws IOException;
/** /**
* Returns the value of this socket's <code>localport</code> field. * Returns the value of this socket's {@code localport} field.
* *
* @return the value of this socket's <code>localport</code> field. * @return the value of this socket's {@code localport} field.
* @see java.net.SocketImpl#localport * @see java.net.SocketImpl#localport
*/ */
protected int getLocalPort() { protected int getLocalPort() {
...@@ -296,7 +296,7 @@ public abstract class SocketImpl implements SocketOptions { ...@@ -296,7 +296,7 @@ public abstract class SocketImpl implements SocketOptions {
} }
/** /**
* Returns the address and port of this socket as a <code>String</code>. * Returns the address and port of this socket as a {@code String}.
* *
* @return a string representation of this socket. * @return a string representation of this socket.
*/ */
...@@ -328,23 +328,23 @@ public abstract class SocketImpl implements SocketOptions { ...@@ -328,23 +328,23 @@ public abstract class SocketImpl implements SocketOptions {
* values represent a lower priority than positive values. If the * values represent a lower priority than positive values. If the
* application prefers short connection time over both low latency and high * application prefers short connection time over both low latency and high
* bandwidth, for example, then it could invoke this method with the values * bandwidth, for example, then it could invoke this method with the values
* <tt>(1, 0, 0)</tt>. If the application prefers high bandwidth above low * {@code (1, 0, 0)}. If the application prefers high bandwidth above low
* latency, and low latency above short connection time, then it could * latency, and low latency above short connection time, then it could
* invoke this method with the values <tt>(0, 1, 2)</tt>. * invoke this method with the values {@code (0, 1, 2)}.
* *
* By default, this method does nothing, unless it is overridden in a * By default, this method does nothing, unless it is overridden in a
* a sub-class. * a sub-class.
* *
* @param connectionTime * @param connectionTime
* An <tt>int</tt> expressing the relative importance of a short * An {@code int} expressing the relative importance of a short
* connection time * connection time
* *
* @param latency * @param latency
* An <tt>int</tt> expressing the relative importance of low * An {@code int} expressing the relative importance of low
* latency * latency
* *
* @param bandwidth * @param bandwidth
* An <tt>int</tt> expressing the relative importance of high * An {@code int} expressing the relative importance of high
* bandwidth * bandwidth
* *
* @since 1.5 * @since 1.5
......
/* /*
* Copyright (c) 1995, 1999, 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -27,8 +27,8 @@ package java.net; ...@@ -27,8 +27,8 @@ package java.net;
/** /**
* This interface defines a factory for socket implementations. It * This interface defines a factory for socket implementations. It
* is used by the classes <code>Socket</code> and * is used by the classes {@code Socket} and
* <code>ServerSocket</code> to create actual socket * {@code ServerSocket} to create actual socket
* implementations. * implementations.
* *
* @author Arthur van Hoff * @author Arthur van Hoff
...@@ -39,9 +39,9 @@ package java.net; ...@@ -39,9 +39,9 @@ package java.net;
public public
interface SocketImplFactory { interface SocketImplFactory {
/** /**
* Creates a new <code>SocketImpl</code> instance. * Creates a new {@code SocketImpl} instance.
* *
* @return a new instance of <code>SocketImpl</code>. * @return a new instance of {@code SocketImpl}.
* @see java.net.SocketImpl * @see java.net.SocketImpl
*/ */
SocketImpl createSocketImpl(); SocketImpl createSocketImpl();
......
/* /*
* 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -67,8 +67,8 @@ class SocketInputStream extends FileInputStream ...@@ -67,8 +67,8 @@ class SocketInputStream extends FileInputStream
* Returns the unique {@link java.nio.channels.FileChannel FileChannel} * Returns the unique {@link java.nio.channels.FileChannel FileChannel}
* object associated with this file input stream.</p> * object associated with this file input stream.</p>
* *
* The <code>getChannel</code> method of <code>SocketInputStream</code> * The {@code getChannel} method of {@code SocketInputStream}
* returns <code>null</code> since it is a socket based stream.</p> * returns {@code null} since it is a socket based stream.</p>
* *
* @return the file channel associated with this file input stream * @return the file channel associated with this file input stream
* *
......
/* /*
* Copyright (c) 1996, 2006, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -115,7 +115,7 @@ public interface SocketOptions { ...@@ -115,7 +115,7 @@ public interface SocketOptions {
* } * }
* </PRE> * </PRE>
* *
* @param optID an <code>int</code> identifying the option to fetch * @param optID an {@code int} identifying the option to fetch
* @return the value of the option * @return the value of the option
* @throws SocketException if the socket is closed * @throws SocketException if the socket is closed
* @throws SocketException if <I>optID</I> is unknown along the * @throws SocketException if <I>optID</I> is unknown along the
......
/* /*
* Copyright (c) 1995, 2007, 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -64,8 +64,8 @@ class SocketOutputStream extends FileOutputStream ...@@ -64,8 +64,8 @@ class SocketOutputStream extends FileOutputStream
* Returns the unique {@link java.nio.channels.FileChannel FileChannel} * Returns the unique {@link java.nio.channels.FileChannel FileChannel}
* object associated with this file output stream. </p> * object associated with this file output stream. </p>
* *
* The <code>getChannel</code> method of <code>SocketOutputStream</code> * The {@code getChannel} method of {@code SocketOutputStream}
* returns <code>null</code> since it is a socket based stream.</p> * returns {@code null} since it is a socket based stream.</p>
* *
* @return the file channel associated with this file output stream * @return the file channel associated with this file output stream
* *
......
/* /*
* Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -110,7 +110,7 @@ import sun.security.util.Debug; ...@@ -110,7 +110,7 @@ import sun.security.util.Debug;
* </pre> * </pre>
* *
* is granted to some code, it allows that code to connect to port 7777 on * is granted to some code, it allows that code to connect to port 7777 on
* <code>puffin.eng.sun.com</code>, and to accept connections on that port. * {@code puffin.eng.sun.com}, and to accept connections on that port.
* *
* <p>Similarly, if the following permission: * <p>Similarly, if the following permission:
* *
...@@ -788,7 +788,7 @@ public final class SocketPermission extends Permission ...@@ -788,7 +788,7 @@ public final class SocketPermission extends Permission
* port range is ignored when p only contains the action, 'resolve'.<p> * port range is ignored when p only contains the action, 'resolve'.<p>
* </ul> * </ul>
* *
* Then <code>implies</code> checks each of the following, in order, * Then {@code implies} checks each of the following, in order,
* and for each returns true if the stated condition is true:<p> * and for each returns true if the stated condition is true:<p>
* <ul> * <ul>
* <li> If this object was initialized with a single IP address and one of <i>p</i>'s * <li> If this object was initialized with a single IP address and one of <i>p</i>'s
...@@ -802,7 +802,7 @@ public final class SocketPermission extends Permission ...@@ -802,7 +802,7 @@ public final class SocketPermission extends Permission
* <li>If this canonical name equals <i>p</i>'s canonical name.<p> * <li>If this canonical name equals <i>p</i>'s canonical name.<p>
* </ul> * </ul>
* *
* If none of the above are true, <code>implies</code> returns false. * If none of the above are true, {@code implies} returns false.
* @param p the permission to check against. * @param p the permission to check against.
* *
* @return true if the specified permission is implied by this object, * @return true if the specified permission is implied by this object,
...@@ -1131,7 +1131,7 @@ public final class SocketPermission extends Permission ...@@ -1131,7 +1131,7 @@ public final class SocketPermission extends Permission
* <p> * <p>
* SocketPermission objects must be stored in a manner that allows them * SocketPermission objects must be stored in a manner that allows them
* to be inserted into the collection in any order, but that also enables the * to be inserted into the collection in any order, but that also enables the
* PermissionCollection <code>implies</code> * PermissionCollection {@code implies}
* method to be implemented in an efficient (and consistent) manner. * method to be implemented in an efficient (and consistent) manner.
* *
* @return a new PermissionCollection object suitable for storing SocketPermissions. * @return a new PermissionCollection object suitable for storing SocketPermissions.
......
/* /*
* 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -315,7 +315,7 @@ class SocksSocketImpl extends PlainSocketImpl implements SocksConsts { ...@@ -315,7 +315,7 @@ class SocksSocketImpl extends PlainSocketImpl implements SocksConsts {
* grants the connections, then the connect is successful and all * grants the connections, then the connect is successful and all
* further traffic will go to the "real" endpoint. * further traffic will go to the "real" endpoint.
* *
* @param endpoint the <code>SocketAddress</code> to connect to. * @param endpoint the {@code SocketAddress} to connect to.
* @param timeout the timeout value in milliseconds * @param timeout the timeout value in milliseconds
* @throws IOException if the connection can't be established. * @throws IOException if the connection can't be established.
* @throws SecurityException if there is a security manager and it * @throws SecurityException if there is a security manager and it
...@@ -1032,9 +1032,9 @@ class SocksSocketImpl extends PlainSocketImpl implements SocksConsts { ...@@ -1032,9 +1032,9 @@ class SocksSocketImpl extends PlainSocketImpl implements SocksConsts {
/** /**
* Returns the value of this socket's <code>address</code> field. * Returns the value of this socket's {@code address} field.
* *
* @return the value of this socket's <code>address</code> field. * @return the value of this socket's {@code address} field.
* @see java.net.SocketImpl#address * @see java.net.SocketImpl#address
*/ */
@Override @Override
...@@ -1046,9 +1046,9 @@ class SocksSocketImpl extends PlainSocketImpl implements SocksConsts { ...@@ -1046,9 +1046,9 @@ class SocksSocketImpl extends PlainSocketImpl implements SocksConsts {
} }
/** /**
* Returns the value of this socket's <code>port</code> field. * Returns the value of this socket's {@code port} field.
* *
* @return the value of this socket's <code>port</code> field. * @return the value of this socket's {@code port} field.
* @see java.net.SocketImpl#port * @see java.net.SocketImpl#port
*/ */
@Override @Override
......
此差异已折叠。
/* /*
* Copyright (c) 2000, 2008, 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -50,13 +50,13 @@ public class URISyntaxException ...@@ -50,13 +50,13 @@ public class URISyntaxException
* @param input The input string * @param input The input string
* @param reason A string explaining why the input could not be parsed * @param reason A string explaining why the input could not be parsed
* @param index The index at which the parse error occurred, * @param index The index at which the parse error occurred,
* or <tt>-1</tt> if the index is not known * or {@code -1} if the index is not known
* *
* @throws NullPointerException * @throws NullPointerException
* If either the input or reason strings are <tt>null</tt> * If either the input or reason strings are {@code null}
* *
* @throws IllegalArgumentException * @throws IllegalArgumentException
* If the error index is less than <tt>-1</tt> * If the error index is less than {@code -1}
*/ */
public URISyntaxException(String input, String reason, int index) { public URISyntaxException(String input, String reason, int index) {
super(reason); super(reason);
...@@ -70,13 +70,13 @@ public class URISyntaxException ...@@ -70,13 +70,13 @@ public class URISyntaxException
/** /**
* Constructs an instance from the given input string and reason. The * Constructs an instance from the given input string and reason. The
* resulting object will have an error index of <tt>-1</tt>. * resulting object will have an error index of {@code -1}.
* *
* @param input The input string * @param input The input string
* @param reason A string explaining why the input could not be parsed * @param reason A string explaining why the input could not be parsed
* *
* @throws NullPointerException * @throws NullPointerException
* If either the input or reason strings are <tt>null</tt> * If either the input or reason strings are {@code null}
*/ */
public URISyntaxException(String input, String reason) { public URISyntaxException(String input, String reason) {
this(input, reason, -1); this(input, reason, -1);
...@@ -102,7 +102,7 @@ public class URISyntaxException ...@@ -102,7 +102,7 @@ public class URISyntaxException
/** /**
* Returns an index into the input string of the position at which the * Returns an index into the input string of the position at which the
* parse error occurred, or <tt>-1</tt> if this position is not known. * parse error occurred, or {@code -1} if this position is not known.
* *
* @return The error index * @return The error index
*/ */
...@@ -113,8 +113,8 @@ public class URISyntaxException ...@@ -113,8 +113,8 @@ public class URISyntaxException
/** /**
* Returns a string describing the parse error. The resulting string * Returns a string describing the parse error. The resulting string
* consists of the reason string followed by a colon character * consists of the reason string followed by a colon character
* (<tt>':'</tt>), a space, and the input string. If the error index is * ({@code ':'}), a space, and the input string. If the error index is
* defined then the string <tt>" at index "</tt> followed by the index, in * defined then the string {@code " at index "} followed by the index, in
* decimal, is inserted after the reason string and before the colon * decimal, is inserted after the reason string and before the colon
* character. * character.
* *
......
此差异已折叠。
/* /*
* Copyright (c) 1997, 2011, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -117,7 +117,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable { ...@@ -117,7 +117,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
/** /**
* Constructs a new URLClassLoader for the specified URLs using the * Constructs a new URLClassLoader for the specified URLs using the
* default delegation parent <code>ClassLoader</code>. The URLs will * default delegation parent {@code ClassLoader}. The URLs will
* be searched in the order specified for classes and resources after * be searched in the order specified for classes and resources after
* first searching in the parent class loader. Any URL that ends with * first searching in the parent class loader. Any URL that ends with
* a '/' is assumed to refer to a directory. Otherwise, the URL is * a '/' is assumed to refer to a directory. Otherwise, the URL is
...@@ -125,13 +125,13 @@ public class URLClassLoader extends SecureClassLoader implements Closeable { ...@@ -125,13 +125,13 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
* as needed. * as needed.
* *
* <p>If there is a security manager, this method first * <p>If there is a security manager, this method first
* calls the security manager's <code>checkCreateClassLoader</code> method * calls the security manager's {@code checkCreateClassLoader} method
* to ensure creation of a class loader is allowed. * to ensure creation of a class loader is allowed.
* *
* @param urls the URLs from which to load classes and resources * @param urls the URLs from which to load classes and resources
* *
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* <code>checkCreateClassLoader</code> method doesn't allow * {@code checkCreateClassLoader} method doesn't allow
* creation of a class loader. * creation of a class loader.
* @see SecurityManager#checkCreateClassLoader * @see SecurityManager#checkCreateClassLoader
*/ */
...@@ -165,7 +165,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable { ...@@ -165,7 +165,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
* obtain protocol handlers when creating new jar URLs. * obtain protocol handlers when creating new jar URLs.
* *
* <p>If there is a security manager, this method first * <p>If there is a security manager, this method first
* calls the security manager's <code>checkCreateClassLoader</code> method * calls the security manager's {@code checkCreateClassLoader} method
* to ensure creation of a class loader is allowed. * to ensure creation of a class loader is allowed.
* *
* @param urls the URLs from which to load classes and resources * @param urls the URLs from which to load classes and resources
...@@ -173,7 +173,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable { ...@@ -173,7 +173,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
* @param factory the URLStreamHandlerFactory to use when creating URLs * @param factory the URLStreamHandlerFactory to use when creating URLs
* *
* @exception SecurityException if a security manager exists and its * @exception SecurityException if a security manager exists and its
* <code>checkCreateClassLoader</code> method doesn't allow * {@code checkCreateClassLoader} method doesn't allow
* creation of a class loader. * creation of a class loader.
* @see SecurityManager#checkCreateClassLoader * @see SecurityManager#checkCreateClassLoader
*/ */
...@@ -217,7 +217,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable { ...@@ -217,7 +217,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
* @param name * @param name
* The resource name * The resource name
* *
* @return An input stream for reading the resource, or <tt>null</tt> * @return An input stream for reading the resource, or {@code null}
* if the resource could not be found * if the resource could not be found
* *
* @since 1.7 * @since 1.7
...@@ -273,7 +273,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable { ...@@ -273,7 +273,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
* as suppressed exceptions of the first one caught, which is then re-thrown. * as suppressed exceptions of the first one caught, which is then re-thrown.
* *
* @throws SecurityException if a security manager is set, and it denies * @throws SecurityException if a security manager is set, and it denies
* {@link RuntimePermission}<tt>("closeClassLoader")</tt> * {@link RuntimePermission}{@code ("closeClassLoader")}
* *
* @since 1.7 * @since 1.7
*/ */
...@@ -316,7 +316,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable { ...@@ -316,7 +316,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
* Appends the specified URL to the list of URLs to search for * Appends the specified URL to the list of URLs to search for
* classes and resources. * classes and resources.
* <p> * <p>
* If the URL specified is <code>null</code> or is already in the * If the URL specified is {@code null} or is already in the
* list of URLs, or if this loader is closed, then invoking this * list of URLs, or if this loader is closed, then invoking this
* method has no effect. * method has no effect.
* *
...@@ -537,7 +537,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable { ...@@ -537,7 +537,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
* Finds the resource with the specified name on the URL search path. * Finds the resource with the specified name on the URL search path.
* *
* @param name the name of the resource * @param name the name of the resource
* @return a <code>URL</code> for the resource, or <code>null</code> * @return a {@code URL} for the resource, or {@code null}
* if the resource could not be found, or if the loader is closed. * if the resource could not be found, or if the loader is closed.
*/ */
public URL findResource(final String name) { public URL findResource(final String name) {
...@@ -560,7 +560,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable { ...@@ -560,7 +560,7 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
* *
* @param name the resource name * @param name the resource name
* @exception IOException if an I/O exception occurs * @exception IOException if an I/O exception occurs
* @return an <code>Enumeration</code> of <code>URL</code>s * @return an {@code Enumeration} of {@code URL}s
* If the loader is closed, the Enumeration will be empty. * If the loader is closed, the Enumeration will be empty.
*/ */
public Enumeration<URL> findResources(final String name) public Enumeration<URL> findResources(final String name)
...@@ -699,9 +699,9 @@ public class URLClassLoader extends SecureClassLoader implements Closeable { ...@@ -699,9 +699,9 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
/** /**
* Creates a new instance of URLClassLoader for the specified * Creates a new instance of URLClassLoader for the specified
* URLs and parent class loader. If a security manager is * URLs and parent class loader. If a security manager is
* installed, the <code>loadClass</code> method of the URLClassLoader * installed, the {@code loadClass} method of the URLClassLoader
* returned by this method will invoke the * returned by this method will invoke the
* <code>SecurityManager.checkPackageAccess</code> method before * {@code SecurityManager.checkPackageAccess} method before
* loading the class. * loading the class.
* *
* @param urls the URLs to search for classes and resources * @param urls the URLs to search for classes and resources
...@@ -725,9 +725,9 @@ public class URLClassLoader extends SecureClassLoader implements Closeable { ...@@ -725,9 +725,9 @@ public class URLClassLoader extends SecureClassLoader implements Closeable {
/** /**
* Creates a new instance of URLClassLoader for the specified * Creates a new instance of URLClassLoader for the specified
* URLs and default parent class loader. If a security manager is * URLs and default parent class loader. If a security manager is
* installed, the <code>loadClass</code> method of the URLClassLoader * installed, the {@code loadClass} method of the URLClassLoader
* returned by this method will invoke the * returned by this method will invoke the
* <code>SecurityManager.checkPackageAccess</code> before * {@code SecurityManager.checkPackageAccess} before
* loading the class. * loading the class.
* *
* @param urls the URLs to search for classes and resources * @param urls the URLs to search for classes and resources
......
/* /*
* Copyright (c) 1995, 1999, 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -26,11 +26,11 @@ ...@@ -26,11 +26,11 @@
package java.net; package java.net;
/** /**
* This interface defines a factory for <code>URL</code> stream * This interface defines a factory for {@code URL} stream
* protocol handlers. * protocol handlers.
* <p> * <p>
* It is used by the <code>URL</code> class to create a * It is used by the {@code URL} class to create a
* <code>URLStreamHandler</code> for a specific protocol. * {@code URLStreamHandler} for a specific protocol.
* *
* @author Arthur van Hoff * @author Arthur van Hoff
* @see java.net.URL * @see java.net.URL
...@@ -39,12 +39,12 @@ package java.net; ...@@ -39,12 +39,12 @@ package java.net;
*/ */
public interface URLStreamHandlerFactory { public interface URLStreamHandlerFactory {
/** /**
* Creates a new <code>URLStreamHandler</code> instance with the specified * Creates a new {@code URLStreamHandler} instance with the specified
* protocol. * protocol.
* *
* @param protocol the protocol ("<code>ftp</code>", * @param protocol the protocol ("{@code ftp}",
* "<code>http</code>", "<code>nntp</code>", etc.). * "{@code http}", "{@code nntp}", etc.).
* @return a <code>URLStreamHandler</code> for the specific protocol. * @return a {@code URLStreamHandler} for the specific protocol.
* @see java.net.URLStreamHandler * @see java.net.URLStreamHandler
*/ */
URLStreamHandler createURLStreamHandler(String protocol); URLStreamHandler createURLStreamHandler(String protocol);
......
/* /*
* Copyright (c) 1995, 2008, 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. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -38,7 +38,7 @@ class UnknownHostException extends IOException { ...@@ -38,7 +38,7 @@ class UnknownHostException extends IOException {
private static final long serialVersionUID = -4639126076052875403L; private static final long serialVersionUID = -4639126076052875403L;
/** /**
* Constructs a new <code>UnknownHostException</code> with the * Constructs a new {@code UnknownHostException} with the
* specified detail message. * specified detail message.
* *
* @param host the detail message. * @param host the detail message.
...@@ -48,7 +48,7 @@ class UnknownHostException extends IOException { ...@@ -48,7 +48,7 @@ class UnknownHostException extends IOException {
} }
/** /**
* Constructs a new <code>UnknownHostException</code> with no detail * Constructs a new {@code UnknownHostException} with no detail
* message. * message.
*/ */
public UnknownHostException() { public UnknownHostException() {
......
此差异已折叠。
此差异已折叠。
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册