private void doParcourir() {
    JFileChooser fileChooser = new JFileChooser(".");
    fileChooser.setDialogTitle(Bundle.getText("BD_ImporterProcessus_parcourir"));
    fileChooser.setFileSelectionMode(JFileChooser.FILES_AND_DIRECTORIES);
    fileChooser.setAcceptAllFileFilterUsed(false);
    fileChooser.setFileFilter(new FiltreFichier("dpe", Bundle.getText("DPE")));
    int res = fileChooser.showDialog(this, Bundle.getText("Valider"));
    if (res == JFileChooser.APPROVE_OPTION) {
      // Vérification si le chemin contient le nom du fichier
      nomDuFichier = null;
      if (fileChooser.getSelectedFile().isFile()) {
        cImportation.addChemin(
            fileChooser
                .getSelectedFile()
                .getAbsolutePath()
                .substring(
                    0,
                    fileChooser.getSelectedFile().getAbsolutePath().lastIndexOf(File.separator)));
        LD_Chemin.setSelectedItem(
            fileChooser
                .getSelectedFile()
                .getAbsolutePath()
                .substring(
                    0,
                    fileChooser.getSelectedFile().getAbsolutePath().lastIndexOf(File.separator)));
        nomDuFichier = fileChooser.getSelectedFile().getName();
      } else {
        cImportation.addChemin(fileChooser.getSelectedFile().getAbsolutePath());
        LD_Chemin.setSelectedItem(fileChooser.getSelectedFile().getAbsolutePath());
      }
    }

    doRechercher();
  }
Пример #2
0
 public void updateTexte() {
   this.MD_Fichier.setText(Bundle.getText("MENU_Fichier"));
   this.MD_Aide.setText(Bundle.getText("MENU_Aide"));
   this.MD_Preferences.setText(Bundle.getText("MENU_Preferences"));
   this.MD_Langue.setText(Bundle.getText("MENU_Langue"));
   this.MD_Laf.setText(Bundle.getText("MENU_Laf"));
   chargerLangue();
   chargerLaf();
 }
 private void doAnnuler() {
   if (!importationComplete) {
     if (JOptionPane.showConfirmDialog(
             this,
             Bundle.getText("BD_ImporterProcessus_UtilisationDPE"),
             Bundle.getText("Question"),
             JOptionPane.YES_NO_OPTION,
             JOptionPane.QUESTION_MESSAGE)
         == JOptionPane.YES_OPTION) dispose();
   } else dispose();
 }
 public void operationSurComposants() {
   // Liste des fichiers
   STC_Fichiers.setText(Bundle.getText("BD_ImporterProcessus_liste"));
   // Parcourir
   BP_Parcourir.setMnemonic(Bundle.getChar("parcourir_mne"));
   BP_Parcourir.setText(Bundle.getText("parcourir"));
   BP_Parcourir.addActionListener(actionParcourir);
   // Chemin
   STC_Chemin.setText(Bundle.getText("BD_ImporterProcessus_chemin"));
   LD_Chemin.setPreferredSize(new Dimension(350, 24));
   LD_Chemin.setEditable(true);
   LD_Chemin.addActionListener(actionRechercher);
   // Rechercher
   BP_Rechercher.setText(Bundle.getText("BD_ImporterProcessus_rechercher"));
   BP_Rechercher.addActionListener(actionRechercher);
 }
 public BD_ImporterProcessus(JDialog parent, boolean importationComplete) {
   // Association au parent
   super(parent, Bundle.getText("BD_ImporterProcessus_caption"), true);
   if (!importationComplete) setTitle(Bundle.getText("BD_ImporterProcessus_caption2"));
   this.importationComplete = importationComplete;
   // Création des éléments
   creationElements();
   // Mise à jour des textes
   updateTexte();
   // Appels de l'interface
   operationSurBoutons();
   operationSurComposants();
   operationSurPanel();
   operationSurFenetre();
   operationMoteur();
 }
 private void doRechercher() {
   String lAdresse = (String) LD_Chemin.getSelectedItem();
   if (lAdresse != null)
     if (!lAdresse.equals("")) {
       cImportation.addChemin(lAdresse);
       File leChemin = new File((String) LD_Chemin.getSelectedItem());
       cImportation.effacerListeFichiers();
       try {
         if (leChemin.isDirectory()) {
           // récupération de la liste des fichiers
           cImportation.getListeFichiersLocal("dpe", lAdresse, "", "");
           cImportation.getListeFichiersLocal("DPE", lAdresse, "", "");
         } else {
           // récupération de la liste des fichiers
           try {
             cImportation.getListeFichiers(
                 "dpe", lAdresse, cImportation.getLogin(lAdresse), cImportation.getPWD(lAdresse));
             cImportation.getListeFichiers(
                 "DPE", lAdresse, cImportation.getLogin(lAdresse), cImportation.getPWD(lAdresse));
           } catch (LoginFTPException e) {
             new BD_LoginPwd(this, lAdresse, "DPE").setVisible(true);
             cImportation.getListeFichiers(
                 "dpe", lAdresse, cImportation.getLogin(lAdresse), cImportation.getPWD(lAdresse));
             cImportation.getListeFichiers(
                 "DPE", lAdresse, cImportation.getLogin(lAdresse), cImportation.getPWD(lAdresse));
           }
         }
       } catch (ConnexionException e2) {
         JOptionPane.showMessageDialog(
             this,
             Bundle.getText("problemeFTP"),
             Bundle.getText("Erreur"),
             JOptionPane.ERROR_MESSAGE);
       } catch (Exception e3) {
         JOptionPane.showMessageDialog(
             this,
             Bundle.getText("problemeConnexion"),
             Bundle.getText("Erreur"),
             JOptionPane.ERROR_MESSAGE);
       }
     }
   if (nomDuFichier != null)
     LS_Fichiers.setSelectedIndex(cImportation.getModeleFichiers().getIndexOf(nomDuFichier));
   nomDuFichier = null;
 }
Пример #7
0
  /** Methode permettant de créer les éléments du menu et de les ajouter */
  private void createMenuBar() {

    // File menu
    this.MD_Fichier = new JMenu();
    this.OM_Quitter = new JMenuItem(fenetrePrincipale.quitterAction);
    this.OM_ImporterProcessus = new JMenuItem(fenetrePrincipale.importerProcessusAction);
    this.OM_ImporterMesures = new JMenuItem(fenetrePrincipale.importerMesuresAction);
    this.OM_Comp_Proc = new JMenuItem(fenetrePrincipale.afficherProcessusComposantsAction);
    this.OM_DescriptionMaturite = new JMenuItem(fenetrePrincipale.associerDescriptionsAction);
    this.add(this.MD_Fichier);
    this.MD_Fichier.add(this.OM_ImporterProcessus);
    this.MD_Fichier.add(this.OM_ImporterMesures);
    this.MD_Fichier.addSeparator();
    this.MD_Fichier.add(this.OM_DescriptionMaturite);
    this.MD_Fichier.add(this.OM_Comp_Proc);
    this.MD_Fichier.addSeparator();
    this.MD_Fichier.add(this.OM_Quitter);

    // Preferences menu
    this.MD_Preferences = new JMenu();
    // this.OM_Configuration = new JMenuItem(fenetrePrincipale.configurationAction);
    this.MD_Langue = new JMenu();
    this.MD_Laf = new JMenu();
    this.OM_GestionUtilisateur = new JMenuItem(fenetrePrincipale.gestionUtilisateurAction);
    this.OM_MotDePasse = new JMenuItem(fenetrePrincipale.motDePasseAction);

    this.add(this.MD_Preferences);
    // this.MD_Preferences.add(this.OM_Configuration);
    this.MD_Preferences.add(this.OM_GestionUtilisateur);
    this.MD_Preferences.add(this.MD_Langue);
    this.MD_Preferences.add(this.MD_Laf);
    this.MD_Preferences.add(this.OM_MotDePasse);

    // Help menu
    this.MD_Aide = new JMenu();
    this.OM_APropos = new JMenuItem(fenetrePrincipale.aProposAction);

    this.add(this.MD_Aide);
    this.MD_Aide.add(this.OM_APropos);

    // Adds tooltip texts
    this.MD_Fichier.setText(Bundle.getText("MENU_Fichier"));
    this.MD_Aide.setText(Bundle.getText("MENU_Aide"));
    this.MD_Preferences.setText(Bundle.getText("MENU_Preferences"));
  } // End of createMenuBar method
Пример #8
0
 public void chargerLangue() {
   MD_Langue.removeAll();
   // Groupe
   SC_Radios = new ButtonGroup();
   // Radios langue
   for (int i = 0; i < Bundle.getLanguesDisponibles().size(); i++) {
     // Récupération de la première des langues disponibles
     String langue = Bundle.getLanguesDisponibles().elementAt(i).toString();
     // Récupération de la langue courante
     String langueCourante = Bundle.getLangueCourante();
     // Création d'un bouton radio
     JRadioButtonMenuItem OO_Langue = new JRadioButtonMenuItem(langue);
     // Ajout au groupe
     SC_Radios.add(OO_Langue);
     // Ajout du listener
     OO_Langue.addActionListener(actionLangue);
     // Si la langue courante correspond à l'élément
     if (langueCourante.equals(langue)) OO_Langue.setSelected(true);
     // Ajout au panel
     MD_Langue.add(OO_Langue);
   }
 }
Пример #9
0
  /** Récupération du fichier en local */
  public void uploaderFichier(String fichier, String chemin)
      throws ConnexionException, FileNotFoundException, IOException, EnvoyerFichierException {
    leModeleTelechargement.addDonnees(Bundle.getText("C_Exportation_connexion_serveur"));
    C_Local ftp = new C_Local();

    ftp.seConnecter(chemin);
    leModeleTelechargement.addDonnees(Bundle.getText("C_Exportation_connexion_etablie"));
    leModeleTelechargement.addDonnees(Bundle.getText("C_Exportation_creation_fichier"));

    creerFichierHTMLMesureRepresentation(fichier);

    leModeleTelechargement.addDonnees(Bundle.getText("C_Exportation_creation_fichier_termine"));
    leModeleTelechargement.addDonnees(Bundle.getText("C_Exportation_transfert_fichier"));
    leModeleTelechargement.addDonnees(Bundle.getText("C_Exportation_debut_transfert"));
    ftp.envoyerFichier("temp" + File.separator + fichier);
    if (!nomFichierCSS.equals("")) ftp.envoyerFichier("temp" + File.separator + nomFichierCSS);
    leModeleTelechargement.addDonnees(Bundle.getText("C_Exportation_fichier_transfere"));
    supprimerFichierHTMLMesureRepresentation(fichier);
    leModeleTelechargement.addDonnees(Bundle.getText("C_Exportation_deconnexion"));
  }
 public void operationSurBoutons() {
   // Annuler
   if (!importationComplete) {
     BP_Annuler.setMnemonic(Bundle.getChar("BD_ImporterProcessus_UtiliserCourant_mne"));
     BP_Annuler.setText(Bundle.getText("BD_ImporterProcessus_UtiliserCourant"));
   } else {
     BP_Annuler.setMnemonic(Bundle.getChar("Fermer_mne"));
     BP_Annuler.setText(Bundle.getText("Fermer"));
   }
   BP_Annuler.addActionListener(actionAnnuler);
   // Fermer
   if (!importationComplete) {
     BP_Fermer.setMnemonic(Bundle.getChar("Annuler_mne"));
     BP_Fermer.setText(Bundle.getText("Annuler"));
     BP_Fermer.addActionListener(actionFermer);
   }
   // Importer
   BP_Importer.setMnemonic(Bundle.getChar("Importer_mne"));
   BP_Importer.setText(Bundle.getText("Importer"));
   BP_Importer.addActionListener(actionImporter);
 }
  private void doImporter() {
    final String lAdresse = (String) LD_Chemin.getSelectedItem();
    cImportation.addChemin(lAdresse);
    cImportation.sauvegarderSelectionChemin(lAdresse);

    // Récupération des fichiers sélectionnés
    final Object lesFichiers[] = LS_Fichiers.getSelectedValues();

    // Création de la fenêtre de téléchargement
    final BM_Telechargement bmTelechargement =
        new BM_Telechargement(this, Bundle.getText("BD_ImporterProcessus_encours"), cImportation);

    try {
      final BD_LoginPwd leLogin = new BD_LoginPwd(this, lAdresse, "DPE");

      // Préparation du traitement
      Thread leTraitement =
          new Thread() {
            public void run() {
              ArrayList idProcMAJ = null;

              for (int i = 0; i < lesFichiers.length; i++) {
                // Importation
                File leChemin = new File(lAdresse);
                try {
                  if (leChemin.isDirectory()) {
                    if (importationComplete)
                      idProcMAJ = cImportation.chargerFichier(lesFichiers[i].toString(), lAdresse);
                    else cImportation.memoriserFichier(lesFichiers[i].toString(), lAdresse);
                  } else {
                    try {
                      if (importationComplete)
                        idProcMAJ =
                            cImportation.chargerFichier(
                                lesFichiers[i].toString(),
                                lAdresse,
                                C_Utilisateur.findServeurDPE(lAdresse).getLogin(),
                                C_Utilisateur.findServeurDPE(lAdresse).getMotDePasse());
                      else
                        cImportation.memoriserFichier(
                            lesFichiers[i].toString(),
                            lAdresse,
                            C_Utilisateur.findServeurDPE(lAdresse).getLogin(),
                            C_Utilisateur.findServeurDPE(lAdresse).getMotDePasse());
                    } catch (LoginFTPException e) {
                      leLogin.setVisible(true);
                      if (importationComplete)
                        idProcMAJ =
                            cImportation.chargerFichier(
                                lesFichiers[i].toString(),
                                (String) LD_Chemin.getSelectedItem(),
                                C_Utilisateur.findServeurDPE(lAdresse).getLogin(),
                                C_Utilisateur.findServeurDPE(lAdresse).getMotDePasse());
                      else
                        cImportation.memoriserFichier(
                            lesFichiers[i].toString(),
                            (String) LD_Chemin.getSelectedItem(),
                            C_Utilisateur.findServeurDPE(lAdresse).getLogin(),
                            C_Utilisateur.findServeurDPE(lAdresse).getMotDePasse());
                    }
                  }

                  if (idProcMAJ != null) {
                    if (((String) idProcMAJ.get(1)) != null) {
                      // Choix de la version du processus
                      String numeroVersion = null;
                      while (numeroVersion == null || numeroVersion.equals(""))
                        numeroVersion =
                            JOptionPane.showInputDialog(
                                bmTelechargement,
                                Bundle.getText("BD_ImporterProcessus_versionMessage")
                                    + " \""
                                    + C_Processus.getProcessus((String) idProcMAJ.get(1))
                                        .getNomSansVersion()
                                    + "\" :",
                                Bundle.getText("BD_ImporterProcessus_versionCaption"),
                                JOptionPane.QUESTION_MESSAGE);
                      String dateExport =
                          C_Processus.getProcessus((String) idProcMAJ.get(1)).getDateExport();
                      C_Processus.enregistrerVersionProcessus(
                          (String) idProcMAJ.get(1), dateExport, numeroVersion);
                      C_Processus.getProcessus((String) idProcMAJ.get(1))
                          .setnumeroVersion(dateExport, numeroVersion);

                      try {
                        new BD_MesureVersion(bmTelechargement, (String) idProcMAJ.get(1));
                      } catch (StopActionException e) {
                      }
                    }
                  }

                  if (idProcMAJ != null) {
                    if (((Boolean) idProcMAJ.get(0)).booleanValue()) {
                      JOptionPane.showMessageDialog(
                          bmTelechargement,
                          Bundle.getText("BD_ImporterProcessus_MajModifsVersionProcessus1")
                              + C_Processus.getProcessus((String) idProcMAJ.get(1))
                                  .getNomSansVersion()
                              + Bundle.getText("BD_ImporterProcessus_MajModifsVersionProcessus2")
                              + C_Processus.getProcessus((String) idProcMAJ.get(1))
                                  .getDateExportFormatee()
                              + Bundle.getText("BD_ImporterProcessus_MajModifsVersionProcessus3"),
                          Bundle.getText("BD_ImporterProcessus_ProcessusMisAJour"),
                          JOptionPane.INFORMATION_MESSAGE);
                      new BD_HistoriqueModifications(bmTelechargement, (String) idProcMAJ.get(1));
                      try {
                        new BD_MesureAmelioration(
                                bmTelechargement, (String) idProcMAJ.get(1), false)
                            .setVisible(true);
                      } catch (NiveauInsuffisantException e) {
                      }
                    }
                  }
                } catch (ConnexionException e2) {
                  JOptionPane.showMessageDialog(
                      bmTelechargement,
                      Bundle.getText("problemeFTP"),
                      Bundle.getText("Erreur"),
                      JOptionPane.ERROR_MESSAGE);
                } catch (SAXException saxe) {
                  JOptionPane.showMessageDialog(
                      bmTelechargement,
                      saxe.getMessage(),
                      Bundle.getText("Erreur"),
                      JOptionPane.ERROR_MESSAGE);
                } catch (RecupererFichierException rfe) {
                  JOptionPane.showMessageDialog(
                      bmTelechargement,
                      Bundle.getText("problemeConnexion"),
                      Bundle.getText("Erreur"),
                      JOptionPane.ERROR_MESSAGE);
                } catch (LoginFTPException lfe) {
                  JOptionPane.showMessageDialog(
                      bmTelechargement,
                      Bundle.getText("problemeConnexion"),
                      Bundle.getText("Erreur"),
                      JOptionPane.ERROR_MESSAGE);
                } catch (Exception e) {
                  JOptionPane.showMessageDialog(
                      bmTelechargement,
                      Bundle.getText("BD_ImporterProcessus_ProcessusDejaAffecte"),
                      Bundle.getText("Erreur"),
                      JOptionPane.ERROR_MESSAGE);
                }
              }
              // Attente de terminaison
              bmTelechargement.dispose();
            }
          };

      // Nommage du thread
      leTraitement.setName("ImportationProcessus");
      // Démarrage
      leTraitement.start();
      // Affichage
      bmTelechargement.setVisible(true);
      // Message d'avertissement pour la conservation du dpe
      if (importationComplete)
        JOptionPane.showMessageDialog(
            this,
            Bundle.getText("BD_ImporterProcessus_ConservationDPE"),
            Bundle.getText("Attention"),
            JOptionPane.INFORMATION_MESSAGE);

    } catch (SQLException sqle) {
      JOptionPane.showMessageDialog(
          this, Bundle.getText("problemeBD"), Bundle.getText("Erreur"), JOptionPane.ERROR_MESSAGE);
    }

    // Femeture de la fenêtre
    bmTelechargement.dispose();
    dispose();
  }
Пример #12
0
  /** Création du fichier */
  private void creerFichierHTMLMesureRepresentation(String nomFichierExport)
      throws FileNotFoundException, IOException {
    // Création du répertoire temposaire
    File repTemp = new File("temp" + File.separator);
    if (!repTemp.isDirectory()) repTemp.mkdir();

    File fichExp = new File(nomFichierExport);
    E_Processus leProcessus = C_Processus.getProcessus(idProcessus);
    FileWriter fichierExport = new FileWriter("temp" + File.separator + fichExp);
    SimpleDateFormat sfDate = new SimpleDateFormat(Bundle.DATE_MODEL);
    SimpleDateFormat sfMois = new SimpleDateFormat(Bundle.MOIS_MODEL);

    fichierExport.write(
        "<html lang=\"fr\">\n<head>\n<meta content=\"text/html; charset=ISO-8859-1\" http-equiv=\"content-type\">\n<meta name=\"GENERATOR\" content=\"HAPI\">\n");
    fichierExport.write(
        "<title>"
            + Bundle.getText("BD_GenererHTML_TitrePage")
            + leProcessus.getNomSansVersion()
            + "</title>\n</head>\n<body>\n");
    if (!nomFichierCSS.equals(""))
      fichierExport.write(
          "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + nomFichierCSS + "\">\n");
    fichierExport.write(
        "<h2>"
            + Bundle.getText("BD_GenererHTML_PremiereLigne")
            + leProcessus.getNomSansVersion()
            + "</h2>\n");
    fichierExport.write(
        "<h4 class=PILOTEPROCESSUS>Pilote du processus : &nbsp;"
            + leProcessus.getNomAuteur()
            + "</h4>\n");

    // ---------------------Niveaux de maturite

    fichierExport.write(
        "<h4 class=TITRETABLE>"
            + Bundle.getText("BD_AssocierDescriptionMaturite_NiveauMaturite")
            + "</h4>\n");
    fichierExport.write("<table border=\"1\" cellpadding=\"2\" cellspacing=\"2\">\n");
    fichierExport.write("  <tbody>\n");
    fichierExport.write("    <tr>\n");
    fichierExport.write(
        "      <td "
            + (leProcessus.getNiveauMaturite() == 1
                ? "class=NIVEAUENCOURS"
                : "class=PREMIERELIGNETABLE")
            + ">1</td>\n");
    fichierExport.write(
        "      <td "
            + (leProcessus.getNiveauMaturite() == 2
                ? "class=NIVEAUENCOURS"
                : "class=PREMIERELIGNETABLE")
            + ">2</td>\n");
    fichierExport.write(
        "      <td "
            + (leProcessus.getNiveauMaturite() == 3
                ? "class=NIVEAUENCOURS"
                : "class=PREMIERELIGNETABLE")
            + ">3</td>\n");
    fichierExport.write(
        "      <td "
            + (leProcessus.getNiveauMaturite() == 4
                ? "class=NIVEAUENCOURS"
                : "class=PREMIERELIGNETABLE")
            + ">4</td>\n");
    fichierExport.write(
        "      <td "
            + (leProcessus.getNiveauMaturite() == 5
                ? "class=NIVEAUENCOURS"
                : "class=PREMIERELIGNETABLE")
            + ">5</td>\n");
    fichierExport.write("    </tr>\n");
    fichierExport.write("    <tr>\n");
    fichierExport.write(
        "      <td "
            + (leProcessus.getNiveauMaturite() == 1 ? "class=NIVEAUENCOURS" : "")
            + ">"
            + C_NiveauMaturite.getNiveauMaturite(idProcessus, 0).getDatePassageFormateeHTML()
            + "</td>\n");
    fichierExport.write(
        "      <td "
            + (leProcessus.getNiveauMaturite() == 2 ? "class=NIVEAUENCOURS" : "")
            + ">"
            + (C_NiveauMaturite.getNiveauMaturite(idProcessus, 1)
                    .getDatePassageFormateeHTML()
                    .equals("&nbsp;")
                ? C_NiveauMaturite.getNiveauMaturite(idProcessus, 0).getDateObjectifFormateeHTML()
                : C_NiveauMaturite.getNiveauMaturite(idProcessus, 1).getDatePassageFormateeHTML())
            + "</td>\n");
    fichierExport.write(
        "      <td "
            + (leProcessus.getNiveauMaturite() == 3 ? "class=NIVEAUENCOURS" : "")
            + ">"
            + (C_NiveauMaturite.getNiveauMaturite(idProcessus, 2)
                    .getDatePassageFormateeHTML()
                    .equals("&nbsp;")
                ? C_NiveauMaturite.getNiveauMaturite(idProcessus, 1).getDateObjectifFormateeHTML()
                : C_NiveauMaturite.getNiveauMaturite(idProcessus, 2).getDatePassageFormateeHTML())
            + "</td>\n");
    fichierExport.write(
        "      <td "
            + (leProcessus.getNiveauMaturite() == 4 ? "class=NIVEAUENCOURS" : "")
            + ">"
            + (C_NiveauMaturite.getNiveauMaturite(idProcessus, 3)
                    .getDatePassageFormateeHTML()
                    .equals("&nbsp;")
                ? C_NiveauMaturite.getNiveauMaturite(idProcessus, 2).getDateObjectifFormateeHTML()
                : C_NiveauMaturite.getNiveauMaturite(idProcessus, 3).getDatePassageFormateeHTML())
            + "</td>\n");
    fichierExport.write(
        "      <td "
            + (leProcessus.getNiveauMaturite() == 5 ? "class=NIVEAUENCOURS" : "")
            + ">"
            + (C_NiveauMaturite.getNiveauMaturite(idProcessus, 4)
                    .getDatePassageFormateeHTML()
                    .equals("&nbsp;")
                ? C_NiveauMaturite.getNiveauMaturite(idProcessus, 3).getDateObjectifFormateeHTML()
                : C_NiveauMaturite.getNiveauMaturite(idProcessus, 4).getDatePassageFormateeHTML())
            + "</td>\n");
    fichierExport.write("    </tr>\n");
    fichierExport.write("  </tbody>\n");
    fichierExport.write("</table>\n");
    fichierExport.write(
        "<div class=SOUSTABLE>" + Bundle.getText("OO_MaturiteProcessus_infoHTML") + "</div>\n");

    // ---------------------Historique

    fichierExport.write(
        "<h4 class=TITRETABLE>" + Bundle.getText("BD_ImporterProcessus_Historique") + "</h4>\n");
    fichierExport.write("<table border=\"1\" cellpadding=\"2\" cellspacing=\"2\">\n");
    fichierExport.write("  <tbody>\n");
    fichierExport.write("    <tr>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_Version")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>" + Bundle.getText("BD_GenererHTML_Date") + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("OO_CommentaireProjet_caption")
            + "</td>\n");
    fichierExport.write("    </tr>\n");
    int nombreVersion = leProcessus.getListeDesVersion().size();
    for (Iterator it = leProcessus.getListeDesVersion().iterator(); it.hasNext(); --nombreVersion) {
      ArrayList unGroupe = (ArrayList) it.next();
      fichierExport.write("    <tr>\n");
      fichierExport.write("      <td>" + unGroupe.get(1) + "</td>\n");
      fichierExport.write(
          "      <td>" + leProcessus.formaterDateExport((String) unGroupe.get(0)) + "</td>\n");
      // TODO : Commentaire du fichier HTML
      fichierExport.write(
          "      <td>"
              + (nombreVersion == 1 ? leProcessus.getDescription() : "&nbsp;")
              + "</td>\n");
      fichierExport.write("    </tr>\n");
    }
    fichierExport.write("  </tbody>\n");
    fichierExport.write("</table>\n");
    fichierExport.write(
        "<div class=SOUSTABLE>" + Bundle.getText("BD_GenererHTML_DateExport") + "</div>\n");

    // ---------------------Revues processus

    fichierExport.write(
        "<h4 class=TITRETABLE>" + Bundle.getText("OO_RevueProcessus_caption") + "</h4>\n");
    fichierExport.write("<table border=\"1\" cellpadding=\"2\" cellspacing=\"2\">\n");
    fichierExport.write("  <tbody>\n");
    fichierExport.write("    <tr>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("OO_RevueProcessus_champ_date")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("OO_RevueProcessus_champ_dateProchaine")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("OO_RevueProcessus_champ_decision")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("OO_RevueProcessus_champ_action")
            + "</td>\n");
    fichierExport.write("    </tr>\n");
    for (int i = 0; i < C_RevueProcessus.size(idProcessus); i++) {
      try {
        fichierExport.write("<tr>\n");
        fichierExport.write(
            "  <td>"
                + sfDate.format(
                    C_RevueProcessus.getRevueProcessusIndice(idProcessus, i).getDateRevue())
                + "</td>\n");
        fichierExport.write(
            "  <td>"
                + ((C_RevueProcessus.getRevueProcessusIndice(idProcessus, i).getDateProchaineRevue()
                        == null)
                    ? "&nbsp;"
                    : sfDate.format(
                        C_RevueProcessus.getRevueProcessusIndice(idProcessus, i).getDateRevue()))
                + "</td>\n");
        String uneDecision = C_RevueProcessus.getRevueProcessusIndice(idProcessus, i).getDecision();
        uneDecision = uneDecision.replaceAll("\n", "<BR>");
        uneDecision = uneDecision.replaceAll(" ", "&nbsp;");
        fichierExport.write("  <td>" + uneDecision + "</td>\n");
        String uneAction =
            (C_RevueProcessus.getRevueProcessusIndice(idProcessus, i).getAction().equals("")
                ? "&nbsp;"
                : C_RevueProcessus.getRevueProcessusIndice(idProcessus, i).getAction());
        uneAction = uneAction.replaceAll("\n", "<BR>");
        uneAction = uneAction.replaceAll(" ", "&nbsp;");
        fichierExport.write("  <td>" + uneAction + "</td>\n");
        fichierExport.write("</tr>\n");
      } catch (Exception e) {
        fichierExport.write("</tr>\n");
      }
    }
    fichierExport.write("</tbody>\n");
    fichierExport.write("</table>\n");
    fichierExport.write("<br>\n");

    // ---------------------Mesures de représentation

    fichierExport.write(
        "<h4 class=TITRETABLE>"
            + Bundle.getText("BD_MesureVersion_MesureRepresentation")
            + "</h4>\n");
    fichierExport.write("<ul>\n");
    fichierExport.write("  <li>" + Bundle.getText("BD_MesureVersion_RI") + "</li>\n");
    fichierExport.write("</ul>\n");
    fichierExport.write("<table border=\"1\" cellpadding=\"2\" cellspacing=\"2\">\n");
    fichierExport.write("  <tbody>\n");
    fichierExport.write("    <tr>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_Version")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_InterfacesE")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_InterfacesS")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_Scenario")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_Explicite")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_Estime")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_EvaluationIT")
            + "</td>\n");
    fichierExport.write("    </tr>\n");
    for (Iterator it = leProcessus.getListeDesVersion().iterator(); it.hasNext(); ) {
      ArrayList uneVersion = (ArrayList) it.next();
      String dateExport = (String) uneVersion.get(0);
      E_MesureRepresentation uneMesure = leProcessus.getMesureRepresentation(dateExport);
      fichierExport.write("    <tr>\n");
      fichierExport.write("      <td>" + uneVersion.get(1) + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getInterfaceE() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getInterfaceS() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getScenario() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getExplicite() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getEstime() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getEvaluationIT() + "</td>\n");
      fichierExport.write("    </tr>\n");
    }
    fichierExport.write("  </tbody>\n");
    fichierExport.write("</table>\n");
    fichierExport.write("<ul>\n");
    fichierExport.write("  <li>" + Bundle.getText("BD_MesureVersion_RM") + "</li>\n");
    fichierExport.write("</ul>\n");
    fichierExport.write("<table border=\"1\" cellpadding=\"2\" cellspacing=\"2\">\n");
    fichierExport.write("  <tbody>\n");
    fichierExport.write("    <tr>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_Version")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_Coherence")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_Completude")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_Definitions")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_Activites")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_Roles")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_Produits")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_EvaluationMO")
            + "</td>\n");
    fichierExport.write("    </tr>\n");
    for (Iterator it = leProcessus.getListeDesVersion().iterator(); it.hasNext(); ) {
      ArrayList uneVersion = (ArrayList) it.next();
      String dateExport = (String) uneVersion.get(0);
      E_MesureRepresentation uneMesure = leProcessus.getMesureRepresentation(dateExport);
      fichierExport.write("    <tr>\n");
      fichierExport.write("      <td>" + uneVersion.get(1) + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getCoherence() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getCompletude() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getNbDef() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getNbAct() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getNbRole() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getNbProd() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getEvaluationMo() + "</td>\n");
      fichierExport.write("    </tr>\n");
    }
    fichierExport.write("  </tbody>\n");
    fichierExport.write("</table>\n");
    fichierExport.write("<ul>\n");
    fichierExport.write("  <li>" + Bundle.getText("BD_MesureVersion_RD") + "</li>\n");
    fichierExport.write("</ul>\n");
    fichierExport.write("<table border=\"1\" cellpadding=\"2\" cellspacing=\"2\">\n");
    fichierExport.write("  <tbody>\n");
    fichierExport.write("    <tr>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_Version")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_ProduitsPlan")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_PourPlan")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_Guide")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_PourGuide")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_Documents")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_PourDoc")
            + "</td>\n");
    fichierExport.write(
        "      <td class=PREMIERELIGNETABLE>"
            + Bundle.getText("BD_MesureVersion_EvaluationDO")
            + "</td>\n");
    fichierExport.write("    </tr>\n");
    for (Iterator it = leProcessus.getListeDesVersion().iterator(); it.hasNext(); ) {
      ArrayList uneVersion = (ArrayList) it.next();
      String dateExport = (String) uneVersion.get(0);
      E_MesureRepresentation uneMesure = leProcessus.getMesureRepresentation(dateExport);
      fichierExport.write("    <tr>\n");
      fichierExport.write("      <td>" + uneVersion.get(1) + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getNbProdType() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getPourPlan() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getNbGuide() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getPourGuide() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getNbDocu() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getPourDocu() + "</td>\n");
      fichierExport.write("      <td>" + uneMesure.getEvaluationDocu() + "</td>\n");
      fichierExport.write("    </tr>\n");
    }
    fichierExport.write("  </tbody>\n");
    fichierExport.write("</table>\n");

    // ---------------------Mesures d'adhésion
    if (C_Processus.getProcessus(idProcessus).getNiveauMaturite() > 1) {
      fichierExport.write("<br>\n");
      fichierExport.write(
          "<h4 class=TITRETABLE>" + Bundle.getText("BD_GenererHTML_MesureAdhesion") + "</h4>\n");
      fichierExport.write("<ul>\n");
      fichierExport.write("  <li>" + Bundle.getText("OO_MesureAcces_caption") + " : </li>\n");
      fichierExport.write("</ul>\n");
      fichierExport.write("<table border=\"1\" cellpadding=\"2\" cellspacing=\"2\">\n");
      fichierExport.write("  <tbody>\n");
      fichierExport.write("    <tr>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("OO_MesureAcces_champ_mois")
              + "</td>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("OO_MesureAcces_champ_nombre")
              + "</td>\n");
      fichierExport.write("    </tr>\n");
      for (Iterator it = leProcessus.getListeMesuresAcces().iterator(); it.hasNext(); ) {
        E_MesureAcces uneMesure = (E_MesureAcces) it.next();
        fichierExport.write("    <tr>\n");
        fichierExport.write("      <td>" + sfMois.format(uneMesure.getMois()) + "</td>\n");
        fichierExport.write("      <td>" + uneMesure.getNombre() + "</td>\n");
        fichierExport.write("    </tr>\n");
      }
      fichierExport.write("  </tbody>\n");
      fichierExport.write("</table>\n");
      fichierExport.write(
          "<div class=SOUSTABLE>"
              + Bundle.getText("BD_GenererHTML_MesureAdhesion_HAbas")
              + "</div>\n");
      fichierExport.write("<ul>\n");
      fichierExport.write("  <li>" + Bundle.getText("OO_MesureFormation_caption") + " : </li>\n");
      fichierExport.write("</ul>\n");
      fichierExport.write("<table border=\"1\" cellpadding=\"2\" cellspacing=\"2\">\n");
      fichierExport.write("  <tbody>\n");
      fichierExport.write("    <tr>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("OO_MesureFormation_champ_date")
              + "</td>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("OO_MesureFormation_champ_effPro")
              + "</td>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("OO_MesureFormation_champ_effMes")
              + "</td>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("OO_MesureFormation_champ_note")
              + "</td>\n");
      fichierExport.write("    </tr>\n");
      for (Iterator it = leProcessus.getListeMesuresFormation().iterator(); it.hasNext(); ) {
        E_MesureFormation uneMesure = (E_MesureFormation) it.next();
        fichierExport.write("    <tr>\n");
        fichierExport.write("      <td>" + sfDate.format(uneMesure.getDateMesure()) + "</td>\n");
        fichierExport.write("      <td>" + uneMesure.getEffectifProcessus() + "</td>\n");
        fichierExport.write("      <td>" + uneMesure.getEffectifMesure() + "</td>\n");
        fichierExport.write("      <td>" + uneMesure.getNote() + "</td>\n");
        fichierExport.write("    </tr>\n");
      }
      fichierExport.write("  </tbody>\n");
      fichierExport.write("</table>\n");
      fichierExport.write(
          "<div class=SOUSTABLE>"
              + Bundle.getText("BD_GenererHTML_MesureAdhesion_HFbas")
              + "</div>\n");
      fichierExport.write("<ul>\n");
      fichierExport.write("  <li>" + Bundle.getText("OO_MesureUtilisation_caption") + " : </li>\n");
      fichierExport.write("</ul>\n");
      fichierExport.write("<table border=\"1\" cellpadding=\"2\" cellspacing=\"2\">\n");
      fichierExport.write("  <tbody>\n");
      fichierExport.write("    <tr>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("BD_GenererHTML_MesureAdhesion_NomProjet")
              + "</td>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("BD_GenererHTML_MesureAdhesion_DateDebut")
              + "</td>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("BD_GenererHTML_MesureAdhesion_DateFin")
              + "</td>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("OO_MesureUtilisation_champ_pourPT")
              + "</td>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("OO_MesureUtilisation_champ_pourAct")
              + "</td>\n");
      fichierExport.write("    </tr>\n");
      for (Iterator it = leProcessus.getListeMesuresUtilisation().iterator(); it.hasNext(); ) {
        E_MesureUtilisation uneMesure = (E_MesureUtilisation) it.next();
        fichierExport.write("    <tr>\n");
        fichierExport.write(
            "      <td>"
                + ((E_ExecutionProcessus)
                        (C_ExecutionProcessus.getExecutionsProcessusDuProcessus(idProcessus)
                            .get(uneMesure.getIdExec())))
                    .getNomSansVersion()
                + "</td>\n");
        fichierExport.write(
            "      <td>"
                + sfDate.format(
                    ((E_ExecutionProcessus)
                            (C_ExecutionProcessus.getExecutionsProcessusDuProcessus(idProcessus)
                                .get(uneMesure.getIdExec())))
                        .getDateDebut())
                + "</td>\n");
        fichierExport.write(
            "      <td>"
                + sfDate.format(
                    ((E_ExecutionProcessus)
                            (C_ExecutionProcessus.getExecutionsProcessusDuProcessus(idProcessus)
                                .get(uneMesure.getIdExec())))
                        .getDateFin())
                + "</td>\n");
        fichierExport.write("      <td>" + uneMesure.getPourPlanType() + "</td>\n");
        fichierExport.write("      <td>" + uneMesure.getPourActivite() + "</td>\n");
        fichierExport.write("    </tr>\n");
      }
      fichierExport.write("  </tbody>\n");
      fichierExport.write("</table>\n");
      fichierExport.write(
          "<div class=SOUSTABLE>"
              + Bundle.getText("BD_GenererHTML_MesureAdhesion_HUbas")
              + "</div>\n");
    }

    // ---------------------Mesures d'amélioration

    if (C_Processus.getProcessus(idProcessus).getNiveauMaturite() > 1) {
      fichierExport.write(
          "<h4 class=TITRETABLE>" + Bundle.getText("BD_MesureAmelioration_caption") + "</h4>\n");
      fichierExport.write("<table border=\"1\" cellpadding=\"2\" cellspacing=\"2\">\n");
      fichierExport.write("  <tbody>\n");
      fichierExport.write("    <tr>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("BD_MesureAmelioration_version")
              + "</td>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("BD_GenererHTML_Date")
              + "</td>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("BD_MesureAmelioration_nombrePropose")
              + "</td>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("BD_MesureAmelioration_nombrePris")
              + "</td>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("BD_MesureAmelioration_presentation")
              + "</td>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("BD_MesureAmelioration_modele")
              + "</td>\n");
      fichierExport.write(
          "      <td class=PREMIERELIGNETABLE>"
              + Bundle.getText("BD_MesureAmelioration_documentation")
              + "</td>\n");
      fichierExport.write("    </tr>\n");
      for (Iterator it = leProcessus.getListeMesureAmelioration().keySet().iterator();
          it.hasNext(); ) {
        String dateExport = (String) it.next();
        E_MesureAmelioration uneMesure = leProcessus.getMesureAmelioration(dateExport);
        fichierExport.write("    <tr>\n");
        fichierExport.write(
            "      <td>" + C_Processus.getNumeroVersion(idProcessus, dateExport) + "</td>\n");
        fichierExport.write(
            "      <td>" + sfDate.format(uneMesure.getDateChangement()) + "</td>\n");
        fichierExport.write("      <td>" + uneMesure.getNombrePropose() + "</td>\n");
        fichierExport.write("      <td>" + uneMesure.getNombrePris() + "</td>\n");
        fichierExport.write("      <td>" + uneMesure.getPresentation() + "</td>\n");
        fichierExport.write("      <td>" + uneMesure.getModele() + "</td>\n");
        fichierExport.write("      <td>" + uneMesure.getDocumentation() + "</td>\n");
        fichierExport.write("    </tr>\n");
      }
      fichierExport.write("  </tbody>\n");
      fichierExport.write("</table>\n");
    }

    // ------------------------

    fichierExport.write("</body>\n</html>");

    fichierExport.close();
  }