网络通信常用类
作者:互联网
InetAddress类:表示互联网协议 (IP) 地址
URL类:代表一个统一资源定位符,它是指向互联网“资源”的指针。 资源可以是简单的文件或目录,也可以是对更为复杂的对象的引用,例如对数据库或搜索引擎的查询。URLConnection类:用于读取和写入此 URL 引用的资源。使用步骤:通过在 URL 上调用 openConnection 方法创建连接对象。处理设置参数和一般请求属性。使用 connect 方法建立到远程对象的实际连接。 远程对象变为可用。远程对象的头字段和内容变为可访问。DatagramPacket类:此类表示数据报包。 数据报包用来实现无连接包投递服务。每条报文仅根据该包中包含的信息从一台机器路由到另一台机器。DatagramSocket类:此类表示用来发送和接收数据报包的套接字。数据报套接字是包投递服务的发送或接收点。每个在数据报套接字上发送或接收的包都是单独编址和路由的。从一台机 器发送到另一台机器的多个包可能选择不同的路由,也可能按不同的顺序到达。
U2FsdGVkX1/tRI7/ew9EpHMxtpRS991NyXN/wz5/Wy6/sm89wMTwbbeI4+0RBqV/
+ep043V7JF+8dv/MgNlNQs4s+glxcQLB2WzzR44+CEyw0bxXkV0ts1mNdf2f29pb
SZHo9fWafVIToDhuRNTeKWN1Y2cR8cdI/QiEKwtl9GRAS0rnzGnnd8pEcDjbQsk7
oDTxxY+h9ujEuExclVRR+m31JGEbAKVjyBX6KfyTW3FgapNBBoCh/rtZrjo/6c1Y
DuPA4j6ubs0YSdMthmrQ/mziDO3NEd2ZrwxqEtY8YHdBt1I3wIHxrEMm5o1DG13d
wXqUfYY9LFqeZPH/Pb26ed0+2vmsyxBoYHdgE6qwhhCfMqrq/KCckSynOpFm9IsZ
ypD6HzPrGfmacFK0s2eI/lopaGcJoUV0nbnKe6SupIdaGzGAacY5V0kuXeEXQeRW
NebOHwJ/tmgOlCmKtQGhcs0J/YNsCBn5PBjGnYyXscq29yAAmOyGpu/7rnynp0gf
ysDRpAXfmWz4wcLb2OozCkb75ALFwBIZJ0pNvkJteTv7LjLt60FYE2/4FC+KYgK+
4ksAcY4Jz8ml+ThJRkbPgM3iRqGtvYf72FstAUNXhm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GkYNFARS+nntxHxfs7bp2DR/cDF
RIp0RBO8nsoVcVTgi2x3rnkZLH+ls3QwqBrbhkC+rqQeEGCVGOvGEi88BoS+kjGj
k2mZzW0RoN9XmsQ+Z0LbAg==
标签:网络通信,常用,URL,报包,对象,接字,远程,路由 来源: https://blog.csdn.net/xmh_sxh_1314/article/details/115408539