Example usage for org.apache.commons.validator ValidatorException printStackTrace

List of usage examples for org.apache.commons.validator ValidatorException printStackTrace

Introduction

In this page you can find the example usage for org.apache.commons.validator ValidatorException printStackTrace.

Prototype

public void printStackTrace() 

Source Link

Document

Prints this throwable and its backtrace to the standard error stream.

Usage

From source file:org.springmodules.commons.validator.AbstractBeanValidator.java

/**
 * Validates the supplied object using a <code>org.apache.commons.validator.Validator</code> loaded from
 * the configured <code>ValidatorFactory</code>.
 *
 * @see ValidatorFactory//www .  java 2s.  c  o  m
 */
public void validate(Object obj, Errors errors) {
    org.apache.commons.validator.Validator commonsValidator = getValidator(obj, errors);
    try {
        commonsValidator.validate();
    } catch (ValidatorException e) {
        e.printStackTrace();
        log.error("Exception while validating object " + obj, e);
    }
}