Implement the client and server components

Assignment Help JAVA Programming
Reference no: EM13923991

Assignment - Chat Client/Server System

Project Details:

In this assignment students will explore basic socket programming, threading and GUI design using Java's network library, threading system, and swing user interface libraries to implement a basic chat client and server system. The system will allow multiple, remote users to send and receive messages across the network. On receiving a send message from a client the server component will broadcast the message to the other clients connected to the server. Consequently, the server component must be multithreaded so as to coordinate communications between the client systems.

Part A - Basic Requirements:

The basic requirements of this assignment are to implement the client and server components as discussed above. The basic protocol of the system is described below:

The operations of the client are:
• SEND_SERVER_MESG: send a basic text message to the server
• RECV_ SERVER_MESG: receive text from the server

The operations of the server are:
• RECV_CLIENT_MESG: receive text from a client
• BROADCAST_MESG: broadcast a text message received from a client to all the other clients connected to the server.

The server component should be multithreaded, and new threads should be allocated and de-allocated when clients connect and disconnect from the server. These threads can be thought of as connection handlers which manage a client socket and input, output streams. To keep track of these handlers some sort of dynamic data structure such as a vector or similar data structure can be used to coordinate access to these message handlers. The client component should be implemented as a GUI interface, and should allow users to enter text messages, display broadcast messages from the server, and send messages using a send button.

The diagram below reflects a typical implementation:

714_img.png

Part B - Extensions:

Basic implementation of the assignment requirements will result in only a passing grade or credit result. To get a distinction or high distinction mark several extensions are possible and include:

1) Client registration (text file based, rather than database based, including username and password)

2) Private messaging between users.

3) Blocking messages from specific users.

4) File or image transfer options.

5) Statistics functions for management at the server side (such as current users, total users, average time online, etc.).

6) Algorithms for efficient thread management.

Reference no: EM13923991

Questions Cloud

Are they likely to make economic profits initially : Are they likely to make economic profits initially? Can they continue to make economic profits in the long term? Why or why not? Discuss. What advice would you give to Alba and Gavigan to help them make more profit in the long term?
Expected loss over the next year with a probability : A stock has an annual return of 11 percent and a standard deviation of 44 percent. What is the smallest expected loss over the next year with a probability of 1 percent?
Compared and contrasted rorschach and mmpi : Submit your response to the: Assignment by Wednesday, August 5, 2015. a) Compared and contrasted Rorschach and MMPI
Jernigan corporation balance sheets : Condensed balance sheet and income statement data for Jernigan Corporation are presented here: Compute the following ratios for 2013 and 2014.
Implement the client and server components : The basic requirements of this assignment are to implement the client and server components as discussed above. The basic protocol of the system is described below: The operations of the client are: SEND_SERVER_MESG: send a basic text message to th..
Derive ggc marginal revenue and marginal cost curves : Derive GGC's marginal revenue (MR) and marginal cost (MC) curves in each market. Show graphically GGC's demand, MR, and MC curves for each market. Derive algebraically the quantities that should be produced and sold, and the prices that should be c..
Discuss how primary market is dependent on secondary market : Define a primary and secondary market for securities and discuss how they differ. Discuss how the primary market is dependent on the secondary market.
Approximate-exact expected real risk premiums on portfolio : Consider the following information about three stocks: Rate of Return If State Occurs State of Probability of Economy State of Economy Stock A Stock B Stock C Boom .20 .34 .46 .50 Normal .40 .25 .23 .20 Bust .40 .03 −.25 −.42. what are the approximat..
What will be its total dividend payment : Rohter Galeano Inc. is considering how to set its dividend policy. It has a capital budget of $3,000,000. The company wants to maintain a target capital structure that is 15% debt and 85% equity. what will be its total dividend payment?

Reviews

Write a Review

JAVA Programming Questions & Answers

  Write an executable program with java

calculates the cost of the baggage when the weight of the baggage is stated by the operator. The baggage cost should differ from city to city

  Solution for the problem and mention algorithms

Explain the purpose of the program as detail as possible and develop a solution for the problem and mention algorithms to be used and list data structures to be used in solution.

  Create a class that inherits from your pizzaorder class

Create a class that inherits from your PizzaOrder class called SeatedPizzaOrder. SeatedPizzaOrder has the three data values that any PizzaOrder has (size, toppings, and price) but also has a tablenumber (of type integer) and serverName (of type st..

  Part-1prepare a program that teaches arithmetic to a young

part-1prepare a program that teaches arithmetic to a young child. the program tests subtraction and addition. in level

  Print the contents of the array

Prepare a second loop that prints the contents of the array

  Loops and files

Convert an algorithm using control structures into Java and write a while loop

  Java program by array

Write a program that reads in a file that contains one integer per line. Each integer represents one location in the image. Assume that there are 64 rows and 64 columns in the image

  Using joptionpanes to handle your input and output

Using JOptionPanes to handle your input and output, produce a Java program which, given three sides of a triangle, determines whether the triangle is.

  Square matrix of dimension

You are given a square matrix of dimension N. Let this matrix be called A. Your task is to rotate A in clockwise direction byS degrees, where S is angle of rotation. On the matrix, there will be 3 types of operations viz.

  Determine the day of the week for new year''s day

This assignment contains a java project. Project evaluates the day of the week for New Year's Day.

  1 give the big o for the followinga n2 6n 32b n 6c

1 give the big o for the followinga. n2 6n 32b. n 6c. analyze the code below for integer n

  Allows a user to select a favorite basketball team

Write an application that allows a user to select a favorite basketball team from a list box. Include at least five teams in the list, and display the chosen team in a text field after the user makes a selection. Save the file as JBasketball.java. :

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd