boolean (List<RadComponent> components, RadComponent component) { RadComponent parent = component.getParent(); while (parent != null) { if (components.contains(parent)) { return true; } parent = parent.getParent(); } return false; }