@@ -0,0 +1,1263 @@
+package com.github.piotr_rusin.yule.entity;%0A%0Aimport java.util.Date;%0Aimport javax.persistence.Column;%0Aimport javax.persistence.Entity;%0Aimport javax.persistence.GeneratedValue;%0Aimport javax.persistence.GenerationType;%0Aimport javax.persistence.Id;%0Aimport javax.persistence.PrePersist;%0Aimport javax.persistence.Table;%0A%0A/**%0A * A class representing blog posts.%0A * %0A * @author Piotr Rusin %3Cpiotr.rusin88@gmail.com%3E%0A */%0A@Entity%0A@Table(name=%22Post%22)%0Apublic class Post %7B%0A%09@Id%0A%09@Column(name=%22id%22)%0A%09@GeneratedValue(strategy=GenerationType.IDENTITY)%0A%09private int id;%0A%0A%09private String title;%0A%0A%09private String slug;%0A%0A%09private String content;%0A%0A%09@Column(name=%22creation_date%22)%0A%09private Date creationDate;%0A%0A%09public int getId() %7B%0A%09%09return id;%0A%09%7D%0A%0A%09public void setId(int id) %7B%0A%09%09this.id = id;%0A%09%7D%0A%0A%09public String getTitle() %7B%0A%09%09return title;%0A%09%7D%0A%0A%09public void setTitle(String title) %7B%0A%09%09this.title = title;%0A%09%7D%0A%0A%09public String getSlug() %7B%0A%09%09return slug;%0A%09%7D%0A%0A%09public void setSlug(String slug) %7B%0A%09%09this.slug = slug;%0A%09%7D%0A%0A%09public String getContent() %7B%0A%09%09return content;%0A%09%7D%0A%0A%09public void setContent(String content) %7B%0A%09%09this.content = content;%0A%09%7D%0A%0A%09public Date getCreationDate() %7B%0A%09%09return creationDate;%0A%09%7D%0A%0A%09@PrePersist%0A%09protected void resetCreationDate() %7B%0A%09%09creationDate = new Date();%0A%09%7D%0A%0A%7D%0A

Add Post entity class