Created
September 29, 2013 04:10
-
-
Save debop/6749269 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package kr.hconnect.data.test.mapping.usertype; | |
| import kr.hconnect.core.json.JsonTextObject; | |
| import kr.hconnect.data.model.EntityBase; | |
| import lombok.Getter; | |
| import lombok.Setter; | |
| import org.hibernate.annotations.Columns; | |
| import org.hibernate.annotations.Type; | |
| import javax.persistence.Column; | |
| import javax.persistence.Entity; | |
| import javax.persistence.GeneratedValue; | |
| import javax.persistence.Id; | |
| /** | |
| * kr.hconnect.data.test.mapping.usertype.JsonEntity | |
| * | |
| * @author 배성혁 sunghyouk.bae@gmail.com | |
| * @since 13. 9. 29. 오후 12:44 | |
| */ | |
| @Entity | |
| @Getter | |
| @Setter | |
| public class JsonEntity extends EntityBase { | |
| @Id | |
| @GeneratedValue | |
| private Long id; | |
| @Columns(columns = { @Column(name = "className"), @Column(name = "jsonText", length=2000) }) | |
| @Type(type = "kr.hconnect.data.hibernate.usertype.JsonUserType") | |
| private JsonTextObject jsonTextObject; | |
| private static final long serialVersionUID = 2820804056937831772L; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment