mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
43 lines
695 B
Java
43 lines
695 B
Java
package org.tests.query.cache;
|
|
|
|
import javax.persistence.Entity;
|
|
import javax.persistence.GeneratedValue;
|
|
import javax.persistence.Id;
|
|
import javax.persistence.ManyToOne;
|
|
|
|
@Entity
|
|
public class Position {
|
|
@Id
|
|
@GeneratedValue
|
|
protected Long id;
|
|
|
|
private String name;
|
|
|
|
@ManyToOne(cascade = {}, optional = false)
|
|
private Contract contract;
|
|
|
|
public Long getId() {
|
|
return id;
|
|
}
|
|
|
|
public void setId(final Long id) {
|
|
this.id = id;
|
|
}
|
|
|
|
public String getName() {
|
|
return name;
|
|
}
|
|
|
|
public void setName(String name) {
|
|
this.name = name;
|
|
}
|
|
|
|
public Contract getContract() {
|
|
return contract;
|
|
}
|
|
|
|
public void setContract(final Contract contract) {
|
|
this.contract = contract;
|
|
}
|
|
}
|