boolean () { synchronized (myLock) { for (Map.Entry<ErrorTreeElementKind, List<ErrorTreeElement>> entry : mySimpleMessages.entrySet()) { final List<ErrorTreeElement> elements = entry.getValue(); if (elements != null && !elements.isEmpty()) { return false; } } } return true; }