Commit 9a282e8e by Michael Koch Committed by Michael Koch

PlainDatagramSocketImpl.java: Reformated to match classpath's version more.

2004-03-11  Michael Koch  <konqueror@gmx.de>

	* gnu/java/net/PlainDatagramSocketImpl.java:
	Reformated to match classpath's version more.

From-SVN: r79314
parent 1f2b4715
2004-03-11 Michael Koch <konqueror@gmx.de> 2004-03-11 Michael Koch <konqueror@gmx.de>
* gnu/java/net/PlainDatagramSocketImpl.java:
Reformated to match classpath's version more.
2004-03-11 Michael Koch <konqueror@gmx.de>
* gnu/java/awt/peer/ClasspathFontPeer.java: * gnu/java/awt/peer/ClasspathFontPeer.java:
Fixed javadoc to be correct xhtml. Fixed javadoc to be correct xhtml.
* gnu/java/awt/peer/gtk/GtkArgList.java * gnu/java/awt/peer/gtk/GtkArgList.java
......
...@@ -135,13 +135,13 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl ...@@ -135,13 +135,13 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl
* *
* @exception SocketException If an error occurs * @exception SocketException If an error occurs
*/ */
protected native void bind(int lport, InetAddress laddr) protected native void bind(int port, InetAddress addr)
throws SocketException; throws SocketException;
protected native void connect (InetAddress i, int port) protected native void connect(InetAddress addr, int port)
throws SocketException; throws SocketException;
protected native void disconnect (); protected native void disconnect();
/** /**
* Creates a new datagram socket * Creates a new datagram socket
...@@ -150,9 +150,9 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl ...@@ -150,9 +150,9 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl
*/ */
protected native void create() throws SocketException; protected native void create() throws SocketException;
protected native int peek(InetAddress i) throws IOException; protected native int peek(InetAddress addr) throws IOException;
protected native int peekData (DatagramPacket dp) throws IOException; protected native int peekData(DatagramPacket packet) throws IOException;
/** /**
* Sets the Time to Live value for the socket * Sets the Time to Live value for the socket
...@@ -188,7 +188,7 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl ...@@ -188,7 +188,7 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl
* *
* @exception IOException IOException If an error occurs * @exception IOException IOException If an error occurs
*/ */
protected native void receive(DatagramPacket p) throws IOException; protected native void receive(DatagramPacket packet) throws IOException;
/** /**
* Sets the value of an option on the socket * Sets the value of an option on the socket
...@@ -198,7 +198,8 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl ...@@ -198,7 +198,8 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl
* *
* @exception SocketException If an error occurs * @exception SocketException If an error occurs
*/ */
public native void setOption(int optID, Object value) throws SocketException; public native void setOption(int option_id, Object val)
throws SocketException;
/** /**
* Retrieves the value of an option on the socket * Retrieves the value of an option on the socket
...@@ -209,8 +210,9 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl ...@@ -209,8 +210,9 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl
* *
* @exception SocketException If an error occurs * @exception SocketException If an error occurs
*/ */
public native Object getOption(int optID) throws SocketException; public native Object getOption(int option_id)
throws SocketException;
/** /**
* Joins or leaves a broadcasting group on a given network interface. * Joins or leaves a broadcasting group on a given network interface.
* If the network interface is <code>null</code> the group is join/left on * If the network interface is <code>null</code> the group is join/left on
...@@ -222,8 +224,7 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl ...@@ -222,8 +224,7 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl
* *
* @exception IOException If an error occurs. * @exception IOException If an error occurs.
*/ */
private native void mcastGrp(InetAddress inetAddr, private native void mcastGrp(InetAddress inetAddr, NetworkInterface netIf,
NetworkInterface netIf,
boolean join) boolean join)
throws IOException; throws IOException;
...@@ -267,9 +268,9 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl ...@@ -267,9 +268,9 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl
* *
* @exception IOException If an error occurs * @exception IOException If an error occurs
*/ */
protected void join(InetAddress inetaddr) throws IOException protected void join(InetAddress addr) throws IOException
{ {
mcastGrp(inetaddr, null, true); mcastGrp(addr, null, true);
} }
/** /**
...@@ -279,20 +280,20 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl ...@@ -279,20 +280,20 @@ public final class PlainDatagramSocketImpl extends DatagramSocketImpl
* *
* @exception IOException If an error occurs * @exception IOException If an error occurs
*/ */
protected void leave(InetAddress inetaddr) throws IOException protected void leave(InetAddress addr) throws IOException
{ {
mcastGrp(inetaddr, null, false); mcastGrp(addr, null, false);
} }
protected void joinGroup (SocketAddress mcastaddr, NetworkInterface netIf) protected void joinGroup(SocketAddress mcastaddr, NetworkInterface netIf)
throws IOException throws IOException
{ {
mcastGrp(((InetSocketAddress)mcastaddr).getAddress(), netIf, true); mcastGrp(((InetSocketAddress) mcastaddr).getAddress(), netIf, true);
} }
protected void leaveGroup (SocketAddress mcastaddr, NetworkInterface netIf) protected void leaveGroup(SocketAddress mcastaddr, NetworkInterface netIf)
throws IOException throws IOException
{ {
mcastGrp(((InetSocketAddress)mcastaddr).getAddress(), netIf, false); mcastGrp(((InetSocketAddress) mcastaddr).getAddress(), netIf, false);
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment