Latest Tutorials| Questions and Answers|Ask Questions?|Site Map



Home Hibernate Hibernate4 net.roseindia.model

Related Tutorials


 
 

Share on Google+Share on Google+

net.roseindia.model

Advertisement
This package is the part of the Spring and Hibernate JPA integration application which contains model classes.

net.roseindia.model

This package is the part of the Spring and Hibernate JPA  integration application which contains model classes.

For returning to main example(Spring Jpa Hibernate). Click here.

Article.java

package net.roseindia.model;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

@Entity
@Table(name = "article")
public class Article {

@Id
@GeneratedValue
@Column(name = "article_id")
private Long articleId;

@Column(name = "article_name", nullable = false, length=20)
private String articleName;

@Column(name = "article_desc", nullable = false)
private String articleDesc;

@Column(name = "date_added")
private Date addedDate;

public Article() { 
}

public Long getArticleId() {
return articleId;
}

public void setArticleId(Long articleId) {
this.articleId = articleId;
}

public String getArticleName() {
return articleName;
}

public void setArticleName(String articleName) {
this.articleName = articleName;
}

public String getArticleDesc() {
return articleDesc;
}

public void setArticleDesc(String articleDesc) {
this.articleDesc = articleDesc;
}

public Date getAddedDate() {
return addedDate;
}

public void setAddedDate(Date addedDate) {
this.addedDate = addedDate;
} 
}

 

Advertisements

If you enjoyed this post then why not add us on Google+? Add us to your Circles



Liked it!  Share this Tutorial


Follow us on Twitter, or add us on Facebook or Google Plus to keep you updated with the recent trends of Java and other open source platforms.

Posted on: May 7, 2012

Related Tutorials

Discuss: net.roseindia.model  

Post your Comment


Your Name (*) :
Your Email :
Subject (*):
Your Comment (*):
  Reload Image
 
 
Comments:0
DMCA.com