nat.presentateur
Class PresentateurSans

java.lang.Object
  extended by nat.presentateur.Presentateur
      extended by nat.presentateur.PresentateurSans

public class PresentateurSans
extends Presentateur


Field Summary
private  java.lang.String charset
           
private  GestionnaireErreur gest
           
 
Fields inherited from class nat.presentateur.Presentateur
sortie, source, tempsExecution
 
Constructor Summary
PresentateurSans(GestionnaireErreur gest, java.lang.String charset, java.lang.String source, java.lang.String sortie)
           
 
Method Summary
 void convert(java.io.File in, java.io.File out, java.lang.String encodingIn, java.lang.String encodingOut)
          Transfert le contenu texte d’un fichier dans un autre fichier en assurant la conversion de l’encodage du texte
 boolean presenter()
           
 
Methods inherited from class nat.presentateur.Presentateur
donneTempsExecution, encode
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

charset

private java.lang.String charset

gest

private GestionnaireErreur gest
Constructor Detail

PresentateurSans

public PresentateurSans(GestionnaireErreur gest,
                        java.lang.String charset,
                        java.lang.String source,
                        java.lang.String sortie)
Method Detail

presenter

public boolean presenter()
Specified by:
presenter in class Presentateur

convert

public void convert(java.io.File in,
                    java.io.File out,
                    java.lang.String encodingIn,
                    java.lang.String encodingOut)
             throws java.io.FileNotFoundException,
                    java.nio.charset.IllegalCharsetNameException,
                    java.nio.charset.UnsupportedCharsetException,
                    java.io.IOException
Transfert le contenu texte d’un fichier dans un autre fichier en assurant la conversion de l’encodage du texte

Parameters:
in - Fichier d’origine. Ne sera pas modifié sauf si passé en 2ème paramètre également
out - Fichier à créer
encodingIn - Encodage du fichier d’origine (tel que ISO-8859-15, UTF-8 ou UTF-16)
encodingOut - Encodage du fichier de destination
Throws:
java.io.FileNotFoundException - Quand le fichier d’origine n’existe pas
java.nio.charset.IllegalCharsetNameException - Quand un des encodages est invalide ou introuvable
java.nio.charset.UnsupportedCharsetException - Quand un des encodages n’est pas supporté
java.io.IOException - Erreur d’entrées/sorties