diff options
author | Michael Koch <konqueror@gmx.de> | 2004-04-20 13:05:10 +0000 |
---|---|---|
committer | Michael Koch <mkoch@gcc.gnu.org> | 2004-04-20 13:05:10 +0000 |
commit | f6d49f66ec0e0a59285d304720cc3bfa18f28141 (patch) | |
tree | 61e0c356000f77339048c144863ae045f79523eb /libjava/java/net/SocketImpl.java | |
parent | cf6f7d55897e0c6b1badbcfc241e512a4bb154b8 (diff) | |
download | gcc-f6d49f66ec0e0a59285d304720cc3bfa18f28141.zip gcc-f6d49f66ec0e0a59285d304720cc3bfa18f28141.tar.gz gcc-f6d49f66ec0e0a59285d304720cc3bfa18f28141.tar.bz2 |
Authenticator.java, [...]: Fixed javadocs, coding style and argument names all over.
2004-04-20 Michael Koch <konqueror@gmx.de>
* java/net/Authenticator.java,
java/net/BindException.java,
java/net/ConnectException.java,
java/net/ContentHandler.java,
java/net/ContentHandlerFactory.java,
java/net/DatagramPacket.java,
java/net/DatagramSocket.java,
java/net/DatagramSocketImpl.java,
java/net/DatagramSocketImplFactory.java,
java/net/FileNameMap.java,
java/net/HttpURLConnection.java,
java/net/Inet4Address.java,
java/net/Inet6Address.java,
java/net/InetAddress.java,
java/net/InetSocketAddress.java,
java/net/JarURLConnection.java,
java/net/MalformedURLException.java,
java/net/MulticastSocket.java,
java/net/NetPermission.java,
java/net/NetworkInterface.java,
java/net/NoRouteToHostException.java,
java/net/PasswordAuthentication.java,
java/net/PortUnreachableException.java,
java/net/ProtocolException.java,
java/net/ServerSocket.java,
java/net/Socket.java,
java/net/SocketAddress.java,
java/net/SocketException.java,
java/net/SocketImpl.java,
java/net/SocketImplFactory.java,
java/net/SocketOptions.java,
java/net/SocketPermission.java,
java/net/SocketTimeoutException.java,
java/net/URI.java,
java/net/URISyntaxException.java,
java/net/URL.java,
java/net/URLClassLoader.java,
java/net/URLConnection.java,
java/net/URLDecoder.java,
java/net/URLEncoder.java,
java/net/URLStreamHandler.java,
java/net/URLStreamHandlerFactory.java,
java/net/UnknownHostException.java,
java/net/UnknownServiceException.java:
Fixed javadocs, coding style and argument names all over.
From-SVN: r80900
Diffstat (limited to 'libjava/java/net/SocketImpl.java')
-rw-r--r-- | libjava/java/net/SocketImpl.java | 55 |
1 files changed, 35 insertions, 20 deletions
diff --git a/libjava/java/net/SocketImpl.java b/libjava/java/net/SocketImpl.java index e43b49e..8cfb9ef 100644 --- a/libjava/java/net/SocketImpl.java +++ b/libjava/java/net/SocketImpl.java @@ -36,14 +36,14 @@ this exception to your version of the library, but you are not obligated to do so. If you do not wish to do so, delete this exception statement from your version. */ - package java.net; import java.io.FileDescriptor; -import java.io.InputStream; import java.io.IOException; +import java.io.InputStream; import java.io.OutputStream; + /* Written using on-line Java Platform 1.2 API Specification. * Believed complete and correct. */ @@ -113,7 +113,8 @@ public abstract class SocketImpl implements SocketOptions * * @exception IOException If an error occurs */ - protected abstract void connect(String host, int port) throws IOException; + protected abstract void connect(String host, int port) + throws IOException; /** * Connects to the remote address and port specified as arguments. @@ -153,7 +154,8 @@ public abstract class SocketImpl implements SocketOptions * * @exception IOException If an error occurs */ - protected abstract void bind(InetAddress host, int port) throws IOException; + protected abstract void bind(InetAddress host, int port) + throws IOException; /** * Starts listening for connections on a socket. The backlog parameter @@ -220,26 +222,38 @@ public abstract class SocketImpl implements SocketOptions * * @return A FileDescriptor for this socket. */ - protected FileDescriptor getFileDescriptor() { return fd; } + protected FileDescriptor getFileDescriptor() + { + return fd; + } /** * Returns the remote address this socket is connected to * * @return The remote address */ - protected InetAddress getInetAddress() { return address; } + protected InetAddress getInetAddress() + { + return address; + } /** * Returns the remote port this socket is connected to * * @return The remote port */ - protected int getPort() { return port; } + protected int getPort() + { + return port; + } /** * Returns true or false when this socket supports sending urgent data * or not. * + * @return true if the socket implementation supports sending urgent data, + * false otherwise + * * @since 1.4 */ protected boolean supportsUrgentData() @@ -248,7 +262,7 @@ public abstract class SocketImpl implements SocketOptions // sending urgend data. return false; } - + /** * Sends one byte of urgent data to the socket. * @@ -258,15 +272,17 @@ public abstract class SocketImpl implements SocketOptions * * @since 1.4 */ - protected abstract void sendUrgentData(int data) - throws IOException; - + protected abstract void sendUrgentData(int data) throws IOException; + /** * Returns the local port this socket is bound to * * @return The local port */ - protected int getLocalPort() { return localport; } + protected int getLocalPort() + { + return localport; + } /** * Returns a <code>String</code> representing the remote host and port of @@ -276,10 +292,9 @@ public abstract class SocketImpl implements SocketOptions */ public String toString() { - return "[addr=" + ((address == null) ? "0.0.0.0/0.0.0.0" : - address.toString()) - + ",port=" + port - + ",localport=" + localport + "]"; + return "[addr=" + + ((address == null) ? "0.0.0.0/0.0.0.0" : address.toString()) + + ",port=" + port + ",localport=" + localport + "]"; } /** @@ -288,9 +303,9 @@ public abstract class SocketImpl implements SocketOptions * * @exception IOException if an error occurs */ - protected void shutdownInput () throws IOException + protected void shutdownInput() throws IOException { - throw new IOException ("Not implemented in this socket class"); + throw new IOException("Not implemented in this socket class"); } /** @@ -299,8 +314,8 @@ public abstract class SocketImpl implements SocketOptions * * @exception IOException if an error occurs */ - protected void shutdownOutput () throws IOException + protected void shutdownOutput() throws IOException { - throw new IOException ("Not implemented in this socket class"); + throw new IOException("Not implemented in this socket class"); } } |