View Javadoc
1   /*
2    * JBoss, Home of Professional Open Source
3    * Copyright 2014, Red Hat, Inc. and/or its affiliates, and individual
4    * contributors by the @authors tag. See the copyright.txt in the
5    * distribution for a full listing of individual contributors.
6    *
7    * Licensed under the Apache License, Version 2.0 (the "License");
8    * you may not use this file except in compliance with the License.
9    * You may obtain a copy of the License at
10   * http://www.apache.org/licenses/LICENSE-2.0
11   * Unless required by applicable law or agreed to in writing, software
12   * distributed under the License is distributed on an "AS IS" BASIS,
13   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14   * See the License for the specific language governing permissions and
15   * limitations under the License.
16   */
17  package org.jboss.as.quickstart.cdi.veto.model;
18  
19  import javax.persistence.Basic;
20  import javax.persistence.Entity;
21  import javax.persistence.GeneratedValue;
22  import javax.persistence.GenerationType;
23  import javax.persistence.Id;
24  
25  /**
26   * Simplistic car JPA model.
27   */
28  @Entity
29  public class Car {
30      @Id @GeneratedValue(strategy = GenerationType.IDENTITY)
31      private Long id;
32  
33      @Basic
34      private String model;
35  
36      @Basic
37      private String make;
38  
39      @Basic
40      private String color;
41  
42      public Long getId() {
43          return id;
44      }
45  
46      public void setId(Long id) {
47          this.id = id;
48      }
49  
50      public String getModel() {
51          return model;
52      }
53  
54      public void setModel(String model) {
55          this.model = model;
56      }
57  
58      public String getMake() {
59          return make;
60      }
61  
62      public void setMake(String make) {
63          this.make = make;
64      }
65  
66      public String getColor() {
67          return color;
68      }
69  
70      public void setColor(String color) {
71          this.color = color;
72      }
73  }