88 lines
2.3 KiB
Java
88 lines
2.3 KiB
Java
package com.example.vpr_javafx;
|
|
|
|
/**
|
|
* User class creates User Objects
|
|
*
|
|
* @author Madeleine Vigier
|
|
* @version 1.2
|
|
*/
|
|
public class User {
|
|
private String nameParent1;
|
|
private String nameParent2;
|
|
private String billAddress;
|
|
private String phoneNumber;
|
|
private String nameChildren;
|
|
private String password;
|
|
|
|
/**
|
|
* constructor
|
|
*
|
|
* @param nameParent1 name of the first parent of the child
|
|
* @param nameParent2 name of the second parent of the child
|
|
* @param billAddress the address the bill should be sent to
|
|
* @param phoneNumber phonenumber of one of the parents and also the username
|
|
* @param nameChildren name of the children
|
|
* @param password password of the user
|
|
* @author Madeleine Vigier
|
|
*/
|
|
public User(String nameParent1, String nameParent2, String billAddress, String phoneNumber, String nameChildren, String password) {
|
|
this.nameParent1 = nameParent1;
|
|
this.nameParent2 = nameParent2;
|
|
this.billAddress = billAddress;
|
|
this.phoneNumber = phoneNumber;
|
|
this.nameChildren = nameChildren;
|
|
this.password = password;
|
|
}
|
|
|
|
/**
|
|
* the method getPhonenumber() gets the Phonenumber
|
|
*
|
|
* @return Phonenumber
|
|
* @author Madeleine Vigier
|
|
*/
|
|
public String getPhonenumber() {
|
|
return phoneNumber;
|
|
}
|
|
|
|
/**
|
|
* the method getPassword() gets the password
|
|
*
|
|
* @return password
|
|
* @author Madeleine Vigier
|
|
*/
|
|
public String getPassword() {
|
|
return password;
|
|
}
|
|
|
|
/**
|
|
* the method getNameParent1() gets nameParent1
|
|
*
|
|
* @return nameParent1
|
|
* @author Madeleine Vigier
|
|
*/
|
|
public String getNameParent1() {
|
|
return nameParent1;
|
|
}
|
|
|
|
/**
|
|
* the method getNameParent2() gets nameParent2
|
|
*
|
|
* @return nameParent2
|
|
* @author Madeleine Vigier
|
|
*/
|
|
public String getNameParent2() {
|
|
return nameParent2;
|
|
}
|
|
|
|
/**
|
|
* the methode toString() returns a String representation of an object
|
|
*
|
|
* @return a String with nameParent1, nameparent2, billAdress, phonenumber, nameChildren, password
|
|
* @author Madeleine Vigier
|
|
*/
|
|
@Override
|
|
public String toString() {
|
|
return nameParent1 + ";" + nameParent2 + ";" + billAddress + ";" + phoneNumber + ";" + nameChildren + ";" + password;
|
|
}
|
|
}
|