毕业设计外文资料基于socket的网络编程内容摘要:
ode to query next hop routing information for application messages. The forwarding decision is made usi ng logical addresses of the overlay nodes. Each overlay socket has two work adapters that each provides an interface to transportlayer protocols, such as TCP or UDP. The node adapter serves as the interface for sending and receiving overlay protocol messages, and the socket adapter serves as the interface for application messages. Each adapter has a transport level address, which, in the case of the Inter, consists of an IP address and a UDP or TCP port number. Currently, there are three different types of adapters, for TCP, UDP, and UDP multicast. Using two adapters pletely separates the handling of messages for maintaining the overlay protocol and the messages that transport application data. The application receive buffer and application transmit buffer can temporarily store messages that, respectively, have been received by the socket but not been delivered to the application, or that have been released by the application program, but not been transmitted by the socket. The application transmit buffer can play a role when messages cannot be transmitted due to rate control or congestion control constraints. The application transmit buffer is not implemented in the Hyper Cast software. Each overlay socket has two external interfaces. The application programming interface (API) of the socket offers application programs the ability to join and leave existing overlays, to send data to other members of the overlay work, and receive data from the overlay work. The statistics interface of the overlay socket provides access to status information of ponents of the overlay socket, and is used for monitoring and management of an overlay socket. Note in Figure 3 that some ponents of the overlay socket also have interfaces, which are accessed by other ponents of the overlay socket. The overlay manager is a ponent external to the overlay socket (and not shown in Figure 3). It is responsible for configuring an overlay socket when the socket is created. The overlay manager reads a configuration file that stores the attributes of an overlay socket, and, if it is specified in the configuration file, may access attributes from a server, and then initiates the instantiation of a new overlay socket. 4 Overlay Network Programming An application developer does not need to be familiar with the details of the ponents of an overlay socket as described in the previous section. The developer is exposed only to the API of the overlay socket and to a file with configuration parameters. The configuration file is a text file which stores all attributes needed to configure an overlay socket. The configuration file is modified whenever a change is needed to the transport protocol, the overlay protocol, or some other parameters of the overlay socket. In the following, we summarize only the main features of the API, and we refer to for detailed information on the overlay socket API. Overlay Socket API Since the overlay topology and the forwarding of applicationlayer data is transparent to the application program, the API for overlay work programming can be made simple. Applications need to be able to create a new overlay work, join and leave an existing overlay work, send data to and receive data from other members in the overlay. The API of the overlay socket is messagebased, and intentionally stays close to the familiar Berkeley socket API. Since space considerations do not permit a description of the full API, we sketch the API with the help of a simplified example. Figure 4 shows the fragment of a Java program that uses an overlay socket. An application program configures and creates an overlay socket with the help of an overlay manager. The overlay manager reads configuration parameters for the overlay socket from a configuration file (hyper cast prop), which can look similarly as shown in Figure 5. The application program reads the overlay ID with mand on get Default Property(“OverlayID”) from the file, and creates an configuration object (config) for an overlay socket with the. // generate the configuration object OverlayManager om = new OverlayManager()。 String MyOverlay = (OverlayID)。 OverlaySocketConfig config = new (MyOverlay)。 // create an overlay socket OL Socket socket = (callback)。 // Join an overlay ()。 // Create a message OL Message msg = (byte[] data, int length)。 // Send the message to all members in overlay work (msg)。 // Receive a message from the socket OL Message msg = ()。 Fig. 4. Program with overlay sockets. OVERLAY Server: OverlayServer = OVERLAY ID: OverlayID = 1234 KeyAttributes= Socket,Node,SocketAdapter SOCKET: Socket = HCast20 = 255 = 200 SOCKET ADAPTER: SocketAdapter = TCP = 16384 NODE: Node = DT20 = 400 NODE ADAPTER: NodeAdapter = NodeAdptUDPServer = 8192 = :8081 Fig. 5. Configuration file (simplified) given overlay ID. The configuration object also loads all configuration information from the configuration file, and then creates the overlay socket (config create Overlay Socket). Once the overlay socket is created, the socket joins the overlay work (socket join Group). When a socket wants to multicast a message, it instantiates a new message (socket create Message) and transmits the message using the send to all method. Other transmission options are sendToP。毕业设计外文资料基于socket的网络编程
相关推荐
, and video. Today multimedia data typically are stored outside the database, in files systems. When the number of multimedia objects is relatively small, features provided by databases are usually
属性面板 在网页编辑窗口的下面还有一个面板,它是有名的“属性面板”,它在这个软件中起到举足轻重的作用。 属性面板顾名思义,就是显示,调整属性的面板,根据鼠标所选中对象的不同,“属性面板”在界面上也会有所差异,用户 可以分别对不同的对象进行调整。 第二章 网站制作实战 站点 创建站点 要制作一个网站,第一步操作都是一样的,就是要创造一个“站点”,这样可以使整个网站的脉络结构清晰地展现在面前
生在放学后,课间操都有过练习体育中考项目的经历。 表 4中学生对于体育中考项目练习的态度调查表 N=269 8 情况 学生人数(人) 百分比( %) 完全自愿 基本自愿 不自愿 合计 104 135 30 269 100 表 4 表明 接近 90%的学生是自愿去进行体育中考项目的练习的,这说明学生对于体育学科有了足够的重视。 不管学生是否是为了获得更多的分数而去进行体育锻炼
争力,其市 4 ‘ 硕士论文 基于 DSP 的直流倒服电机控制器设计与实现 场策略是高性能、高价格,以全套自动化解决方案作为主要特点 f8l。 国内外伺服控制器的水平主要体现在三个方面:硬件方案、核心控制算法以及应用 软件功能。 国内的伺服控制器所采用的硬件平台和国外产品没有太大的差距。 国内伺服控制器 的差距主要体现在控制算法和二次开发平台的易用性方面。 尤其是在全数字化的高性能
erlying physical phenomena, and proceeded to statistical fading models, which are more appropriate for the design and performance analysis of munication schemes. We will in fact see a lot of
内部无上拉电阻。 P l 口输出缓冲器可以吸 收 20mA 电流并可 以 直 接驱动 LED。 当 Pl 口引入脚写入 1 时 可 以 作 输入 端 , 当 引 脚 用作输入并 被 外 部拉低时,它们将因内部的上拉电阻而输出电流。 P3 口还用于实现 AT89C2051 特殊功 能 , 如 表 31 所示。 表 31 P3 口特殊功能 口 引脚 功能特性 基于单片 机控制的 教 室 灯 光 自动