本文整理匯總了Java中org.kuali.rice.kew.api.validation.RuleValidationContext類的典型用法代碼示例。如果您正苦於以下問題:Java RuleValidationContext類的具體用法?Java RuleValidationContext怎麽用?Java RuleValidationContext使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
RuleValidationContext類屬於org.kuali.rice.kew.api.validation包,在下文中一共展示了RuleValidationContext類的7個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: validate
import org.kuali.rice.kew.api.validation.RuleValidationContext; //導入依賴的package包/類
/**
* Validates the rule within the given RuleValidationContext.
*
* @return a ValidationResults object representing the results of the validation, if this is
* empty or <code>null</code> this signifies that validation was successful.
*/
@WebMethod(operationName = "validate")
@WebResult(name = "validationResults")
@XmlElement(name = "validationResults", required = false)
ValidationResults validate(
@WebParam(name = "attributeName") String attributeName,
@WebParam(name = "validationContext") RuleValidationContext validationContext) throws RiceIllegalArgumentException;
示例2: validate
import org.kuali.rice.kew.api.validation.RuleValidationContext; //導入依賴的package包/類
@Override
public ValidationResults validate(String attributeName, RuleValidationContext validationContext) {
if (StringUtils.isBlank(attributeName)) {
throw new RiceIllegalArgumentException("attribute name was null or blank");
}
RuleValidationAttribute attr = loadAttribute(attributeName);
return attr.validate(validationContext);
}
示例3: resolveRuleValidationAttribute
import org.kuali.rice.kew.api.validation.RuleValidationContext; //導入依賴的package包/類
@Override
public RuleValidationAttribute resolveRuleValidationAttribute(final String attributeName, String applicationId) throws Exception {
final RuleValidationAttributeExporterService service = findRuleValidationAttributeExporterService(applicationId);
return (RuleValidationAttribute) Proxy.newProxyInstance(this.getClass().getClassLoader(), new Class<?>[] { RuleValidationAttribute.class }, new RuleValidationAttributeInvocationHandler() {
@Override
protected ValidationResults invokeValidate(RuleValidationContext context) throws Exception {
return service.validate(attributeName, context);
}
});
}
示例4: invoke
import org.kuali.rice.kew.api.validation.RuleValidationContext; //導入依賴的package包/類
@Override
public ValidationResults invoke(Object o, Method method, Object[] objects) throws Throwable {
if (!StringUtils.equals(method.getName(), "validate")) {
throw new UnsupportedOperationException("RuleValidationAttribute only supports 'validate'");
}
return invokeValidate((RuleValidationContext) objects[0]);
}
示例5: validate
import org.kuali.rice.kew.api.validation.RuleValidationContext; //導入依賴的package包/類
public ValidationResults validate(RuleValidationContext validationContext) {
invocations++;
return ValidationResults.Builder.create().build();
}
示例6: validate
import org.kuali.rice.kew.api.validation.RuleValidationContext; //導入依賴的package包/類
/**
* Validates the rule within the given RuleValidationContext.
*
* @return a ValidationResults object representing the results of the validation, if this is
* empty or <code>null</code> this signifies that validation was successful.
*/
public ValidationResults validate(RuleValidationContext validationContext);
示例7: invokeValidate
import org.kuali.rice.kew.api.validation.RuleValidationContext; //導入依賴的package包/類
protected abstract ValidationResults invokeValidate(RuleValidationContext context) throws Exception;