Skip to content

Instantly share code, notes, and snippets.

@m1k3yfoo
Last active September 30, 2018 22:27
Show Gist options
  • Save m1k3yfoo/594929c739d0e01ed4021595d5e2e48d to your computer and use it in GitHub Desktop.
Save m1k3yfoo/594929c739d0e01ed4021595d5e2e48d to your computer and use it in GitHub Desktop.
[Java Spring Boot Entity] #SpringBoot
package com.example.project;
import javax.persistence.Entity;
import javax.persistence.Id;
@Entity
public class Hospital {
public int getId() {
return id;
}
public void setId(int id) {
this.id = id;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getCity() {
return city;
}
public void setCity(String city) {
this.city = city;
}
public double getRating() {
return rating;
}
public void setRating(double rating) {
this.rating = rating;
}
@Id
private int id;
private String name;
private String city;
private double rating;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment