/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package database.patient;

/**
 *
 * @author Emmanuel Promayon, (c) UJF - Polytech'Grenoble - 2011
 */
public class TestPatient {

    public static void main(String[] args) {
        Patient p1 = new Patient();
        p1.nom = "Tracque Pat";
        p1.annéeDeNaissance = 1984;
        
        Adresse a1 = new Adresse();
        a1.rue = "66, rue des lieutemants Thomazo";
        a1.codePostal = "83300";
        a1.ville = "DRAGUIGNAN";
        p1.adresse = a1;
        
        // Affichage des informations p1
        System.out.println("----------------");
        System.out.println("Patient :");
        System.out.println(p1.nom);
        System.out.println("Age :");
        // calcul de l'age...
        int age;
        age = 2011 - p1.annéeDeNaissance;
        // ... et affichage
        System.out.println(age);
        System.out.println("Adresse :");
        System.out.println(p1.adresse.rue);
        System.out.println(p1.adresse.codePostal);
        System.out.println(p1.adresse.ville);
        
        Patient p2 = new Patient();
        p2.nom = "Zeblouze Agathe";
        p2.annéeDeNaissance = 1990;
        
        Adresse a2 = new Adresse();
        a2.rue = "71, rue de Geneve";
        a2.codePostal = "80080";
        a2.ville = "AMIENS";
        
        // --- Complétez ici pour afficher les informations p2
    }

}
