public boolean contains(final String name) { for (final CategoryItem child : children) { if (child.getName().equals(name)) { return true; } } return false; }
public void removeChildren(final String name) { for (int i = 0; i < children.size(); i++) { final CategoryItem child = children.get(i); if (child.getName().equals(name)) { children.remove(i); break; } } }