package edu.northwestern.bioinformatics.studycalendar.web;

import java.util.Date;

import edu.northwestern.bioinformatics.studycalendar.domain.Participant;

/**
 * @author Padmaja Vedula
 */

public class NewParticipantCommand {
	private String firstName;
    private String lastName;
    private Date dateOfBirth;
    private String gender;
    private String socialSecurityNumber;
	
	public Participant createParticipant() {
		Participant participant = new Participant();
		participant.setFirstName(getFirstName());
		participant.setLastName(getLastName());
		participant.setDateOfBirth(getDateOfBirth());
		participant.setGender(getGender());
		participant.setSocialSecurityNumber(getSocialSecurityNumber());        
        return participant;
    }

	public Date getDateOfBirth() {
		return dateOfBirth;
	}

	public void setDateOfBirth(Date dateOfBirth) {
		this.dateOfBirth = dateOfBirth;
	}

	public String getFirstName() {
		return firstName;
	}

	public void setFirstName(String firstName) {
		this.firstName = firstName;
	}

	public String getGender() {
		return gender;
	}

	public void setGender(String gender) {
		this.gender = gender;
	}

	public String getLastName() {
		return lastName;
	}

	public void setLastName(String lastName) {
		this.lastName = lastName;
	}

	public String getSocialSecurityNumber() {
		return socialSecurityNumber;
	}

	public void setSocialSecurityNumber(String socialSecurityNumber) {
		this.socialSecurityNumber = socialSecurityNumber;
	}

}

@@ -370,39 +370,31 @@
  String 
-socialSecurityNumber;%0D%0A
+personId;%0D%0A    
 %09%0D%0A%09publ
@@ -676,52 +676,28 @@
 .set
-SocialSecurityNumber(getSocialSecurityNumber
+PersonId(getPersonId
 ());
@@ -740,24 +740,27 @@
 ;%0D%0A    %7D%0D%0A%0D%0A
+%09%0D%0A
 %09public Date
@@ -1329,191 +1329,119 @@
  get
-SocialSecurityNumber() %7B%0D%0A%09%09return socialSecurityNumber;%0D%0A%09%7D%0D%0A%0D%0A%09public void setSocialSecurityNumber(String socialSecurityNumber) %7B%0D%0A%09%09this.socialSecurityNumber = socialSecurityNumber
+PersonId() %7B%0D%0A%09%09return personId;%0D%0A%09%7D%0D%0A%0D%0A%09public void setPersonId(String personId) %7B%0D%0A%09%09this.personId = personId
 ;%0D%0A%09

changed social_security_number to person_id