티스토리 뷰

program

bean, dto, vo, pojo 등 차이점

littlecarbb 2013. 10. 3. 00:27

http://stackoverflow.com/questions/1612334/difference-between-dto-vo-pojo-javabeans

 

Java Beans
-생성자 : class는 public default constructor를 가져야한다
-Getter/Setter for private data member : 클래스 속성들은 get, set, 그 외 함수(accessor, mutator mehotds라고도 한다)로 접근할 수 있어야한다. 
-Serializable

•The class must have a public default constructor. This allows easy instantiation within editing and activation frameworks.
•The class properties must be accessible using get, set, and other methods (so-called accessor methods and mutator methods), following a standard naming convention. This allows easy automated inspection and updating of bean state within frameworks, many of which include custom editors for various types of properties.
•The class should be serializable. This allows applications and frameworks to reliably save, store, and restore the bean's state in a fashion that is independent of the VM and platform.

 

Plain Old Java Object(POJO)
-any simple object with no extra stuff


Value Object(VO)
-object such as java.lang.Integer that hold values
-represents itself a fix set of data

Data Transfer Object(DTO)
-to encapsulate data in a value object that could be transfered over the network

공지사항
최근에 올라온 글
최근에 달린 댓글
Total
Today
Yesterday
링크
«   2024/12   »
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28
29 30 31
글 보관함