Uses of Class
java.net.SocketAddress
-
Packages that use SocketAddress 软件包 描述 com.sun.nio.sctp 用于流控制传输协议的Java API。java.net 提供实现网络应用程序的类。java.nio.channels 定义通道,其表示与能够执行I / O操作的实体的连接,例如文件和套接字; 定义选择器,用于多路复用,非阻塞I / O操作。 -
-
Uses of SocketAddress in com.sun.nio.sctp
Fields in com.sun.nio.sctp with type parameters of type SocketAddress Modifier and Type Field 描述 static SctpSocketOption<SocketAddress>
SctpStandardSocketOptions. SCTP_PRIMARY_ADDR
请求本地SCTP堆栈使用给定对等体地址作为关联主节点。static SctpSocketOption<SocketAddress>
SctpStandardSocketOptions. SCTP_SET_PEER_PRIMARY_ADDR
请求对等方将附带的地址标记为关联主。Methods in com.sun.nio.sctp that return SocketAddress Modifier and Type 方法 描述 abstract SocketAddress
MessageInfo. address()
如果接收到消息,则返回源套接字地址,否则将发送消息的首选目标。abstract SocketAddress
PeerAddressChangeNotification. address()
返回对等地址。abstract SocketAddress
SendFailedNotification. address()
返回地址。Methods in com.sun.nio.sctp that return types with arguments of type SocketAddress Modifier and Type 方法 描述 abstract Set<SocketAddress>
SctpChannel. getAllLocalAddresses()
返回此通道的套接字所绑定的所有套接字地址。abstract Set<SocketAddress>
SctpMultiChannel. getAllLocalAddresses()
返回此通道的套接字所绑定的所有套接字地址。abstract Set<SocketAddress>
SctpServerChannel. getAllLocalAddresses()
返回此通道的套接字所绑定的所有套接字地址。abstract Set<SocketAddress>
SctpChannel. getRemoteAddresses()
返回此通道的套接字所连接的所有远程地址。abstract Set<SocketAddress>
SctpMultiChannel. getRemoteAddresses(Association association)
返回此通道的套接字连接给定关联的所有远程地址。Methods in com.sun.nio.sctp with parameters of type SocketAddress Modifier and Type 方法 描述 abstract SctpChannel
SctpChannel. bind(SocketAddress local)
将通道的套接字绑定到本地地址。SctpMultiChannel
SctpMultiChannel. bind(SocketAddress local)
将通道的套接字绑定到本地地址,并配置套接字以监听连接。abstract SctpMultiChannel
SctpMultiChannel. bind(SocketAddress local, int backlog)
将通道的套接字绑定到本地地址,并配置套接字以监听连接。SctpServerChannel
SctpServerChannel. bind(SocketAddress local)
将通道的套接字绑定到本地地址,并配置套接字以侦听关联。abstract SctpServerChannel
SctpServerChannel. bind(SocketAddress local, int backlog)
将通道的套接字绑定到本地地址,并配置套接字以侦听关联。abstract boolean
SctpChannel. connect(SocketAddress remote)
连接此通道的插座。abstract boolean
SctpChannel. connect(SocketAddress remote, int maxOutStreams, int maxInStreams)
连接此通道的插座。static MessageInfo
MessageInfo. createOutgoing(Association association, SocketAddress address, int streamNumber)
创建适用于向给定关联发送消息时使用的MessageInfo
实例。static MessageInfo
MessageInfo. createOutgoing(SocketAddress address, int streamNumber)
创建适用于发送消息时使用的MessageInfo
实例。static SctpChannel
SctpChannel. open(SocketAddress remote, int maxOutStreams, int maxInStreams)
打开SCTP通道并将其连接到远程地址。 -
Uses of SocketAddress in java.net
Subclasses of SocketAddress in java.net Modifier and Type Class 描述 class
InetSocketAddress
该类实现IP套接字地址(IP地址+端口号)它也可以是一对(主机名+端口号),在这种情况下将尝试解析主机名。Methods in java.net that return SocketAddress Modifier and Type 方法 描述 SocketAddress
Proxy. address()
返回代理的套接字地址,如果是null
则直接连接。SocketAddress
DatagramSocket. getLocalSocketAddress()
返回此套接字绑定到的端点的地址。SocketAddress
ServerSocket. getLocalSocketAddress()
返回此套接字绑定到的端点的地址。SocketAddress
Socket. getLocalSocketAddress()
返回此套接字绑定到的端点的地址。SocketAddress
DatagramSocket. getRemoteSocketAddress()
返回此套接字连接到的端点的地址,如果未连接,则null
。SocketAddress
Socket. getRemoteSocketAddress()
返回此套接字连接到的端点的地址,如果未连接,则null
。SocketAddress
DatagramPacket. getSocketAddress()
获取该数据包发送到或正在从其发送的远程主机的SocketAddress(通常为IP地址+端口号)。Methods in java.net with parameters of type SocketAddress Modifier and Type 方法 描述 void
DatagramSocket. bind(SocketAddress addr)
将此DatagramSocket绑定到特定的地址和端口。void
ServerSocket. bind(SocketAddress endpoint)
将ServerSocket
绑定到特定地址(IP地址和端口号)。void
ServerSocket. bind(SocketAddress endpoint, int backlog)
将ServerSocket
绑定到特定地址(IP地址和端口号)。void
Socket. bind(SocketAddress bindpoint)
将套接字绑定到本地地址。void
DatagramSocket. connect(SocketAddress addr)
将此套接字连接到远程套接字地址(IP地址+端口号)。void
Socket. connect(SocketAddress endpoint)
将此套接字连接到服务器。void
Socket. connect(SocketAddress endpoint, int timeout)
将此套接字连接到具有指定超时值的服务器。protected abstract void
SocketImpl. connect(SocketAddress address, int timeout)
将此套接字连接到指定主机上的指定端口号。abstract void
ProxySelector. connectFailed(URI uri, SocketAddress sa, IOException ioe)
被称为表示连接不能建立到代理/袜子服务器。protected abstract void
DatagramSocketImpl. joinGroup(SocketAddress mcastaddr, NetworkInterface netIf)
加入组播组。void
MulticastSocket. joinGroup(SocketAddress mcastaddr, NetworkInterface netIf)
在指定的接口加入指定的组播组。protected abstract void
DatagramSocketImpl. leaveGroup(SocketAddress mcastaddr, NetworkInterface netIf)
离开组播组。void
MulticastSocket. leaveGroup(SocketAddress mcastaddr, NetworkInterface netIf)
在指定的本地接口上留下组播组。void
DatagramPacket. setSocketAddress(SocketAddress address)
设置该数据报发送到的远程主机的SocketAddress(通常是IP地址+端口号)。Constructors in java.net with parameters of type SocketAddress Constructor 描述 DatagramPacket(byte[] buf, int offset, int length, SocketAddress address)
构造一个数据报包,发送长度为length
的数据包,并将偏移量为ioffset
到指定主机上的指定端口号。DatagramPacket(byte[] buf, int length, SocketAddress address)
构造一个数据报包,将数据包长度为length
,发送到指定主机上的指定端口号。DatagramSocket(SocketAddress bindaddr)
创建一个数据报套接字,绑定到指定的本地套接字地址。MulticastSocket(SocketAddress bindaddr)
创建一个绑定到指定套接字地址的MulticastSocket。Proxy(Proxy.Type type, SocketAddress sa)
创建一个表示PROXY连接的条目。 -
Uses of SocketAddress in java.nio.channels
Methods in java.nio.channels that return SocketAddress Modifier and Type 方法 描述 abstract SocketAddress
AsynchronousServerSocketChannel. getLocalAddress()
返回此通道的套接字所绑定的套接字地址。abstract SocketAddress
AsynchronousSocketChannel. getLocalAddress()
返回此通道的套接字所绑定的套接字地址。abstract SocketAddress
DatagramChannel. getLocalAddress()
返回此通道的套接字所绑定的套接字地址。SocketAddress
NetworkChannel. getLocalAddress()
返回此通道的套接字所绑定的套接字地址。abstract SocketAddress
ServerSocketChannel. getLocalAddress()
返回此通道的套接字所绑定的套接字地址。abstract SocketAddress
SocketChannel. getLocalAddress()
返回此通道的套接字所绑定的套接字地址。abstract SocketAddress
AsynchronousSocketChannel. getRemoteAddress()
返回此通道的插座所连接的远程地址。abstract SocketAddress
DatagramChannel. getRemoteAddress()
返回此通道的插座所连接的远程地址。abstract SocketAddress
SocketChannel. getRemoteAddress()
返回此通道的插座所连接的远程地址。abstract SocketAddress
DatagramChannel. receive(ByteBuffer dst)
通过该频道接收数据报。Methods in java.nio.channels with parameters of type SocketAddress Modifier and Type 方法 描述 AsynchronousServerSocketChannel
AsynchronousServerSocketChannel. bind(SocketAddress local)
将通道的套接字绑定到本地地址,并配置套接字以监听连接。abstract AsynchronousServerSocketChannel
AsynchronousServerSocketChannel. bind(SocketAddress local, int backlog)
将通道的套接字绑定到本地地址,并配置套接字以监听连接。abstract AsynchronousSocketChannel
AsynchronousSocketChannel. bind(SocketAddress local)
abstract DatagramChannel
DatagramChannel. bind(SocketAddress local)
NetworkChannel
NetworkChannel. bind(SocketAddress local)
将通道的套接字绑定到本地地址。ServerSocketChannel
ServerSocketChannel. bind(SocketAddress local)
将通道的套接字绑定到本地地址,并配置套接字以监听连接。abstract ServerSocketChannel
ServerSocketChannel. bind(SocketAddress local, int backlog)
将通道的套接字绑定到本地地址,并配置套接字以监听连接。abstract SocketChannel
SocketChannel. bind(SocketAddress local)
abstract Future<Void>
AsynchronousSocketChannel. connect(SocketAddress remote)
连接此频道。abstract <A> void
AsynchronousSocketChannel. connect(SocketAddress remote, A attachment, CompletionHandler<Void,? super A> handler)
连接此频道。abstract DatagramChannel
DatagramChannel. connect(SocketAddress remote)
连接此通道的插座。abstract boolean
SocketChannel. connect(SocketAddress remote)
连接此通道的插座。static SocketChannel
SocketChannel. open(SocketAddress remote)
打开套接字通道并将其连接到远程地址。abstract int
DatagramChannel. send(ByteBuffer src, SocketAddress target)
通过此频道发送数据报。
-