private void resolveValueGrid(Node parentNode) {
        validateTagsOnlyOnce(parentNode, new String[]{"show_grid", "grid_step", "label_factor"});
        boolean showGrid = true;
        double gridStep = Double.NaN;
        int NOT_SET = Integer.MIN_VALUE, labelFactor = NOT_SET;
        Node[] childNodes = getChildNodes(parentNode);
        for (Node childNode : childNodes) {
            String nodeName = childNode.getNodeName();
            if (nodeName.equals("show_grid")) {
                showGrid = getValueAsBoolean(childNode);
            }
            else if (nodeName.equals("grid_step")) {
                gridStep = getValueAsDouble(childNode);
            }
            else if (nodeName.equals("label_factor")) {
                labelFactor = getValueAsInt(childNode);
            }
        }
        rrdGraphDef.setDrawYGrid(showGrid);
        if (!Double.isNaN(gridStep) && labelFactor != NOT_SET) {
            rrdGraphDef.setValueAxis(gridStep, labelFactor);
        }
        else if (!Double.isNaN(gridStep) || labelFactor != NOT_SET) {
            throw new IllegalArgumentException("Incomplete value axis settings");
        }
    }