34 */ |
34 */ |
35 |
35 |
36 class DatagramDispatcher extends NativeDispatcher { |
36 class DatagramDispatcher extends NativeDispatcher { |
37 DatagramDispatcher() { } |
37 DatagramDispatcher() { } |
38 |
38 |
39 public int read(FileDescriptor fd, long address, int len) throws IOException { |
39 int read(FileDescriptor fd, long address, int len) throws IOException { |
40 return read0(fd, address, len); |
40 return read0(fd, address, len); |
41 } |
41 } |
42 |
42 |
43 long readv(FileDescriptor fd, long address, int len) throws IOException { |
43 long readv(FileDescriptor fd, long address, int len) throws IOException { |
44 return readv0(fd, address, len); |
44 return readv0(fd, address, len); |
45 } |
45 } |
46 |
46 |
47 public int write(FileDescriptor fd, long address, int len) throws IOException { |
47 int write(FileDescriptor fd, long address, int len) throws IOException { |
48 return write0(fd, address, len); |
48 return write0(fd, address, len); |
49 } |
49 } |
50 |
50 |
51 long writev(FileDescriptor fd, long address, int len) throws IOException { |
51 long writev(FileDescriptor fd, long address, int len) throws IOException { |
52 return writev0(fd, address, len); |
52 return writev0(fd, address, len); |
53 } |
53 } |
54 |
54 |
55 public void close(FileDescriptor fd) throws IOException { |
55 void close(FileDescriptor fd) throws IOException { |
56 SocketDispatcher.invalidateAndClose(fd); |
56 SocketDispatcher.invalidateAndClose(fd); |
57 } |
57 } |
58 |
58 |
59 // -- Native methods -- |
59 // -- Native methods -- |
60 |
60 |