Guest User

JPA Entity

a guest
Aug 27th, 2012
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.76 KB | None | 0 0
  1. package cz.sedlackovi.test.entity;
  2.  
  3. import java.io.Serializable;
  4.  
  5. import javax.persistence.Entity;
  6. import javax.persistence.GeneratedValue;
  7. import javax.persistence.GenerationType;
  8. import javax.persistence.Id;
  9.  
  10. /**
  11.  * Entity implementation class for Entity: Message
  12.  *
  13.  */
  14. @Entity
  15.  
  16. public class Zprava implements Serializable {
  17.  
  18.    
  19.     private String text;  
  20.     @Id
  21.     @GeneratedValue(strategy = GenerationType.AUTO)
  22.     private Long id;
  23.     private static final long serialVersionUID = 1L;
  24.  
  25.     public Zprava() {
  26.         super();
  27.     }  
  28.     public String getText() {
  29.         return this.text;
  30.     }
  31.  
  32.     public void setText(String text) {
  33.         this.text = text;
  34.     }  
  35.     public Long getId() {
  36.         return this.id;
  37.     }
  38.  
  39.     public void setId(Long id) {
  40.         this.id = id;
  41.     }
  42.    
  43. }
Advertisement
Add Comment
Please, Sign In to add comment