Returns the contents of the Cache as a string.
()
| 828 | * Returns the contents of the Cache as a string. |
| 829 | */ |
| 830 | public String |
| 831 | toString() { |
| 832 | StringBuffer sb = new StringBuffer(); |
| 833 | synchronized (this) { |
| 834 | Iterator it = data.values().iterator(); |
| 835 | while (it.hasNext()) { |
| 836 | Element [] elements = allElements(it.next()); |
| 837 | for (int i = 0; i < elements.length; i++) { |
| 838 | sb.append(elements[i]); |
| 839 | sb.append("\n"); |
| 840 | } |
| 841 | } |
| 842 | } |
| 843 | return sb.toString(); |
| 844 | } |
| 845 | |
| 846 | } |