Example usage for org.springframework.validation BindException setNestedPath

List of usage examples for org.springframework.validation BindException setNestedPath

Introduction

In this page you can find the example usage for org.springframework.validation BindException setNestedPath.

Prototype

@Override
    public void setNestedPath(String nestedPath) 

Source Link

Usage

From source file:edu.psu.citeseerx.myciteseer.web.AddFriendFormController.java

protected void onBindAndValidate(HttpServletRequest request, Object command, BindException errors)
        throws Exception {

    Friend friend = (Friend) command;/*from   www .  j a  v a 2s.c  om*/
    errors.setNestedPath("friend");
    getValidator().validate(friend, errors);
    errors.setNestedPath("");

}