软件包 | 描述 |
---|---|
java.lang |
提供对java编程语言的设计基础课。
|
java.net |
为实现网络应用程序提供类。
|
java.nio.channels |
定义了渠道,它代表的是能够执行I/O操作的实体连接,如文件和套接字;定义选择器,多路复用,非阻塞I/O操作。
|
javax.net |
为网络应用程序提供类。
|
javax.net.ssl |
为安全套接字包提供类。
|
javax.security.auth.kerberos |
此包包含实用类的Kerberos网络认证协议相关。
|
org.ietf.jgss |
这个包提供了一个框架,允许应用程序开发人员使用的认证安全服务、数据完整性和数据从各种底层的安全机制,如Kerberos的保密性,使用统一的API。
|
Modifier and Type | Method and Description |
---|---|
void |
SecurityManager.checkMulticast(InetAddress maddr)
抛出一个
SecurityException 如果调用线程不允许使用(加入/离开/发送/接收)IP组播。
|
void |
SecurityManager.checkMulticast(InetAddress maddr, byte ttl)
过时的。
使用# checkPermission(java。安全。许可)代替
|
Modifier and Type | Class and Description |
---|---|
class |
Inet4Address
这类代表一个互联网协议版本4(IPv4)地址。
|
class |
Inet6Address
这类代表一个互联网协议版本6(IPv6)地址。
|
Modifier and Type | Field and Description |
---|---|
protected InetAddress |
SocketImpl.address
这个套接字的远程端的IP地址。
|
Modifier and Type | Method and Description |
---|---|
InetAddress |
InterfaceAddress.getAddress()
返回该地址的
InetAddress 。
|
InetAddress |
DatagramPacket.getAddress()
返回的IP地址的机器,这个数据包被发送或从收到的数据报。
|
InetAddress |
InetSocketAddress.getAddress()
得到
InetAddress 。
|
static InetAddress[] |
InetAddress.getAllByName(String host)
给定一个主机的名称,返回其IP地址的数组,基于系统上的配置的名称服务。
|
InetAddress |
InterfaceAddress.getBroadcast()
返回此interfaceaddress广播地址的
InetAddress 。
|
static InetAddress |
InetAddress.getByAddress(byte[] addr)
返回给定的原始IP地址
InetAddress 对象。
|
static InetAddress |
InetAddress.getByAddress(String host, byte[] addr)
它创造了一个基于所提供的主机名和IP地址。
|
static InetAddress |
InetAddress.getByName(String host)
确定主机的IP地址,给定主机名。
|
protected InetAddress |
URLStreamHandler.getHostAddress(URL u)
获取我们主机的IP地址。
|
protected InetAddress |
SocketImpl.getInetAddress()
返回此套接字的
address 字段的值。
|
InetAddress |
ServerSocket.getInetAddress()
返回此服务器套接字的本地地址。
|
InetAddress |
DatagramSocket.getInetAddress()
返回此套接字连接的地址。
|
InetAddress |
Socket.getInetAddress()
返回套接字连接的地址。
|
InetAddress |
MulticastSocket.getInterface()
检索用于多播包的网络接口的地址。
|
InetAddress |
DatagramSocket.getLocalAddress()
获取绑定的套接字的本地地址。
|
InetAddress |
Socket.getLocalAddress()
获取绑定的套接字的本地地址。
|
static InetAddress |
InetAddress.getLocalHost()
返回本地主机的地址。
|
static InetAddress |
InetAddress.getLoopbackAddress()
返回回送地址。
|
protected InetAddress |
Authenticator.getRequestingSite()
获取站点请求授权
InetAddress ,或
null 如果不可用。
|
Modifier and Type | Method and Description |
---|---|
Enumeration<InetAddress> |
NetworkInterface.getInetAddresses()
返回的所有或inetaddresses绑定到该网络接口的子集枚举的便捷方法。
|
Modifier and Type | Method and Description |
---|---|
protected abstract void |
SocketImpl.bind(InetAddress host, int port)
将此套接字绑定到指定的本地IP地址和端口号。
|
protected abstract void |
DatagramSocketImpl.bind(int lport, InetAddress laddr)
结合数据报套接字到本地端口和地址。
|
protected abstract void |
SocketImpl.connect(InetAddress address, int port)
将此套接字连接到指定主机上的指定端口号。
|
void |
DatagramSocket.connect(InetAddress address, int port)
将套接字连接到这个套接字的远程地址。
|
protected void |
DatagramSocketImpl.connect(InetAddress address, int port)
一个数据报套接字连接到远程目的地。
|
static NetworkInterface |
NetworkInterface.getByInetAddress(InetAddress addr)
方便的方法来搜索一个网络接口,该接口有指定的因特网协议(IP)地址绑定到它。
|
protected abstract void |
DatagramSocketImpl.join(InetAddress inetaddr)
加入多播组。
|
void |
MulticastSocket.joinGroup(InetAddress mcastaddr)
加入一个多播组。
|
protected abstract void |
DatagramSocketImpl.leave(InetAddress inetaddr)
离开组播组。
|
void |
MulticastSocket.leaveGroup(InetAddress mcastaddr)
留下一个多播组。
|
protected abstract int |
DatagramSocketImpl.peek(InetAddress i)
偷看包,看看是谁从。
|
static PasswordAuthentication |
Authenticator.requestPasswordAuthentication(InetAddress addr, int port, String protocol, String prompt, String scheme)
向鉴定人,已与一个密码系统注册。
|
static PasswordAuthentication |
Authenticator.requestPasswordAuthentication(String host, InetAddress addr, int port, String protocol, String prompt, String scheme)
向鉴定人,已与一个密码系统注册。
|
static PasswordAuthentication |
Authenticator.requestPasswordAuthentication(String host, InetAddress addr, int port, String protocol, String prompt, String scheme, URL url, Authenticator.RequestorType reqType)
向鉴定人,已与一个密码系统注册。
|
void |
DatagramPacket.setAddress(InetAddress iaddr)
设置本机的IP地址,这个数据包被发送。
|
void |
MulticastSocket.setInterface(InetAddress inf)
设置使用网络接口的值影响其行为的方法所使用的多播网络接口。
|
Constructor and Description |
---|
DatagramPacket(byte[] buf, int length, InetAddress address, int port)
指定主机上的指定端口发送数据包的长度
length 数据报包结构。
|
DatagramPacket(byte[] buf, int offset, int length, InetAddress address, int port)
发送有偏置
ioffset to指定端口号指定主机上的数据包长度
length 数据报包结构。
|
DatagramSocket(int port, InetAddress laddr)
创建一个数据报套接字,绑定到指定的本地地址。
|
InetSocketAddress(InetAddress addr, int port)
从IP地址和端口号创建一个套接字地址。
|
ServerSocket(int port, int backlog, InetAddress bindAddr)
用指定的端口创建一个服务器,听积压,和本地IP地址绑定到。
|
Socket(InetAddress address, int port)
创建一个流套接字,并将其与指定的IP地址中的指定端口号连接起来。
|
Socket(InetAddress host, int port, boolean stream)
过时的。
使用UDP传输DatagramSocket。
|
Socket(InetAddress address, int port, InetAddress localAddr, int localPort)
创建一个套接字,并将其与指定的远程端口上的指定的远程地址连接起来。
|
Socket(String host, int port, InetAddress localAddr, int localPort)
创建一个套接字,并将其连接到指定的远程端口上的指定的远程主机上。
|
Modifier and Type | Method and Description |
---|---|
abstract InetAddress |
MembershipKey.group()
返回创建此成员键的多播组。
|
abstract InetAddress |
MembershipKey.sourceAddress()
如果这个会员关键是源的返回源地址,或
null 如果会员不特定源。
|
Modifier and Type | Method and Description |
---|---|
abstract MembershipKey |
MembershipKey.block(InetAddress source)
块多播数据报从给定的源地址。
|
MembershipKey |
MulticastChannel.join(InetAddress group, NetworkInterface interf)
加入一个多播组开始接收所有的数据包发送到组,返回一个会员的关键。
|
MembershipKey |
MulticastChannel.join(InetAddress group, NetworkInterface interf, InetAddress source)
加入一个多播组开始接收从一个给定的源地址的数据包发送到组。
|
abstract MembershipKey |
MembershipKey.unblock(InetAddress source)
疏通多播数据报从给定的源地址,先前被使用
block 方法。
|
Modifier and Type | Method and Description |
---|---|
abstract ServerSocket |
ServerSocketFactory.createServerSocket(int port, int backlog, InetAddress ifAddress)
返回绑定到指定端口的服务器套接字,并带有指定的监听积压和本地IP。
|
abstract Socket |
SocketFactory.createSocket(InetAddress host, int port)
创建一个套接字,并将其与指定的端口号连接到指定的地址处。
|
abstract Socket |
SocketFactory.createSocket(InetAddress address, int port, InetAddress localAddress, int localPort)
创建一个套接字,并将其连接到指定的远程端口上的指定的远程地址。
|
abstract Socket |
SocketFactory.createSocket(String host, int port, InetAddress localHost, int localPort)
创建一个套接字,并将其连接到指定的远程端口上的指定的远程主机上。
|
Constructor and Description |
---|
SSLServerSocket(int port, int backlog, InetAddress address)
仅由子类使用。
|
SSLSocket(InetAddress address, int port)
仅由子类使用。
|
SSLSocket(InetAddress address, int port, InetAddress clientAddress, int clientPort)
仅由子类使用。
|
SSLSocket(String host, int port, InetAddress clientAddress, int clientPort)
仅由子类使用。
|
Modifier and Type | Method and Description |
---|---|
InetAddress[] |
KerberosTicket.getClientAddresses()
返回可以使用的地址的列表列表。
|
Constructor and Description |
---|
KerberosTicket(byte[] asn1Encoding, KerberosPrincipal client, KerberosPrincipal server, byte[] sessionKey, int keyType, boolean[] flags, Date authTime, Date startTime, Date endTime, Date renewTill, InetAddress[] clientAddresses)
构建了一个kerberosticket使用凭据的信息,客户端可以接收从KDC或从缓存中读取。
|
Modifier and Type | Method and Description |
---|---|
InetAddress |
ChannelBinding.getAcceptorAddress()
获取此通道绑定的接收器的地址。
|
InetAddress |
ChannelBinding.getInitiatorAddress()
获取此通道绑定的引发剂的地址。
|
Constructor and Description |
---|
ChannelBinding(InetAddress initAddr, InetAddress acceptAddr, byte[] appData)
创建一个channelbinding对象提供的地址信息和用户数据。
|
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.