본문 바로가기

Spring

ModelMap 객체

상속관계 및 구현 인터페이스

 

HashMap을 상속받은 자바 컬렉션

 

 

 

Serializable :

(직렬화) 자바시스템 내부에서

사용되는 Object또는 Data

외부의 자바시스템에서도

사용할 있도록 byte형태로

데이터를 변환하는 기술

 

Cloneable :

객체 clone()시에 (다른 변수 대입 )

원본 객체에 피해를 주면 안되고,

복제본 클래스의 불변규칙을 지켜야 할때

사용됨

 

 

 

설명

Implementation of Map for use when building model data for use with UI tools. Supports chained calls and generation of model attribute names.

This class serves as generic model holder for Servlet MVC but is not tied to it. Check out the Model interface for an interface variant.

 

출처: <https://docs.spring.io/spring-framework/docs/current/javadoc-api/org/springframework/ui/ModelMap.html>

 

UI 도구와 함께 사용할 모델 데이터를 작성할 때 사용할 맵 구현. 연결된 호출 및 모델 속성 이름 생성을 지원합니다.

이 클래스는 서블릿 MVC의 일반 모델 홀더 역할을 하지만 이에 얽매이지 않습니다. 인터페이스 변형 모델의 모델 인터페이스를 확인하십시오.

 

 

ModelMap 객체에 addAttribute만 해도 데이터가 리퀘스트 영역에 담기나 보다..

리턴은 뷰페이지 디렉토리를 String으로 직접 리턴한다.

'Spring' 카테고리의 다른 글

기타 어노테이션  (0) 2021.07.29