@Override
    public void run() {
        gareDepart.getEspaceQuai().entrerVoie(this);
        System.out.println(""+getNomTrain()+" : arrive en gare.");
        try {
            Thread.sleep(TEMPS_ARRET_TRAIN*1000);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        gareDepart.getEspaceQuai().quitterVoie(this);
        System.out.println(""+getNomTrain()+" a quitté la gare.");

        try {
            Thread.sleep(TEMPS_TRAJET);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }


        gareArrivee.getEspaceQuai().entrerVoie(this);;
        System.out.println(""+getNomTrain()+" : arrive en gare.");
        try {
            Thread.sleep(TEMPS_ARRET_TRAIN*1000);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        gareArrivee.getEspaceQuai().quitterVoie(this);
    }