客户端服务器模型

英国it课程补习范文精选:“客户端服务器模型”,这篇论文主要介绍了CSCI6303的客户端服务器模型,同时本程序将以Java socket编写,且需要用swing来进行界面的编写。

 

The program must be demonstrated in Lab on the due date. After the demo, the program must be submitted electronically through the digital dropbox on the due date. If you fail to demo your program or submit it to dropbox, your will not receive credit for the lab assignment. Put your name in the program file.

 

Objective

 

The goal of this project is to develop a client-server based chat application using sockets in Java programming language. After completing the project, you will have a basic understanding of the working of a Client/Server architecture as well as socket programming. You may work on this project with one more student. You cannot have teams with more than two students. You may work alone if you wish to. Any clarifications and revisions to the assignment will be posted on the course Web page.

 

Project Description

 

In this project, you will be writing two programs, a server and a client. The server will authenticate each client using some password file. After authentication, the client’s request will be served by the server. For this project, the client would send some string to the server and the server must forward the message to other clients known to the server.

 

You are required to implement the following steps using GUI. You may use java swing objects or applets to do that.

1.When the server is started, it will open a file (passwd.txt) which will have a mapping of hostnames to passwords. The server will store this mapping in some storage object. You may use any type of structure (arrays, arraylists, vectors etc.) to store this information. Assume that maximum number of entries in the file is 100.

2.After building the storage structure, the server would create a socket and bind it to a SERVER PORT. The server will then receive requests on this port from clients.

3.The client also creates a socket and uses this socket to communicate with the server. CLIENT PORT, SERVER PORT, SERVER IP ADDRESS and PASSWORD are supplied to the client from the GUI.

4.The client must first authenticate itself to the server. If the client is a first time user, the server must prompt the client to create a new password. Thereafter, the hostname and the password of the client must be stored in the passwd.txt file on the server.

5.After the client authenticates itself, it can start sending messages to the server. When the server receives a message from a client, it must forward the message to other clients connected to the server.

6.The client must be able to create a new group (chatroom) or join an existing group. The list of existing groups must be available to the client next to the chat window. A separate list of groups joined by the client must also be available to the client. The client must pick a group (that the client created or joined before), write a message and click send to send the message to the server.

7.The server must forward the message to only the clients who are in the selected group (multicast). If no group is selected, the message is sent to all clients connected to the server (broadcast). Clients can pick a single client and send messages to them (unicast). Messages always go to the server first and then sent out to other clients from there. Clients must have a choice to opt out of receiving messages that were sent to everyone.

8.Clients must also have a choice to be visible to other clients or not. However, all the clients within a group must be visible. Invisible clients will not receive broadcast or unicast messages. However, they will receive group messages.

9.Clients must be able to leave a group at any time.

 

Additional Requirements

 

1.Print out every request/reply sent by the client and the server.

2.Client and server programs should be able to handle and print system errors. (Use exceptions or try/catch and print errors).

3.Submission Instructions: This project requires the submission of a soft copy and a hard copy.

 

51Due作为专业的留学教育辅导机构,专业辅导语言学论文代写硕士paper代写英国matlab作业代写,自2004年至今,坚持以学生为中心,全天候服务,为海外留学生完成了数万篇assignment代写、essay代写、report代写、dissertation代写等论文,以优质的英国代写服务赢得留学生的信赖,如有英国代写code需求或者英国it课程补习需求,欢迎咨询51Due哦。

 

Advertisements

发表评论

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / 更改 )

Twitter picture

You are commenting using your Twitter account. Log Out / 更改 )

Facebook photo

You are commenting using your Facebook account. Log Out / 更改 )

Google+ photo

You are commenting using your Google+ account. Log Out / 更改 )

Connecting to %s