Source Code Cross Referenced for INetworkSystem.java in  » Apache-Harmony-Java-SE » org-package » org » apache » harmony » luni » platform » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Apache Harmony Java SE » org package » org.apache.harmony.luni.platform 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         *  Licensed to the Apache Software Foundation (ASF) under one or more
003:         *  contributor license agreements.  See the NOTICE file distributed with
004:         *  this work for additional information regarding copyright ownership.
005:         *  The ASF licenses this file to You under the Apache License, Version 2.0
006:         *  (the "License"); you may not use this file except in compliance with
007:         *  the License.  You may obtain a copy of the License at
008:         *
009:         *     http://www.apache.org/licenses/LICENSE-2.0
010:         *
011:         *  Unless required by applicable law or agreed to in writing, software
012:         *  distributed under the License is distributed on an "AS IS" BASIS,
013:         *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
014:         *  See the License for the specific language governing permissions and
015:         *  limitations under the License.
016:         */
017:
018:        package org.apache.harmony.luni.platform;
019:
020:        import java.io.FileDescriptor;
021:        import java.io.IOException;
022:        import java.net.DatagramPacket;
023:        import java.net.InetAddress;
024:        import java.net.SocketException;
025:        import java.net.SocketImpl;
026:        import java.net.UnknownHostException;
027:        import java.nio.channels.Channel;
028:
029:        /*
030:         * The interface for network methods.
031:         */
032:        public interface INetworkSystem {
033:
034:            /*
035:             * Socket connect Step start
036:             */
037:            public final int SOCKET_CONNECT_STEP_START = 0;
038:
039:            /*
040:             * Socket connect Step check
041:             */
042:            public final int SOCKET_CONNECT_STEP_CHECK = 1;
043:
044:            /*
045:             * socket accept
046:             */
047:            public void accept(FileDescriptor fdServer, SocketImpl newSocket,
048:                    FileDescriptor fdnewSocket, int timeout) throws IOException;
049:
050:            public void bind(FileDescriptor aFD, int port,
051:                    InetAddress inetAddress) throws SocketException;
052:
053:            public boolean bind2(FileDescriptor aFD, int port,
054:                    boolean bindToDevice, InetAddress inetAddress)
055:                    throws SocketException;
056:
057:            public void createSocket(FileDescriptor fd, boolean preferIPv4Stack)
058:                    throws IOException;
059:
060:            public int read(FileDescriptor aFD, byte[] data, int offset,
061:                    int count, int timeout) throws IOException;
062:
063:            public int readDirect(FileDescriptor aFD, long address, int count,
064:                    int timeout) throws IOException;
065:
066:            public int write(FileDescriptor fd, byte[] data, int offset,
067:                    int count) throws IOException;
068:
069:            public int writeDirect(FileDescriptor fd, long address, int count)
070:                    throws IOException;
071:
072:            public void setNonBlocking(FileDescriptor aFD, boolean block)
073:                    throws IOException;
074:
075:            public int connect(FileDescriptor aFD, int trafficClass,
076:                    InetAddress inetAddress, int port) throws IOException;
077:
078:            public int connectWithTimeout(FileDescriptor aFD, int timeout,
079:                    int trafficClass, InetAddress hostname, int port, int step,
080:                    Long context) throws IOException;
081:
082:            public int sendDatagram(FileDescriptor fd, byte[] data, int offset,
083:                    int length, int port, boolean bindToDevice,
084:                    int trafficClass, InetAddress inetAddress)
085:                    throws IOException;
086:
087:            public int sendDatagramDirect(FileDescriptor fd, long address,
088:                    int offset, int length, int port, boolean bindToDevice,
089:                    int trafficClass, InetAddress inetAddress)
090:                    throws IOException;
091:
092:            public int receiveDatagram(FileDescriptor aFD,
093:                    DatagramPacket packet, byte[] data, int offset, int length,
094:                    int receiveTimeout, boolean peek) throws IOException;
095:
096:            public int receiveDatagramDirect(FileDescriptor aFD,
097:                    DatagramPacket packet, long address, int offset,
098:                    int length, int receiveTimeout, boolean peek)
099:                    throws IOException;
100:
101:            public int recvConnectedDatagram(FileDescriptor aFD,
102:                    DatagramPacket packet, byte[] data, int offset, int length,
103:                    int receiveTimeout, boolean peek) throws IOException;
104:
105:            public int recvConnectedDatagramDirect(FileDescriptor aFD,
106:                    DatagramPacket packet, long address, int offset,
107:                    int length, int receiveTimeout, boolean peek)
108:                    throws IOException;
109:
110:            public int peekDatagram(FileDescriptor aFD, InetAddress sender,
111:                    int receiveTimeout) throws IOException;
112:
113:            public int sendConnectedDatagram(FileDescriptor fd, byte[] data,
114:                    int offset, int length, boolean bindToDevice)
115:                    throws IOException;
116:
117:            public int sendConnectedDatagramDirect(FileDescriptor fd,
118:                    long address, int offset, int length, boolean bindToDevice)
119:                    throws IOException;
120:
121:            public void disconnectDatagram(FileDescriptor aFD)
122:                    throws SocketException;
123:
124:            public void createDatagramSocket(FileDescriptor aFD,
125:                    boolean preferIPv4Stack) throws SocketException;
126:
127:            public void connectDatagram(FileDescriptor aFD, int port,
128:                    int trafficClass, InetAddress inetAddress)
129:                    throws SocketException;
130:
131:            public void createMulticastSocket(FileDescriptor aFD,
132:                    boolean preferIPv4Stack) throws SocketException;
133:
134:            public void createServerStreamSocket(FileDescriptor aFD,
135:                    boolean preferIPv4Stack) throws SocketException;
136:
137:            public int receiveStream(FileDescriptor aFD, byte[] data,
138:                    int offset, int count, int timeout) throws IOException;
139:
140:            public int sendStream(FileDescriptor fd, byte[] data, int offset,
141:                    int count) throws IOException;
142:
143:            public void shutdownInput(FileDescriptor descriptor)
144:                    throws IOException;
145:
146:            public void shutdownOutput(FileDescriptor descriptor)
147:                    throws IOException;
148:
149:            public boolean supportsUrgentData(FileDescriptor fd);
150:
151:            public void sendUrgentData(FileDescriptor fd, byte value);
152:
153:            public int availableStream(FileDescriptor aFD)
154:                    throws SocketException;
155:
156:            public void acceptStreamSocket(FileDescriptor fdServer,
157:                    SocketImpl newSocket, FileDescriptor fdnewSocket,
158:                    int timeout) throws IOException;
159:
160:            public void createStreamSocket(FileDescriptor aFD,
161:                    boolean preferIPv4Stack) throws SocketException;
162:
163:            public void listenStreamSocket(FileDescriptor aFD, int backlog)
164:                    throws SocketException;
165:
166:            public void connectStreamWithTimeoutSocket(FileDescriptor aFD,
167:                    int aport, int timeout, int trafficClass,
168:                    InetAddress inetAddress) throws IOException;
169:
170:            public int sendDatagram2(FileDescriptor fd, byte[] data,
171:                    int offset, int length, int port, InetAddress inetAddress)
172:                    throws IOException;
173:
174:            public InetAddress getSocketLocalAddress(FileDescriptor aFD,
175:                    boolean preferIPv6Addresses);
176:
177:            public int[] select(FileDescriptor[] readFDs,
178:                    FileDescriptor[] writeFDs, long timeout)
179:                    throws SocketException;
180:
181:            /*
182:             * Query the IP stack for the local port to which this socket is bound.
183:             * 
184:             * @param aFD the socket descriptor @param preferIPv6Addresses address
185:             * preference for nodes that support both IPv4 and IPv6 @return int the
186:             * local port to which the socket is bound
187:             */
188:            public int getSocketLocalPort(FileDescriptor aFD,
189:                    boolean preferIPv6Addresses);
190:
191:            /*
192:             * Query the IP stack for the nominated socket option.
193:             * 
194:             * @param aFD the socket descriptor @param opt the socket option type
195:             * @return the nominated socket option value
196:             * 
197:             * @throws SocketException if the option is invalid
198:             */
199:            public Object getSocketOption(FileDescriptor aFD, int opt)
200:                    throws SocketException;
201:
202:            /*
203:             * Set the nominated socket option in the IP stack.
204:             * 
205:             * @param aFD the socket descriptor @param opt the option selector @param
206:             * optVal the nominated option value
207:             * 
208:             * @throws SocketException if the option is invalid or cannot be set
209:             */
210:            public void setSocketOption(FileDescriptor aFD, int opt,
211:                    Object optVal) throws SocketException;
212:
213:            public int getSocketFlags();
214:
215:            /*
216:             * Close the socket in the IP stack.
217:             * 
218:             * @param aFD the socket descriptor
219:             */
220:            public void socketClose(FileDescriptor aFD) throws IOException;
221:
222:            public InetAddress getHostByAddr(byte[] addr)
223:                    throws UnknownHostException;
224:
225:            public InetAddress getHostByName(String addr,
226:                    boolean preferIPv6Addresses) throws UnknownHostException;
227:
228:            public void setInetAddress(InetAddress sender, byte[] address);
229:
230:            public boolean isReachableByICMP(InetAddress dest,
231:                    InetAddress source, int ttl, int timeout);
232:
233:            public Channel inheritedChannel();
234:
235:            public void oneTimeInitialization(boolean jcl_supports_ipv6);
236:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.