|
xlang v4.0 Release
程序设计语言基础库文档
|
tcp协议套接字 更多...
Public 成员函数 |
静态 Public 成员函数 |
包函数 |
静态包属性 |
额外继承的成员函数 |
tcp协议套接字
在文件 BuiltinObjects.x 第 954 行定义.
| void StreamSocket | ( | ) | throws IllegalArgumentException |
|
package |
构造函数
| StreamSocket accept | ( | ) | throws IllegalArgumentException |
|
package |
接受连接
|
package |
| long available | ( | bool | ) | throws IllegalArgumentException, IOException, InterruptedException |
实现了 Stream.
| int available | ( | long | , |
| int | |||
| ) |
|
package |
bind地址
| host | 地址 |
| port | 端口 |
| void close | ( | ) | throws IllegalArgumentException |
实现了 Stream.
|
package |
关闭套接字
实现了 Stream.
|
package |
建立UDP连接
| host | 地址 |
| port | 端口 |
| bool connect | ( | String | , |
| int | , | ||
| int | |||
| ) | throws TimeoutException, InterruptedException |
|
package |
开启禁用长连接
| be | 开启或禁用 |
|
package |
开启禁用nagle算法
| be | 开启或禁用 |
| void finalize | ( | ) |
| void flush | ( | ) | throws IOException |
实现了 Stream.
| long getHandle | ( | ) |
|
package |
获取套接字句柄
| bool getKeepAlive | ( | ) |
|
package |
获取本地32位的IP地址信息
| InetAddress getLocalInetAddress | ( | ) |
|
package |
获取本地地址信息
| String getLocalIpAddress | ( | ) |
| int getLocalPort | ( | ) |
|
package |
获取本地端口信息
| long getPosition | ( | ) | throws IllegalArgumentException, IOException |
实现了 Stream.
|
package |
获取远程32位的IP地址信息
| InetAddress getRemoteInetAddress | ( | ) |
|
package |
获取远程地址信息
| String getRemoteIpAddress | ( | ) |
| int getRemotePort | ( | ) |
|
package |
获取远程端口信息
| bool getReuseAddress | ( | ) |
|
package |
获取select触发的选项
| bool getTcpNoDelay | ( | ) |
| bool isConnected | ( | ) |
|
package |
是否已连接
|
package |
检查是否开启长连接
|
package |
检查是否开启nagle算法
| long length | ( | ) | throws IllegalArgumentException, IOException |
实现了 Stream.
|
package |
监听端口
| port | 端口号 |
| backlog | 连接等待数量 |
| bool listen | ( | String | , |
| int | , | ||
| int | |||
| ) |
|
package |
| int read | ( | byte | [], |
| int | , | ||
| int | |||
| ) | throws IndexOutOfBoundsException, IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final bool readBool | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final bool readBoolLE | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final char readChar | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final char readCharLE | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final double readDouble | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final double readDoubleLE | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final float readFloat | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final float readFloatLE | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final int readInt | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final int readIntLE | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final long readLong | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final long readLongLE | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final short readShort | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final short readShortLE | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final String readString | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final String readStringLE | ( | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| long seek | ( | int | , |
| long | |||
| ) | throws IndexOutOfBoundsException, IllegalArgumentException, IOException |
实现了 Stream.
|
package |
选择事件触发的socket
| offset | 偏移量 |
| count | 选择的总数量 |
| sets | 数组 用于接收结果 |
| time | 超时 |
|
static |
| bool setKeepAlive | ( | bool | ) |
| bool setReuseAddress | ( | bool | ) |
|
package |
设置select触发的选项
| bool setSoTimeout | ( | int | ) |
| bool setTcpNoDelay | ( | bool | ) |
|
package |
设置超时
| millis | 超时毫秒数 |
|
package |
| int write | ( | byte | [], |
| int | , | ||
| int | |||
| ) | throws IndexOutOfBoundsException, IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeBool | ( | bool | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeBoolLE | ( | bool | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeChar | ( | char | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeCharLE | ( | char | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeDouble | ( | double | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeDoubleLE | ( | double | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeFloat | ( | float | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeFloatLE | ( | float | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeInt | ( | int | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeIntLE | ( | int | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeLong | ( | long | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeLongLE | ( | long | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeShort | ( | short | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeShortLE | ( | short | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeString | ( | String | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
| final void writeStringLE | ( | String | ) | throws IllegalArgumentException, IOException, TimeoutException, InterruptedException |
实现了 Stream.
|
staticpackage |
在文件 BuiltinObjects.x 第 957 行定义.
|
staticpackage |
在文件 BuiltinObjects.x 第 955 行定义.
|
staticpackage |
在文件 BuiltinObjects.x 第 956 行定义.