IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

Java Discussion :

DLL temporaire extrait du jar


Sujet :

Java

  1. #21
    Expert éminent sénior
    Avatar de tchize_
    Homme Profil pro
    Ingénieur développement logiciels
    Inscrit en
    Avril 2007
    Messages
    25 481
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Âge : 44
    Localisation : Belgique

    Informations professionnelles :
    Activité : Ingénieur développement logiciels
    Secteur : High Tech - Éditeur de logiciels

    Informations forums :
    Inscription : Avril 2007
    Messages : 25 481
    Points : 48 806
    Points
    48 806
    Par défaut
    Tu fais simplement ceci après l'avoir extrait:


    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    System.setProperty("java.library.path",tempFile.getParent());
    donc en gros tu change le library path pour qu'il pointe vers l'endroit où se trouve ton fichier. C'est pas super propre, mais ça vaut le coup d'essayer.

  2. #22
    Membre habitué
    Homme Profil pro
    Inscrit en
    Septembre 2013
    Messages
    149
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations forums :
    Inscription : Septembre 2013
    Messages : 149
    Points : 126
    Points
    126
    Par défaut
    J'obtiens encore une fois la même erreur avec System.setProperty(...);

    Quand je ne demande pas de charger une librairie et que mon dll est dans le répertoire courant (en mettant en commentaire l'extraction). Mon jar se lance parfaitement. Donc si le dll est dans le répertoire courant avant le lancement du programme, ça fonctionne. Si je peux faire en sorte que Sigar attende que j'extraie le dll avant de se lancer, je pense que ça fonctionnerais.

  3. #23
    Expert éminent sénior
    Avatar de tchize_
    Homme Profil pro
    Ingénieur développement logiciels
    Inscrit en
    Avril 2007
    Messages
    25 481
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Âge : 44
    Localisation : Belgique

    Informations professionnelles :
    Activité : Ingénieur développement logiciels
    Secteur : High Tech - Éditeur de logiciels

    Informations forums :
    Inscription : Avril 2007
    Messages : 25 481
    Points : 48 806
    Points
    48 806
    Par défaut
    tu peux nous montrer ton code avec le System.setProperty et l'erreur?


    Citation Envoyé par JeremGamer Voir le message
    Si je peux faire en sorte que Sigar attende que j'extraie le dll avant de se lancer, je pense que ça fonctionnerais.
    Il me semblait, je peux me tromper, que c'était déjà ce que tu faisais :/ Si Cigar se lance avant, c'est un autre problème, faut revoir la manière dont tu charge Cigar.

    Vu qu'on parle d'initialisation statique, le plus simple c'est que la classe contenant ton main() ne fasse aucune référence à Cigar et que la première chose qu'elle fasse soit extraire la librairie.

  4. #24
    Membre habitué
    Homme Profil pro
    Inscrit en
    Septembre 2013
    Messages
    149
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations forums :
    Inscription : Septembre 2013
    Messages : 149
    Points : 126
    Points
    126
    Par défaut
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    	public static void loadDLL() throws IOException { 
    	//Creating temp file
    		File tempFile = File.createTempFile("sigar-amd64-winnt", ".dll");
     
    		try (InputStream input = Main.class.getResourceAsStream("sigar-amd64-winnt.dll");
    			OutputStream output = new FileOutputStream(tempFile)) {
    			byte[] buf = new byte[8192];
    			int len;
    			while ( (len=input.read(buf)) > 0 ) {
    				output.write(buf, 0, len);
    			}
    			output.flush();
    		}
    		System.setProperty("java.library.path",tempFile.getParent());
    		tempFile.deleteOnExit(); 
        //-------------------------------------------------------	
    	}
    Et voila l'erreur.
    Nom : screenshot3.png
Affichages : 64
Taille : 26,8 Ko

  5. #25
    Membre habitué
    Homme Profil pro
    Inscrit en
    Septembre 2013
    Messages
    149
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations forums :
    Inscription : Septembre 2013
    Messages : 149
    Points : 126
    Points
    126
    Par défaut
    J'ai tenté de minimiser les références à Sigar:

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    public class Main {
     
     
    	//-------------------------------------------------------
    	//Loading Required Libraries
    	//-------------------------------------------------------
    	public static void loadDLL() throws IOException { 
    	//Creating temp file
    		File tempFile = File.createTempFile("sigar-amd64-winnt", ".dll");
    		//File tempFile = new File("sigar-amd64-winnt.dll");
     
    		try (InputStream input = Main.class.getResourceAsStream("sigar-amd64-winnt.dll");
    			OutputStream output = new FileOutputStream(tempFile)) {
    			byte[] buf = new byte[8192];
    			int len;
    			while ( (len=input.read(buf)) > 0 ) {
    				output.write(buf, 0, len);
    			}
    			output.flush();
    		}
    		System.setProperty("java.library.path",tempFile.getParent());
    		tempFile.deleteOnExit(); 
     
        //-------------------------------------------------------	
    	}
     
     
     
     
        public static void main(String args[]) throws IOException {
     
     
        	//----------Calling for DLL importation method-----------
        	loadDLL();
        	//-------------------------------------------------------
     
     
        	new GettingInformations();
    		//----------------Displaying Informations---------------- 
        	GettingInformations.getGeneralInformations();
        	GettingInformations.getInformationsAboutCPU();
        	GettingInformations.getInformationsAboutMemory();
        	GettingInformations.getInformationsAboutGPU();
        	//-------------------------------------------------------
    J'ai cette erreur:
    Nom : screenshot 4.png
Affichages : 70
Taille : 35,0 Ko

  6. #26
    Expert éminent sénior
    Avatar de tchize_
    Homme Profil pro
    Ingénieur développement logiciels
    Inscrit en
    Avril 2007
    Messages
    25 481
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Âge : 44
    Localisation : Belgique

    Informations professionnelles :
    Activité : Ingénieur développement logiciels
    Secteur : High Tech - Éditeur de logiciels

    Informations forums :
    Inscription : Avril 2007
    Messages : 25 481
    Points : 48 806
    Points
    48 806
    Par défaut
    Tu peux rajouter un System.out.println("Librairie extraite") juste après le System.setProperty("java.library.path",tempFile.getParent()); ? Que l'on vois à quel moment a lieu l'extraction. Aussi, donne le code complet de ta classe main, que je puisse voir ce qui ne va éventuellement pas.

  7. #27
    Membre habitué
    Homme Profil pro
    Inscrit en
    Septembre 2013
    Messages
    149
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations forums :
    Inscription : Septembre 2013
    Messages : 149
    Points : 126
    Points
    126
    Par défaut
    Voila le code de ma classe Main (avant d'avoir effectué les modifications pour minimiser les références à Sigar):

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    130
    131
    132
    133
    134
    135
    136
    137
    138
    139
    140
    141
    142
    143
    144
    145
    146
    147
    148
    149
    150
    151
    152
    153
    package main;
     
    import java.awt.Dimension;
    import java.awt.Toolkit;
    import java.io.File;
    import java.io.FileOutputStream;
    import java.io.IOException;
    import java.io.InputStream;
    import java.io.OutputStream;
    import java.net.InetAddress;
    import java.net.UnknownHostException;
     
    import org.hyperic.sigar.CpuInfo;
    import org.hyperic.sigar.Mem;
    import org.hyperic.sigar.Sigar;
    import org.hyperic.sigar.SigarException;
     
     
     
    public class Main {
     
     
    	//-------------------------------------------------------
    	//Loading Required Libraries
    	//-------------------------------------------------------
    	public static void loadDLL() throws IOException { 
    	//Creating temp file
    		File tempFile = File.createTempFile("sigar-amd64-winnt", ".dll");
     
    		try (InputStream input = Main.class.getResourceAsStream("sigar-amd64-winnt.dll");
    			OutputStream output = new FileOutputStream(tempFile)) {
    			byte[] buf = new byte[8192];
    			int len;
    			while ( (len=input.read(buf)) > 0 ) {
    				output.write(buf, 0, len);
    			}
    			output.flush();
    		}
    		System.setProperty("java.library.path",tempFile.getParent());
                    System.out.println("Librairie extraite");
    		tempFile.deleteOnExit(); 
     
    	//Loading Library
    		//System.load(tempFile.getAbsolutePath());
        //-------------------------------------------------------	
    	}
     
     
     
     
        private static Sigar sigar = new Sigar();
     
        //-----------------------------------------------------------
        //Getting General Informations Method
        //-----------------------------------------------------------
        public static void getGeneralInformations() {
        	InetAddress ip;
        	try {
        		ip = InetAddress.getLocalHost();
        		System.out.println("Nom du PC : " + ip.getHostName());  
        		System.out.println("Votre adresse IP locale: " + ip.getHostAddress());
        	} catch (UnknownHostException e) {
        		e.printStackTrace();
        	}      	
        	String os = System.getProperty("os.name");
        	String version = System.getProperty("os.version");
        	System.out.println("Système d'exploitation: " + os + " Version " + version); 
        }
        //-----------------------------------------------------------
     
     
     
        //-----------------------------------------------------------
        //Getting Memory Informations Method
        //-----------------------------------------------------------
        public static void getInformationsAboutMemory() {
            Mem mem = null;
            try {
                mem = sigar.getMem();
            } catch (SigarException se) {
                se.printStackTrace();
                }
     
            System.out.println("Mémoire RAM hors système: " + mem.getTotal() / 1024 / 1024 + " MB soit " + mem.getTotal() / 1024 / 1024 / 1024 + " GB");
        }
        //-----------------------------------------------------------
     
     
     
        //-----------------------------------------------------------
        //Getting CPU Informations Method
        //-----------------------------------------------------------
        static CpuInfo[] infos = null;
    	public static void getInformationsAboutCPU() {
            try {
                infos = sigar.getCpuInfoList();
            } catch (SigarException se) {
                se.printStackTrace();        }
    		org.hyperic.sigar.CpuInfo info = infos[0];
            System.out.println("Processeur: " + info.getVendor() + " " + info.getModel() + " || " + info.getTotalCores() + " coeurs");
        }
    	//-----------------------------------------------------------
     
     
     
        //-----------------------------------------------------------
        //Getting GPU Informations Method
        //-----------------------------------------------------------
    	public static void getInformationsAboutGPU() {
     
     
    	   	Toolkit tk = Toolkit.getDefaultToolkit();
    	   	Dimension d = tk.getScreenSize();	
    	       int height = d.height;
    	       int width = d.width;
    	       System.out.println("Résolution de l'écran: " + width + "X" + height);
     
    	}
        //-----------------------------------------------------------
     
     
     
        public static void main(String args[]) throws IOException {
     
     
        	//----------Calling for DLL importation method-----------
        	loadDLL();
        	//-------------------------------------------------------
     
     
        	//----------------Displaying Informations---------------- 
        	getGeneralInformations();
     
        	getInformationsAboutCPU();
     
        	getInformationsAboutMemory();
     
        	getInformationsAboutGPU();
        	//-------------------------------------------------------
     
     
        	//--------------Displaying Usage Frames------------------
        	try {
    			CPUUsageFrame cpuFrame = new CPUUsageFrame(); // Displaying CPU usage frame
    			new MEMUsageFrame(cpuFrame); //Displaying RAM usage frame
    		} catch (SigarException e) {
    			e.printStackTrace();
    		}
        	//-------------------------------------------------------
     
        }
     
    }
    edit: L'extraction se fait bien après le démarrage de Sigar:
    Nom : screenshot 5.png
Affichages : 60
Taille : 34,8 Ko

  8. #28
    Expert éminent sénior
    Avatar de tchize_
    Homme Profil pro
    Ingénieur développement logiciels
    Inscrit en
    Avril 2007
    Messages
    25 481
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Âge : 44
    Localisation : Belgique

    Informations professionnelles :
    Activité : Ingénieur développement logiciels
    Secteur : High Tech - Éditeur de logiciels

    Informations forums :
    Inscription : Avril 2007
    Messages : 25 481
    Points : 48 806
    Points
    48 806
    Par défaut
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
        private static Sigar sigar = new Sigar();
    Les champs statique de ta classe sont initialisés avant de rentrer dans le main. Le main() devrait être la toute première chose que fait ton programme. Du coup, il ne devrait y avoir aucun champ statique dans ta classe. Retire le static, remplace toutes tes méthodes statiques, a l'exception de loadDll par des méthodes d'instance, fait un new Main() après le loadDll et utilie cette instance pour tous tes appels.


    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
        public static void main(String args[]) throws IOException {
     
     
        	//----------Calling for DLL importation method-----------
        	loadDLL();
        	//-------------------------------------------------------
     
     
            Main main = new Main();
        	//----------------Displaying Informations---------------- 
        	main.getGeneralInformations();
     
        	main.getInformationsAboutCPU();
            // etc.

  9. #29
    Membre habitué
    Homme Profil pro
    Inscrit en
    Septembre 2013
    Messages
    149
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations forums :
    Inscription : Septembre 2013
    Messages : 149
    Points : 126
    Points
    126
    Par défaut
    Ah très bien! Sigar se lance après l'extraction désormais!

    J'obtiens cependant encore l'erreur:
    Nom : screenshot 6.png
Affichages : 68
Taille : 30,3 Ko

    J'ai alors changé mon tempFile pour qu'il se créé dans le répertoire courant. Ça fonctionne!
    Seul problème qui subsiste: Le fichier ne se supprime pas à la fermeture du programme...
    Voici mon nouveau code:
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    130
    131
    132
    133
    134
    135
    136
    137
    138
    139
    140
    141
    package main;
     
    import java.awt.Dimension;
    import java.awt.Toolkit;
    import java.io.File;
    import java.io.FileOutputStream;
    import java.io.IOException;
    import java.io.InputStream;
    import java.io.OutputStream;
    import java.net.InetAddress;
    import java.net.UnknownHostException;
     
    import org.hyperic.sigar.CpuInfo;
    import org.hyperic.sigar.Mem;
    import org.hyperic.sigar.Sigar;
    import org.hyperic.sigar.SigarException;
     
     
     
    public class Main {
     
     
    	//-------------------------------------------------------
    	//Loading Required Libraries
    	//-------------------------------------------------------
    	public static void loadDLL() throws IOException { 
    	//Creating temp file
    		//File tempFile = File.createTempFile("sigar-amd64-winnt", ".dll");
    		File tempFile = new File("sigar-amd64-winnt.dll");
     
    		try (InputStream input = Main.class.getResourceAsStream("sigar-amd64-winnt.dll");
    			OutputStream output = new FileOutputStream(tempFile)) {
    			byte[] buf = new byte[8192];
    			int len;
    			while ( (len=input.read(buf)) > 0 ) {
    				output.write(buf, 0, len);
    			}
    			output.flush();
    			input.close();
    			output.close();
    		}
    		//System.setProperty("java.library.path",tempFile.getParent());
    		System.out.println("Librairie extraite");
    		tempFile.deleteOnExit(); 
     
        //-------------------------------------------------------	
    	}
     
     
     
    	Main() {
        Sigar sigar = new Sigar();
     
        //-----------------------------------------------------------
        //Getting General Informations Method
        //-----------------------------------------------------------
        	InetAddress ip;
        	try {
        		ip = InetAddress.getLocalHost();
        		System.out.println("Nom du PC : " + ip.getHostName());  
        		System.out.println("Votre adresse IP locale: " + ip.getHostAddress());
        	} catch (UnknownHostException e) {
        		e.printStackTrace();
        	}      	
        	String os = System.getProperty("os.name");
        	String version = System.getProperty("os.version");
        	System.out.println("Système d'exploitation: " + os + " Version " + version); 
        //-----------------------------------------------------------
     
     
     
        //-----------------------------------------------------------
        //Getting Memory Informations Method
        //-----------------------------------------------------------
            Mem mem = null;
            try {
                mem = sigar.getMem();
            } catch (SigarException se) {
                se.printStackTrace();
                }
     
            System.out.println("Mémoire RAM hors système: " + mem.getTotal() / 1024 / 1024 + " MB soit " + mem.getTotal() / 1024 / 1024 / 1024 + " GB");
        //-----------------------------------------------------------
     
     
     
        //-----------------------------------------------------------
        //Getting CPU Informations Method
        //-----------------------------------------------------------
        CpuInfo[] infos = null;
            try {
                infos = sigar.getCpuInfoList();
            } catch (SigarException se) {
                se.printStackTrace();        }
    		org.hyperic.sigar.CpuInfo info = infos[0];
            System.out.println("Processeur: " + info.getVendor() + " " + info.getModel() + " || " + info.getTotalCores() + " coeurs");
    	//-----------------------------------------------------------
     
     
     
        //-----------------------------------------------------------
        //Getting GPU Informations Method
        //-----------------------------------------------------------
     
     
    	   	Toolkit tk = Toolkit.getDefaultToolkit();
    	   	Dimension d = tk.getScreenSize();	
    	       int height = d.height;
    	       int width = d.width;
    	       System.out.println("Résolution de l'écran: " + width + "X" + height);
     
     
        //-----------------------------------------------------------
    	}
     
     
        public static void main(String args[]) throws IOException {
     
     
        	//----------Calling for DLL importation method-----------
        	loadDLL();
        	//-------------------------------------------------------
     
     
        	//----------------Displaying Informations---------------- 
        	new Main();
        	//-------------------------------------------------------
     
     
        	//--------------Displaying Usage Frames------------------
        	try {
    			CPUUsageFrame cpuFrame = new CPUUsageFrame(); // Displaying CPU usage frame
    			new MEMUsageFrame(cpuFrame); //Displaying RAM usage frame
    		} catch (SigarException e) {
    			e.printStackTrace();
    		}
        	//-------------------------------------------------------
     
        }
     
    }

  10. #30
    Expert éminent sénior
    Avatar de tchize_
    Homme Profil pro
    Ingénieur développement logiciels
    Inscrit en
    Avril 2007
    Messages
    25 481
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Âge : 44
    Localisation : Belgique

    Informations professionnelles :
    Activité : Ingénieur développement logiciels
    Secteur : High Tech - Éditeur de logiciels

    Informations forums :
    Inscription : Avril 2007
    Messages : 25 481
    Points : 48 806
    Points
    48 806
    Par défaut
    Pourquoi c'est commenté ça?

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
     
    		//System.setProperty("java.library.path",tempFile.getParent());
    aussi, pour la properté, faire ceci?


    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
     
    		File tempFile = new File(System.getProperty("java.io.tmpdir"),"sigar-amd64-winnt.dll");
    Pour la suppression à la fermeture, ça risque de ne pas être possible. Le verrou sur la dll, une fois chargée, ne sera libéré que lorsque java se sera arrêté. Et à ce moment là, trop tard pour exécuter du code java qui efface le fichier

  11. #31
    Membre habitué
    Homme Profil pro
    Inscrit en
    Septembre 2013
    Messages
    149
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations forums :
    Inscription : Septembre 2013
    Messages : 149
    Points : 126
    Points
    126
    Par défaut
    Je l'ai laissé pour l'instant au cas où j'aurais besoin de le remettre. Si je le laisse, cela créé une NullPointerException.
    De même pour //File tempFile = File.createTempFile("sigar-amd64-winnt", ".dll");
    Vu que mon fichier est maintenant dans le répertoire courant, plus besoin de changer le library path.

    A quoi servirait cette ligne? File tempFile = new File(System.getProperty("java.io.tmpdir"),"sigar-amd64-winnt.dll");
    Pour la suppression à la fermeture, ça risque de ne pas être possible. Le verrou sur la dll, une fois chargée, ne sera libéré que lorsque java se sera arrêté. Et à ce moment là, trop tard pour exécuter du code java qui efface le fichier
    Arf. Il n'est pas possible de définir une action qui s'effectuera juste avant la fermeture?
    Je sais que c'est possible avec une JFrame mais sur console je ne sais pas.
    De toute manière, je remplacerais plus tard la console par une JFrame qui regroupera mes "usage frame" et les informations que j'affiche en ce moment sur console.
    Je pourrais peut-être supprimer mon fichier grâce à ça? (Pas très propre mais bon )

  12. #32
    Membre chevronné
    Inscrit en
    Mai 2006
    Messages
    1 364
    Détails du profil
    Informations forums :
    Inscription : Mai 2006
    Messages : 1 364
    Points : 1 984
    Points
    1 984
    Par défaut
    Faudrait regarder l'API de Sigar. Avec un peu de chance, il existe des fonctions type close/dispose qui permettraient de liberer proprement ce qu'il faut pour que tu puisses effacer la dll...

  13. #33
    Membre habitué
    Homme Profil pro
    Inscrit en
    Septembre 2013
    Messages
    149
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations forums :
    Inscription : Septembre 2013
    Messages : 149
    Points : 126
    Points
    126
    Par défaut
    Le fichier se supprime correctement à la fermeture du programme quand j’exécute celui-ci depuis Eclipse et en le fermant par mes JFrame.
    Or, une fois compilé, je fais le test mais le fichier ne se supprime pas.

Discussions similaires

  1. Réponses: 0
    Dernier message: 24/11/2011, 18h23
  2. Intégration des dll dans un fichier JAR
    Par dot-_-net dans le forum Général Java
    Réponses: 1
    Dernier message: 02/03/2011, 04h27
  3. Réponses: 5
    Dernier message: 29/07/2009, 15h04
  4. Problème de DLL dans un fichier jar
    Par Guigui985 dans le forum Entrée/Sortie
    Réponses: 0
    Dernier message: 14/10/2008, 18h15
  5. Réponses: 3
    Dernier message: 24/11/2006, 11h12

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo