Investor.java
01 package trail.entity.beans;
02 
03 import javax.persistence.*;
04 import java.io.Serializable;
05 
06 @Entity
07 @Table(name = "investor")
08 public class Investor implements Serializable {
09   private int id;
10   private String name;
11   private int startAge;
12   private int endAge;
13 
14   public Investor () { }
15 
16   public Investor (String name, int startAge, int endAge) {
17     this.name = name;
18     this.startAge = startAge;
19     this.endAge = endAge;
20   }
21 
22   @Id
23   @GeneratedValue
24   public int getId () {
25     return id;
26   }
27 
28   public void setId (int id) {
29     this.id = id;
30   }
31 
32   public String getName () {
33     return name;
34   }
35 
36   public void setName (String name) {
37     this.name = name;
38   }
39 
40   public int getStartAge () {
41     return startAge;
42   }
43   public void setStartAge (int startAge) {
44     this.startAge = startAge;
45   }
46 
47   public int getEndAge () {
48     return endAge;
49   }
50   public void setEndAge (int endAge) {
51     this.endAge = endAge;
52   }
53 
54 }