Coder Social home page Coder Social logo

multi-threaded-restaurant-simulator's Introduction

Multi-threaded Restaurant Simulation

A class project that simulates a day of operation for a restaurant. Simulation is run using multiple threads and without the use of built in concurrent Java libraries.

Project grade: 100%

Simulation includes:

  • Customers who line up to enter the restaurant.
  • Restaurant only allows a max capacity in at a time.
  • Customers who have entered place an order.
  • Orders are sent to chefs. An available chef will take an order and begin cooking.
  • Cooking is done by dedicated machines that can cook a type of food. Each machine has a specified time it takes to cook a food item.
  • Machines can only cook a specified amount of food at a time. If capacity of machine is full, cook must wait before being able to use that machine. Cook will attempt to use other machines if needed while waiting.
  • When all items in an order are completed, the customer who placed order initially will receive their food and leave the restaurant, allowing another waiting customer to enter.

Customers, chefs, and machines run on their individual threads.

Simulation parameters can be put in from the command line or in the main() function of Simulation.java. The number of customers, restaurant capacity, number of chefs, and machine capacities can be set. Project includes a Validate.java that runs multiple tests of the output log of the simulation.

multi-threaded-restaurant-simulator's People

Contributors

vdesouza avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.