View Javadoc
1   package ejava.examples.orm.core.mapped;
2   
3   import java.io.Serializable;
4   
5   /**
6    * This class provides an example of an object with no identity of its own
7    * and must be stored within a containing object. See the XRay class for
8    * an example of a containing object.
9    */
10  public class Manufacturer implements Serializable {
11      private static final long serialVersionUID = 1L;
12      private String name;
13      private String address;
14      private String phone;
15      
16      public Manufacturer() {}
17      public Manufacturer(String name, String address, String phone) {
18          this.name = name;
19          this.address = address;
20          this.phone=phone;
21      }
22      
23      public String getAddress() { return address; }
24      public void setAddress(String address) {
25          this.address = address;
26      }
27  
28      public String getName() { return name; }
29      public void setName(String name) {
30          this.name = name;
31      }
32  
33      public String getPhone() { return phone; }
34      public void setPhone(String phone) {
35          this.phone = phone;
36      }
37  
38      public String toString() {
39          return super.getClass().getName() +
40              ", name=" + name +
41              ", address=" + address +
42              ", phone=" + phone;        
43      }
44  }