Code example for ArrayBlockingQueue

Methods: put

0
	 * 
	 * @param t the t 
	 * @throws InterruptedException the interrupted exception 
	 */ 
	public void push(T t) throws InterruptedException {
		queue.put(t);
	} 
 
	/** 
	 * Pop. 
	 * 
	 * @return the t 
	 * @throws InterruptedException the interrupted exception 
	 */ 
	public T pop() throws InterruptedException { 
		T t = queue.poll(1, TimeUnit.SECONDS);
		return t;
	} 
	 
	/** 
	 * Do stuff.