Commit 724258c0 authored by tbilos's avatar tbilos
Browse files

add lombok to mission

parent 28729fad
Pipeline #122222 waiting for manual action with stage
package cz.fi.muni.pa165.seminar4.group7.secretservice.entity; package cz.fi.muni.pa165.seminar4.group7.secretservice.entity;
import com.sun.istack.NotNull; import com.sun.istack.NotNull;
import lombok.Getter;
import lombok.Setter;
import javax.persistence.*; import javax.persistence.*;
import java.sql.Date; import java.sql.Date;
...@@ -14,18 +16,26 @@ public class Mission { ...@@ -14,18 +16,26 @@ public class Mission {
@Id @Id
@Column(name = "id", nullable = false) @Column(name = "id", nullable = false)
@GeneratedValue(strategy = GenerationType.IDENTITY) @GeneratedValue(strategy = GenerationType.IDENTITY)
@Getter
@Setter
private Long id; private Long id;
@NotNull @NotNull
@Column(nullable = false) @Column(nullable = false)
@Getter
@Setter
private Date start; private Date start;
@NotNull @NotNull
@Column(nullable = false) @Column(nullable = false)
@Getter
@Setter
private int duration; private int duration;
@NotNull @NotNull
@Column(nullable = false) @Column(nullable = false)
@Getter
@Setter
private String objective; private String objective;
@OneToMany(mappedBy = "mission") @OneToMany(mappedBy = "mission")
...@@ -35,38 +45,6 @@ public class Mission { ...@@ -35,38 +45,6 @@ public class Mission {
// @ManyToOne ? // @ManyToOne ?
// private Country country; // private Country country;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public Date getStart() {
return start;
}
public void setStart(Date start) {
this.start = start;
}
public int getDuration() {
return duration;
}
public void setDuration(int duration) {
this.duration = duration;
}
public String getObjective() {
return objective;
}
public void setObjective(String objective) {
this.objective = objective;
}
@Override @Override
public boolean equals(Object o) { public boolean equals(Object o) {
if (this == o) return true; if (this == o) return true;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment