Event.java 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. package models;
  2. import java.util.Date;
  3. import javax.persistence.Entity;
  4. import javax.persistence.Id;
  5. import javax.persistence.GeneratedValue;
  6. import javax.persistence.GenerationType;
  7. @Entity
  8. public class Event
  9. {
  10. @Id
  11. @GeneratedValue(strategy=GenerationType.IDENTITY)
  12. private long eventId;
  13. private long userId;
  14. private Date time;
  15. private String name;
  16. private String place;
  17. private String foodType;
  18. private String description;
  19. private double lat;
  20. private double lng;
  21. public void setEventId(long id)
  22. {
  23. eventId = id;
  24. }
  25. public long getEventId()
  26. {
  27. return eventId;
  28. }
  29. public void setUserId(long id)
  30. {
  31. userId = id;
  32. }
  33. public long getUserId()
  34. {
  35. return userId;
  36. }
  37. public Date getTime() {
  38. return time;
  39. }
  40. public void setTime(Date time) {
  41. this.time = time;
  42. }
  43. public String getName() {
  44. return name;
  45. }
  46. public void setName(String name) {
  47. this.name = name;
  48. }
  49. public String getPlace() {
  50. return place;
  51. }
  52. public void setPlace(String place) {
  53. this.place = place;
  54. }
  55. public String getFoodType() {
  56. return foodType;
  57. }
  58. public void setFoodType(String foodType) {
  59. this.foodType = foodType;
  60. }
  61. public String getDescription() {
  62. return description;
  63. }
  64. public void setDescription(String description) {
  65. this.description = description;
  66. }
  67. public double getLat() {
  68. return lat;
  69. }
  70. public void setLat(double lat) {
  71. this.lat = lat;
  72. }
  73. public double getLng() {
  74. return lng;
  75. }
  76. public void setLng(double lng) {
  77. this.lng = lng;
  78. }
  79. }