PCRuntimeLibrary::validateConstraintFocused Method [AX 2012]

Validates the constraint definition by using the solver and XML schema validations.

client server public static boolean validateConstraintFocused(
    PCProductConfigurationModel _productModel, 
    PCConstraint _constraint, 
    Set _outErrorMessages, 
   [boolean _throwOnError])

Run On

Called

Parameters

_productModel
Type: PCProductConfigurationModel Table
The product model that contains the constraint.
_constraint
Type: PCConstraint Table
The specified constraint to validate.
_outErrorMessages
Type: Set Class
The string set that receives the error message string if the validation fails.
_throwOnError
Type: boolean
A Boolean value that indicates whether the method throws an exception if an error is found; optional.

Return Value

Type: boolean
true if the validation of the constraint succeeds; otherwise, false.

ExceptionCondition
Error

The _productModel, _constraint, and _outErrorMessages parameters are nullNothingnullptrunita null reference (Nothing in Visual Basic) or undefined.

-or-

The _throwOnError parameter is set to true and the validation of the constraint fails.

Since the validation will focus on the specified constraint, validation will not fail because of other invalid constraints.

Show: