public class KAZipPacketReceiver extends KAPacketReceiver
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
Schema |
AcceptPollingInterval, DefaultMaxActiveConnections, DefaultPort, DefaultReceiveTimeout, receive_timeout
Constructor and Description |
---|
KAZipPacketReceiver() |
KAZipPacketReceiver(int port_number) |
KAZipPacketReceiver(int port_number,
int qsize) |
KAZipPacketReceiver(java.net.ServerSocket s) |
Modifier and Type | Method and Description |
---|---|
byte[] |
address()
external address of this packet receiver.
|
protected static java.net.InetAddress |
guessMyIPAddress() |
protected static java.net.InetAddress |
guessMyIPAddress(java.net.DatagramSocket s) |
protected static java.net.InetAddress |
guessMyIPAddress(java.net.ServerSocket s) |
int |
receive(byte[] buf)
receives a packet in the given buffer.
|
void |
setHostName(java.lang.String hostname)
explicitly sets the address of this packet receiver.
|
receive, receive, setMaxActiveConnections, shutdown
public static final java.lang.String Schema
public KAZipPacketReceiver() throws java.io.IOException
java.io.IOException
public KAZipPacketReceiver(int port_number, int qsize) throws java.io.IOException
java.io.IOException
public KAZipPacketReceiver(int port_number) throws java.io.IOException
java.io.IOException
public KAZipPacketReceiver(java.net.ServerSocket s) throws java.io.IOException
java.io.IOException
public void setHostName(java.lang.String hostname)
KAPacketReceiver
setHostName
in class KAPacketReceiver
public int receive(byte[] buf) throws PacketReceiverException
PacketReceiver
receive
in interface PacketReceiver
receive
in class KAPacketReceiver
PacketReceiverException
- in case an error occurrs
while reading.public byte[] address()
:
host:
portaddress
in interface PacketReceiver
PacketReceiver.address()
protected static java.net.InetAddress guessMyIPAddress() throws java.net.UnknownHostException
java.net.UnknownHostException
protected static java.net.InetAddress guessMyIPAddress(java.net.ServerSocket s) throws java.net.UnknownHostException
java.net.UnknownHostException
protected static java.net.InetAddress guessMyIPAddress(java.net.DatagramSocket s) throws java.net.UnknownHostException
java.net.UnknownHostException
Copyright © 2005-2011 Antonio Carzaniga.
This documentation is maintained by Antonio Carzaniga