blob: 60993b075dd3c825ccc9ffec22cf1fab1f566823 [file] [log] [blame]
/*
* Copyright (c) 2018, 2020 Oracle and/or its affiliates. All rights reserved.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0,
* or the Eclipse Distribution License v. 1.0 which is available at
* http://www.eclipse.org/org/documents/edl-v10.php.
*
* SPDX-License-Identifier: EPL-2.0 OR BSD-3-Clause
*/
package jpql.query;
import java.io.Serializable;
import jakarta.persistence.Column;
import jakarta.persistence.Entity;
import jakarta.persistence.Id;
import jakarta.persistence.JoinColumn;
import jakarta.persistence.ManyToOne;
import jakarta.persistence.NamedQueries;
import jakarta.persistence.NamedQuery;
@Entity
@NamedQueries
({
@NamedQuery(name="phone.findAll", query="SELECT p FROM Phone p")
})
@SuppressWarnings("unused")
public class Phone implements Serializable {
private String area;
@ManyToOne
@JoinColumn(name = "CUSTOMER_ID")
private Customer customer;
@ManyToOne
@JoinColumn(name = "EMPLOYEE_ID")
private Employee employee;
@Id
@Column(nullable = false)
private Long id;
@Column(name="PHONE_NUMBER")
private String phoneNumber;
private Long type;
}