import java.util.Date;
import java.util.Random; 
import java.util.Set;

/** Class containing Event object 
Setters for variables that user can change about event
*/
public class Event {
  private final int eventId;
  private String name;
  private String description;
  private Set<String> labels;
  private String location;
  private Date date;
  private Set<VolunteeringOpportunity> opportunities;
  private Set<User> attendees;
  private User host;

  Random rand = new Random(); 

  /** TO DO (MVP): Add Event to Event db*/
  public Event(String name, String description, Set<String> labels, String location, Date date, 
  Set<VolunteeringOpportunity> opportunities, Set<User> attendees, User host) {
    this.eventId = rand.nextInt(1000000); //this will later be a unique number based on the database id
    this.name = name;
    this.description = description;
    this.labels = labels;
    this.location = location;
    this.date = date;
    this.opportunities = opportunities;
    this.attendees = attendees;
    this.host = host;
  }

  /** TO DO (MVP) for all getters: get from Event db*/
  /** TO DO (MVP) for all setters: set in Event db*/
  public int getID() {
    return eventId;
  }

  public String getName() {
    return name;
  }

  public void setName(String newName) {
    this.name = newName;
  }

  public String getDescription() {
    return description;
  }

  public void setDescription(String newDescription) {
    this.description = newDescription;
  }

  public Set<String> getLabels() {
    return labels;
  }

  public void setLabel(String newLabel) {
    labels.add(newLabel);
  }

  public void removeLabel(String deletedLabel) {
    labels.remove(deletedLabel);
  }

  public String getLocation() {
    return location;
  }

  public void setLocation(String newLocation) {
    this.location = newLocation;
  }

  public Date getDate() {
    return date;
  }

  public void setDate(Date newDate) {
    this.date = newDate;
  }

  public Set<VolunteeringOpportunity> getOpportunities() {
    return opportunities;
  }

  public Set<User> getAttendees() {
    return attendees;
  }

  public User getHost() {
    return host;
  }
}
@@ -165,16 +165,22 @@
 %0Apublic 
+final 
 class Ev
@@ -540,26 +540,222 @@
 lic 
-Event(String name,
+static class Builder %7B%0A  //required params%0A    this.eventId = rand.nextInt(1000000); //this will later be a unique number based on the database id%0A    private final int eventId;%0A    private String name;%0A    private
  Str
@@ -769,17 +769,29 @@
 cription
-,
+;%0A    private
  Set%3CStr
@@ -801,17 +801,29 @@
 %3E labels
-,
+;%0A    private
  String 
@@ -834,88 +834,313 @@
 tion
-, Date date, %0A  Set%3CVolunteeringOpportunity%3E opportunities, Set%3CUser%3E attendees,
+;%0A    private Date date;%0A    private User host;%0A    %0A    //optional params%0A    private Set%3CVolunteeringOpportunity%3E opportunities = new HashSet%3C%3E();%0A    private Set%3CUser%3E attendees = new HashSet%3C%3E();%0A%0A    public Builder(String name, String description, Set%3CString%3E labels, String location, Date date, %0A   
  Use
@@ -1145,24 +1145,28 @@
 ser host) %7B%0A
+    
     this.eve
@@ -1253,24 +1253,28 @@
 database id%0A
+    
     this.nam
@@ -1279,24 +1279,28 @@
 ame = name;%0A
+    
     this.des
@@ -1319,24 +1319,28 @@
 escription;%0A
+    
     this.lab
@@ -1349,24 +1349,28 @@
 s = labels;%0A
+    
     this.loc
@@ -1383,24 +1383,28 @@
 = location;%0A
+    
     this.dat
@@ -1421,92 +1421,649 @@
     
+  
+  
 this.
-opportunities = opportunities;%0A    this.attendees = attendees;%0A    this.host = 
+host = host;%0A    %7D%0A%0A    public Builder opportunities(VolunteeringOpportunity opportunity) %7B%0A        opportunities.add(opportunity);%0A        return this;%0A    %7D%0A    public Builder attendees(User attendee) %7B%0A        attendees.add(attendee);%0A        return this;%0A    %7D%0A%0A    public Event build() %7B%0A        return new Event(this);%0A    %7D%0A  %7D%0A%0A  private Event(Builder builder) %7B%0A  eventId = builder.eventId;%0A  name = builder.name;%0A  description = builder.description;%0A  labels = builder.labels;%0A  location = builder.location;%0A  date = builder.date;%0A  opportunities = builder.opportunities;%0A  attendees = builder.attendees;%0A  host = builder.
 host
@@ -2288,214 +2288,46 @@
 lic 
-void setName(String newName) %7B%0A    this.name = newName;%0A  %7D%0A%0A  public String getDescription() %7B%0A    return description;%0A  %7D%0A%0A  public void setDescription(String newDescription) %7B%0A    this.description = newD
+String getDescription() %7B%0A    return d
 escr
@@ -2629,191 +2629,37 @@
 lic 
-void setLocation(String newLocation) %7B%0A    this.location = newLocation;%0A  %7D%0A%0A  public Date getDate() %7B%0A    return date;%0A  %7D%0A%0A  public void setDate(Date newDate) %7B%0A    this.date = newD
+Date getDate() %7B%0A    return d
 ate;

migrate to Builder