Created
April 27, 2018 09:20
-
-
Save klinki/346111b2e879173a38d0a654b42efb95 to your computer and use it in GitHub Desktop.
DTO Entities - public or private with getters and setters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Jedná se o třídu pro REST DTO Mapping. | |
Neobsahuje žádnou logiku, je to čistě jen obálka na data, která lezou na výstupu controllerů jako JSON. | |
(Kdyby Java uměla struktury, tak by to mohla být struktura :) ) | |
V případě, že by nějaká logika přibyla, není problém gettery a settery dopsat. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package cz.profinit.dagensia.tradeportal.backofficegui.rest.dto; | |
/** | |
* @author David Klingenberg | |
*/ | |
public class UserDto { | |
public Long id; | |
public String nickname; | |
public String personName; | |
public String personSurname; | |
public String email; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package cz.profinit.dagensia.tradeportal.backofficegui.rest.dto; | |
/** | |
* @author David Klingenberg | |
*/ | |
public class UserDto { | |
private Long id; | |
private String nickname; | |
private String personName; | |
private String personSurname; | |
private String email; | |
public Long getId() { | |
return id; | |
} | |
public void setId(Long id) { | |
this.id = id; | |
} | |
public String getNickname() { | |
return nickname; | |
} | |
public void setNickname(String nickname) { | |
this.nickname = nickname; | |
} | |
public String getPersonName() { | |
return personName; | |
} | |
public void setPersonName(String personName) { | |
this.personName = personName; | |
} | |
public String getPersonSurname() { | |
return personSurname; | |
} | |
public void setPersonSurname(String personSurname) { | |
this.personSurname = personSurname; | |
} | |
public String getEmail() { | |
return email; | |
} | |
public void setEmail(String email) { | |
this.email = email; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment