16.10.2015 Views

Getting Started with WebSphere Application Server

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

102 <strong>Getting</strong> <strong>Started</strong> <strong>with</strong> <strong>WebSphere</strong> <strong>Application</strong> <strong>Server</strong> Community Edition<br />

Figure 5.6 – Create an entity in JPA project<br />

package com.ibm.start.wasce.student;<br />

……<br />

@Entity<br />

@Table(name="Student")<br />

public class Student implements Serializable {<br />

@Id<br />

private int id;<br />

private int score1;<br />

private int score2;<br />

private int score3;<br />

private int credit;<br />

private static final long serialVersionUID = 1L;<br />

public Student(){<br />

super();<br />

}

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!