Specifications
Sun Services
Java™ Programming Language
Module 13, slide 34 of 37
Copyright 2005 Sun Microsystems, Inc. All Rights Reserved. Sun Services, Revision F
The pop Method
9 public synchronized char pop() {
10 char c;
11 while (buffer.size() == 0) {
12 try {
13 this.wait();
14 } catch (InterruptedException e) {
15 // ignore it...
16 }
17 }
18 c = buffer.remove(buffer.size()-1);
19 return c;
20 }










