package p2;

/**
 * This class implements the doorman's part of the
 * Barbershop thread synchronization example.
 * One doorman instance corresponds to one producer in
 * the producer/consumer problem.
 */
public class Doorman implements Runnable {
	/**
	 * Creates a new doorman. Make sure to save these variables in the class.
	 * @param queue		The customer queue.
	 * @param gui		A reference to the GUI interface.
	 */
	public Doorman(CustomerQueue queue, Gui gui) { 
		// Incomplete
	}

	/**
	 * This is the code that will run when a new thread is
	 * created for this instance.
	 */
	@Override
	public void run(){
		// Incomplete
	}


	/**
	 * Starts the doorman running as a separate thread. Make
	 * sure to create the thread and start it.
	 */
	public void startThread() {
		// Incomplete
	}

	/**
	 * Stops the doorman thread. Use Thread.join() for stopping
	 * a thread.
	 */
	public void stopThread() {
		// Incomplete
	}

	// Add more methods as needed
}

@@ -422,32 +422,71 @@
 terface.%0D%0A%09 */%0D%0A
+%09%0D%0A%09CustomerQueue queue;%0D%0A%09Gui gui;%0D%0A%0D%0A
 %09public Doorman(
@@ -517,37 +517,62 @@
  gui) %7B %0D%0A%09%09
-// Incomplete
+this.queue = queue;%0D%0A%09%09this.gui = gui;
 %0D%0A%09%7D%0D%0A%0D%0A%09/**

Add contructor to Doorman