main
Last change
on this file since 1dd9226 was 1dd9226, checked in by HristijanMitic00 <hristijan.mitic.01@…>, 17 months ago |
Initial commit
|
-
Property mode
set to
100644
|
File size:
736 bytes
|
Rev | Line | |
---|
[1dd9226] | 1 | package model;
|
---|
| 2 |
|
---|
| 3 | import jakarta.persistence.*;
|
---|
| 4 |
|
---|
| 5 | import java.util.Objects;
|
---|
| 6 |
|
---|
| 7 | @Entity
|
---|
| 8 | public class Dostavuvac {
|
---|
| 9 | @GeneratedValue(strategy = GenerationType.IDENTITY)
|
---|
| 10 | @Id
|
---|
| 11 | @Column(name = "id_korisnik")
|
---|
| 12 | private int idKorisnik;
|
---|
| 13 |
|
---|
| 14 | public int getIdKorisnik() {
|
---|
| 15 | return idKorisnik;
|
---|
| 16 | }
|
---|
| 17 |
|
---|
| 18 | public void setIdKorisnik(int idKorisnik) {
|
---|
| 19 | this.idKorisnik = idKorisnik;
|
---|
| 20 | }
|
---|
| 21 |
|
---|
| 22 | @Override
|
---|
| 23 | public boolean equals(Object o) {
|
---|
| 24 | if (this == o) return true;
|
---|
| 25 | if (o == null || getClass() != o.getClass()) return false;
|
---|
| 26 | Dostavuvac that = (Dostavuvac) o;
|
---|
| 27 | return idKorisnik == that.idKorisnik;
|
---|
| 28 | }
|
---|
| 29 |
|
---|
| 30 | @Override
|
---|
| 31 | public int hashCode() {
|
---|
| 32 | return Objects.hash(idKorisnik);
|
---|
| 33 | }
|
---|
| 34 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.