/** * Do any required validation for this node. Throw an exception if it's incorrect. */ @Override public void validateNode() { if ((getQueryKeyOrNull() == null) && (getMapping() == null)) { throw QueryException.invalidQueryKeyInExpression(getName()); } if (!getMapping().isCollectionMapping()) { throw QueryException.mapEntryExpressionForNonCollection(getBaseExpression(), getMapping()); } ContainerPolicy cp = getMapping().getContainerPolicy(); if ((cp == null) || !cp.isMapPolicy()) { throw QueryException.mapEntryExpressionForNonMap(getBaseExpression(), getMapping()); } }
/** * Do any required validation for this node. Throw an exception if it's incorrect. */ @Override public void validateNode() { if ((getQueryKeyOrNull() == null) && (getMapping() == null)) { throw QueryException.invalidQueryKeyInExpression(getName()); } if (!getMapping().isCollectionMapping()) { throw QueryException.mapEntryExpressionForNonCollection(getBaseExpression(), getMapping()); } ContainerPolicy cp = getMapping().getContainerPolicy(); if ((cp == null) || !cp.isMapPolicy()) { throw QueryException.mapEntryExpressionForNonMap(getBaseExpression(), getMapping()); } }
/** * Do any required validation for this node. Throw an exception if it's incorrect. */ public void validateNode() { if ((getQueryKeyOrNull() == null) && (getMapping() == null)) { throw QueryException.invalidQueryKeyInExpression(getName()); } if (!getMapping().isCollectionMapping()){ throw QueryException.mapEntryExpressionForNonCollection(getBaseExpression(), getMapping()); } ContainerPolicy cp = getMapping().getContainerPolicy(); if ((cp == null) || !(cp.isMapPolicy() || cp.isDirectMapPolicy())){ throw QueryException.mapEntryExpressionForNonMap(getBaseExpression(), getMapping()); } }