Last change
on this file was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago |
initial commit
|
-
Property mode
set to
100644
|
File size:
627 bytes
|
Line | |
---|
1 | package finki.diplomska.tripplanner.models;
|
---|
2 |
|
---|
3 | import com.fasterxml.jackson.annotation.JsonIgnore;
|
---|
4 | import lombok.AllArgsConstructor;
|
---|
5 | import lombok.Getter;
|
---|
6 | import lombok.NoArgsConstructor;
|
---|
7 | import lombok.Setter;
|
---|
8 |
|
---|
9 | import javax.persistence.*;
|
---|
10 | import java.util.List;
|
---|
11 |
|
---|
12 | @Entity
|
---|
13 | @Table(name = "companions")
|
---|
14 | @NoArgsConstructor
|
---|
15 | @AllArgsConstructor
|
---|
16 | @Getter
|
---|
17 | @Setter
|
---|
18 | public class Companion {
|
---|
19 | @Id
|
---|
20 | @GeneratedValue(strategy = GenerationType.IDENTITY)
|
---|
21 | @Column(name = "id_companion")
|
---|
22 | private Long id;
|
---|
23 |
|
---|
24 | private String type;
|
---|
25 |
|
---|
26 | @ManyToMany(mappedBy = "companionList")
|
---|
27 | @JsonIgnore
|
---|
28 | private List<Location> locationList;
|
---|
29 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.