1
|
package vldc.aswi.domain;
|
2
|
|
3
|
import lombok.Data;
|
4
|
import lombok.EqualsAndHashCode;
|
5
|
import lombok.NoArgsConstructor;
|
6
|
import vldc.aswi.domain.parameter.Parameter;
|
7
|
import vldc.aswi.domain.parameter.ParameterInConfiguration;
|
8
|
|
9
|
import javax.persistence.Column;
|
10
|
import javax.persistence.Entity;
|
11
|
import javax.persistence.ManyToMany;
|
12
|
import javax.persistence.OneToMany;
|
13
|
import java.util.List;
|
14
|
|
15
|
/**
|
16
|
* Domain entity representing Operator in application.
|
17
|
*/
|
18
|
@Entity(name = "Operator")
|
19
|
@Data
|
20
|
@EqualsAndHashCode(callSuper = true)
|
21
|
@NoArgsConstructor
|
22
|
public class Operator extends EntityParent {
|
23
|
|
24
|
/** Name of operator. */
|
25
|
@Column(name = "nazev")
|
26
|
private String name;
|
27
|
|
28
|
/** List of parameters which allowing this operator to be used. */
|
29
|
@ManyToMany(mappedBy = "operators")
|
30
|
private List<Parameter> parameters;
|
31
|
|
32
|
/** List of parametersInConfiguration using this operator. */
|
33
|
@OneToMany(mappedBy = "operator")
|
34
|
private List<ParameterInConfiguration> parametersInConfiguration;
|
35
|
|
36
|
/**
|
37
|
* Constructor.
|
38
|
* @param name - Name of operator.
|
39
|
*/
|
40
|
public Operator(String name) {
|
41
|
this.setName(name);
|
42
|
}
|
43
|
|
44
|
@Override
|
45
|
public String toString() {
|
46
|
return "";
|
47
|
}
|
48
|
}
|