public boolean isValid() { // we don't check the canvas for validaty only the children // the canvas itself won't be valid because its bounds are zero if (canvas != null && canvas.children != null) { for (Node node : canvas.children) { if (!node.isValid()) { return false; } } } return true; }
public boolean isValid() { // we don't check the canvas for validaty only the children // the canvas itself won't be valid because its bounds are zero if (canvas != null && canvas.children != null) { for (Node node : canvas.children) { if (!node.isValid()) { return false; } } } return true; }
/** * A Node is considered valid if its Bounds are valid * and all the contained children are valid. */ public boolean isValid() { if (bounds == null || !bounds.isValid()) { return false; } if (children != null) { for (Node node : children) { if (!node.isValid()) { return false; } } } return true; }
/** * A Node is considered valid if its Bounds are valid * and all the contained children are valid. */ public boolean isValid() { if (bounds == null || !bounds.isValid()) { return false; } if (children != null) { for (Node node : children) { if (!node.isValid()) { return false; } } } return true; }