Reformat rest of the design patterns - Issue #224

This commit is contained in:
Ankur Kaushal
2015-11-01 21:29:13 -05:00
parent 449340bd2b
commit 306b1f3d31
337 changed files with 6744 additions and 6851 deletions
@@ -8,20 +8,19 @@ import java.util.concurrent.BlockingQueue;
*/
public class SimpleMessageQueue implements MessageQueue {
private final BlockingQueue<Message> queue;
private final BlockingQueue<Message> queue;
public SimpleMessageQueue(int bound) {
queue = new ArrayBlockingQueue<Message>(bound);
}
public SimpleMessageQueue(int bound) {
queue = new ArrayBlockingQueue<Message>(bound);
}
@Override
public void put(Message msg) throws InterruptedException {
queue.put(msg);
}
@Override
public Message take() throws InterruptedException {
return queue.take();
}
@Override
public void put(Message msg) throws InterruptedException {
queue.put(msg);
}
@Override
public Message take() throws InterruptedException {
return queue.take();
}
}