본문 바로가기
국비교육

국비교육 76일차

by Diligejy 2019. 3. 26.

1.

org.springframework.validation


ⓐ Validator(I) => 검증할 대상(Class)과 검증 내용을 적용

ⓑ DataBinder(C) => 검증할 값의 범위를 지정 또는 대상을 연결

ⓒ ValidationUtils(C) => 검증할 범위 등의 내용들



2.


void org.springframework.validation.Errors.rejectValue(String field, String errorCode, String defaultMessage)


Register a field error for the specified field of the current object(respecting the current nested path, if any), using the given errordescription.

The field name may be null or empty String to indicatethe current object itself rather than a field of it. This may resultin a corresponding field error within the nested object graph or aglobal error if the current object is the top object.
Parameters:field the field name (may be null or empty String)errorCode error code, interpretable as a message keydefaultMessage fallback default messageSee Also:getNestedPath()


3.

org.springframework.web.servlet.ModelAndView.ModelAndView(String viewName, String modelName, Object modelObject)


Convenient constructor to take a single model object.

Parameters:
viewName name of the View to render, to be resolved by the DispatcherServlet's ViewResolver
modelName name of the single entry in the model
modelObject the single model object

-> ModelObject를 ModelName으로 ViewName.jsp에 넘겨주겠다.라는 의미



4

'국비교육' 카테고리의 다른 글

MongoDB 수업 2일차 - 쿼리  (0) 2019.04.16
MongoDB 수업 1일차 - 개론  (0) 2019.04.15
국비교육 75일차  (0) 2019.03.25
국비교육 74일차  (0) 2019.03.22
국비교육 73일차  (0) 2019.03.21

댓글