Suggest a feature
×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: Java
Posted by: lolonda dotKlar
Added: Nov 26, 2020 9:59 AM
Views: 21
Tags: no tags
  1. @Embeddable
  2. public class Address implements Serializable {
  3.  
  4.     private static final long serialVersionUID = 1L;
  5.  
  6.     @Basic
  7.     @NotNull
  8.     @Size(min=5, max=100,
  9.         message="The address must contain between {min} and {max} characters")
  10.     private String address;
  11.  
  12.     public String getAddress() {
  13.         return address;
  14.     }
  15.  
  16.     public void setAddress(String adresse) {
  17.         this.address = adresse;
  18.     }
  19. }