/*
 * Copyright (c) 2014 Personal-Health-Monitoring-System
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * 	http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package com.cse3310.phms.model;

import com.activeandroid.annotation.Column;
import com.activeandroid.annotation.Table;

@Table(name = "PersonalInfo")
public class PersonalInfo extends Info{
    public enum Gender {MALE, FEMALE}

    @Column(name = "Gender")
    private String gender;
    @Column(name = "Age")
    private int age;
    @Column(name = "weight")
    private double weight;
    @Column(name = "height")
    private double height;

    public PersonalInfo() {
        super();
    }

    public PersonalInfo(String firstName, String lastName) {
        super(firstName, lastName);
    }

    public Gender getGender() {
        return Gender.valueOf(gender);
    }

    public PersonalInfo setGender(Gender gender) {
        this.gender = gender.toString();
        return this;
    }

    public int getAge() {
        return age;
    }

    public PersonalInfo setAge(int age) {
        this.age = age;
        return this;
    }

    public double getWeight() {
        return weight;
    }

    public PersonalInfo setWeight(double weight) {
        this.weight = weight;
        return this;
    }

    public double getHeight() {
        return height;
    }

    public PersonalInfo setHeight(double height) {
        this.height = height;
        return this;
    }
}

@@ -827,16 +827,17 @@
 Gender %7B
+ 
 MALE, FE
@@ -840,16 +840,17 @@
 , FEMALE
+ 
 %7D%0A%0A    @
@@ -1068,55 +1068,252 @@
     
-public PersonalInfo() %7B%0A        super();%0A    %7D%0A
+/**%0A     * Instantiates a new Personal info.%0A     */%0A    public PersonalInfo() %7B%0A        super();%0A    %7D%0A%0A    /**%0A     * Instantiates a new Personal info.%0A     *%0A     * @param firstName the first name%0A     * @param lastName the last name%0A     */
 %0A   
@@ -1405,32 +1405,101 @@
 stName);%0A    %7D%0A%0A
+    /**%0A     * Gets gender.%0A     *%0A     * @return the gender%0A     */%0A
     public Gende
@@ -1552,32 +1552,142 @@
 gender);%0A    %7D%0A%0A
+    /**%0A     * Sets gender.%0A     *%0A     * @param gender the gender%0A     * @return PersonalInfo object%0A     */%0A
     public Perso
@@ -1798,383 +1798,905 @@
     
-public int getAge() %7B%0A        return age;%0A    %7D%0A%0A    public PersonalInfo setAge(int age) %7B%0A        this.age = age;%0A        return this;%0A    %7D%0A%0A    public double getWeight() %7B%0A        return weight;%0A    %7D%0A%0A    public PersonalInfo setWeight(double weight) %7B%0A        this.weight = weight;%0A        return this;%0A    %7D%0A%0A    public double getHeight() %7B%0A        return height;%0A    %7D%0A
+/**%0A     * Gets age.%0A     *%0A     * @return the age%0A     */%0A    public int getAge() %7B%0A        return age;%0A    %7D%0A%0A    /**%0A     * Sets age.%0A     *%0A     * @param age the age%0A     * @return PersonalInfo object%0A     */%0A    public PersonalInfo setAge(int age) %7B%0A        this.age = age;%0A        return this;%0A    %7D%0A%0A    /**%0A     * Gets weight.%0A     *%0A     * @return the weight%0A     */%0A    public double getWeight() %7B%0A        return weight;%0A    %7D%0A%0A    /**%0A     * Sets weight.%0A     *%0A     * @param weight the weight%0A     * @return PersonalInfo object%0A     */%0A    public PersonalInfo setWeight(double weight) %7B%0A        this.weight = weight;%0A        return this;%0A    %7D%0A%0A    /**%0A     * Gets height.%0A     *%0A     * @return the height%0A     */%0A    public double getHeight() %7B%0A        return height;%0A    %7D%0A%0A    /**%0A     * Sets height.%0A     *%0A     * @param height the height%0A     * @return PersonalInfo object%0A     */
 %0A   

add javadoc