Forums Rue-Montgallet.com
Rue-Montgallet.comRue-Hardware.comRue-Occasion.comRue-DVD.comRue-Jeuxvideo.comRue-AudioVideo.comRue-Telephone.comForums
S'inscrire | S'identifier |
| Recherche avancée | Aide
 
 

Achat - Vente Informatique : herve_94220, vtatin Au coin de la ruelle : sthv Achat - Vente Divers : schloups, super-warrior, tademi16 et 31 utilisateurs inconnus

 Mot :   Pseudo :  
 
Bas de page
Auteur
 Sujet :

Compilation Java sous windows (edit new pb dernier post)

 
n°14979
Memphis
Franc Archer
Profil : Habitué
Posté le 19-10-2005 à 23:09:15  profilanswer
 

Bonsoir all,
 
je viens de me mettre au java (via la license MPI), et j'essaye de refaire mon tp (a la fac sous kde avec tout de préinstallé pour les étudiants) chez moi sous windows XP.
 
Je fais mon fichier en *.java
J'ai windows
J'ai installé JDK
 
et pourtant quand je vais dans l'invite de command (cmd) et que je tappe
 
javac nomdufichier.java il me dit 'javac' n'est pas reconnu en tant que commande interne
ou externe, un programme exécutable ou un fichier de commandes.
 
Voilà, j'ai lu pas mal de tutorial, mais étant tout nouveau débutant, j'avoue sans complexe que je fais de la brasse coulée!!
 
Si quelqu'un pouvait m'expliquer la demarche a suivre pour activer les commandes java, ce serait génial.
 
Merci d'avance!
 
Memphis


Message édité par Memphis le 20-10-2005 à 20:57:19
n°14980
P-Y
Profil : Vieux de la vieille
Posté le 19-10-2005 à 23:18:26  profilanswer
 

ca doit etre parce que javac n'est pas dans le PATH... t'as plusieurs solutions:
1)tu vas dans le repertoire ou il est situe (surement C:\program files\java) avant de lancer la commande, mais dans ce cas il faut indiquer tout le chemin vers tes fichier java, c'est pas super pratique...
2)tu rajoutes ce repertoire dans le PATH, ce qui me semble une meilleure idee, mais me demande pas comment on fait sous windows, j'en sais rien :cache: )


Message édité par P-Y le 19-10-2005 à 23:19:12
n°14981
Memphis
Franc Archer
Profil : Habitué
Posté le 19-10-2005 à 23:22:08  profilanswer
 

Merci, j'y arrive avec ta solution 1.
 
Je vais surement passer pour un boulay en programmation, mais c'est quoi PATH, puisque d'après toi ta deuxième solution est mieux.
 
Merci encore

n°14982
Memphis
Franc Archer
Profil : Habitué
Posté le 19-10-2005 à 23:35:33  profilanswer
 

j'ai compris qu'il faut le changer dans le fichier autoexec.bat, mais je ne trouve pas ce fichier!
 
Faut il que je le crée?

n°14983
m@noo
je javaïse, je phpïse ^=^
Profil : Habitué
Posté le 20-10-2005 à 10:19:40  profilanswer
 

c'est fini çà l'autoexec.bat  :D  
les variables d'environnment sont accessibles par le poste de travail (clic droit sur le poste de travail puis propriétés) dans la boite de dialogue doit y avoir un onglet avancé puis un bouton variables d'environnement)
dans variable système tu devrais trouvé le path
pas besoin de reboot normalement.
 
tu peux faire pareil avec classpath pour les besoins de java

n°14985
Memphis
Franc Archer
Profil : Habitué
Posté le 20-10-2005 à 17:00:02  profilanswer
 

Cool ca marche.
 
Merci a vous deux!!!

n°14990
Memphis
Franc Archer
Profil : Habitué
Posté le 20-10-2005 à 20:56:40  profilanswer
 

Voila nouveau problème, j'ai fait mon programme (comme je débute vous pouvez constater du niveau de mon programme ^^) et  en fait c'est une applet que j'ai intégré donc dans une page html.
et il me dit java not inited et ca m'affiche ca:
 
http://img452.imageshack.us/img452/9599/pb7fz.th.jpg
 
D'ou cela peut il venir?


Message édité par Memphis le 23-10-2005 à 21:13:18
n°14992
m@noo
je javaïse, je phpïse ^=^
Profil : Habitué
Posté le 21-10-2005 à 08:49:28  profilanswer
 

mouep (je ne pense pas dire une connerie :D ) là il faut chercher du côté JRE(java runtime environment) à télécharger chez sun également et à installer.


Message édité par m@noo le 21-10-2005 à 08:49:50
n°14995
Memphis
Franc Archer
Profil : Habitué
Posté le 21-10-2005 à 10:50:55  profilanswer
 

ok je vais essayer, donc ma jvm ne serai pas assez a jour!!  
 
Bon je vais dl JRE et je reppase vous dire!

n°14996
Memphis
Franc Archer
Profil : Habitué
Posté le 21-10-2005 à 11:08:19  profilanswer
 

J'ai installé le jre, mais malheureuement ce n'est aps la solution!
Au moins j'aurai le jre a jour!!
 
Si vous avez d'autres idees!
 
bonne journee
 
Memphis

n°14999
Memphis
Franc Archer
Profil : Habitué
Posté le 21-10-2005 à 21:12:45  profilanswer
 

c'est long a lire mais si ca peut vous aider a connaitre le problème:
 
#
# An unexpected error has been detected by HotSpot Virtual Machine:
#
#  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x5c0148d5, pid=2524, tid=6984
#
# Java VM: Java HotSpot(TM) Client VM (1.5.0_05-b05 mixed mode, sharing)
# Problematic frame:
# C  [D3DIM700.DLL+0x148d5]
#
 
---------------  T H R E A D  ---------------
 
Current thread (0x0032dd28):  JavaThread "main" [_thread_in_native, id=6984]
 
siginfo: ExceptionCode=0xc0000005, reading address 0x0000008c
 
Registers:
EAX=0x00000000, EBX=0x00000008, ECX=0x10000000, EDX=0x001be6e0
ESP=0x00123e08, EBP=0x00123e34, ESI=0x001c2620, EDI=0x00000000
EIP=0x5c0148d5, EFLAGS=0x00010246
 
Top of Stack: (sp=0x00123e08)
0x00123e08:   001c2620 5c01499c 00000000 001c2620
0x00123e18:   00000000 00000101 001c2620 00000000
0x00123e28:   00123e5c 5c0b3aad 00000000 00000000
0x00123e38:   5c00b57e 00000000 8007000e 001c2620
0x00123e48:   00123e68 001c2580 5c00ce9d 001c2620
0x00123e58:   001c2620 00123ea0 5c0b37db 00000000
0x00123e68:   00123eac 5c00ce62 001c2620 5c00d159
0x00123e78:   00000001 001c2598 00000000 00123f20  
 
Instructions: (pc=0x5c0148d5)
0x5c0148c5:   00 85 c0 74 05 85 48 1c 75 18 8b 86 b4 33 00 00
0x5c0148d5:   8b 80 8c 00 00 00 85 c0 74 0f 8b 40 04 85 48 1c  
 
 
Stack: [0x00030000,0x00130000),  sp=0x00123e08,  free space=975k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C  [D3DIM700.DLL+0x148d5]
 
Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j  sun.awt.Win32GraphicsEnvironment.initDisplay()V+0
j  sun.awt.Win32GraphicsEnvironment.initDisplayWrapper()V+10
j  sun.awt.Win32GraphicsEnvironment.<clinit>()V+6
v  ~StubRoutines::call_stub
j  java.lang.Class.forName0(Ljava/lang/String;ZLjava/lang/ClassLoader;)Ljava/lang/Class;+0
j  java.lang.Class.forName(Ljava/lang/String;)Ljava/lang/Class;+5
j  java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment()Ljava/awt/GraphicsEnvironment;+24
j  java.awt.Window.init(Ljava/awt/GraphicsConfiguration;)V+45
j  java.awt.Window.<init>()V+71
j  java.awt.Frame.<init>(Ljava/lang/String;)V+1
j  java.awt.Frame.<init>()V+3
j  sun.plugin.AppletViewer.<clinit>()V+4
v  ~StubRoutines::call_stub
j  sun.plugin.JavaRunTime.initEnvironment(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V+45
v  ~StubRoutines::call_stub
 
---------------  P R O C E S S  ---------------
 
Java Threads: ( => current thread )
  0x03afd9c8 JavaThread "Low Memory Detector" daemon [_thread_blocked, id=7204]
  0x03afc5f8 JavaThread "CompilerThread0" daemon [_thread_blocked, id=7120]
  0x03afb8e8 JavaThread "Signal Dispatcher" daemon [_thread_blocked, id=7072]
  0x03af6bc8 JavaThread "Finalizer" daemon [_thread_blocked, id=7268]
  0x03af56e8 JavaThread "Reference Handler" daemon [_thread_blocked, id=7260]
=>0x0032dd28 JavaThread "main" [_thread_in_native, id=6984]
 
Other Threads:
  0x03af2e48 VMThread [id=7328]
  0x03afebd8 WatcherThread [id=7348]
 
VM state:not at safepoint (normal execution)
 
VM Mutex/Monitor currently owned by a thread: None
 
Heap
 def new generation   total 576K, used 391K [0x20a70000, 0x20b10000, 0x211d0000)
  eden space 512K,  76% used [0x20a70000, 0x20ad1ee8, 0x20af0000)
  from space 64K,   0% used [0x20af0000, 0x20af0000, 0x20b00000)
  to   space 64K,   0% used [0x20b00000, 0x20b00000, 0x20b10000)
 tenured generation   total 1408K, used 0K [0x211d0000, 0x21330000, 0x26a70000)
   the space 1408K,   0% used [0x211d0000, 0x211d0000, 0x211d0200, 0x21330000)
 compacting perm gen  total 8192K, used 159K [0x26a70000, 0x27270000, 0x2aa70000)
   the space 8192K,   1% used [0x26a70000, 0x26a97cb8, 0x26a97e00, 0x27270000)
    ro space 8192K,  62% used [0x2aa70000, 0x2af7a3a0, 0x2af7a400, 0x2b270000)
    rw space 12288K,  46% used [0x2b270000, 0x2b8003d8, 0x2b800400, 0x2be70000)
 
Dynamic libraries:
0x00400000 - 0x00419000  F:\Program Files\Internet Explorer\iexplore.exe
0x77f40000 - 0x77fee000  F:\WINDOWS\System32\ntdll.dll
0x77e40000 - 0x77f36000  F:\WINDOWS\system32\kernel32.dll
0x77be0000 - 0x77c33000  F:\WINDOWS\system32\msvcrt.dll
0x77d10000 - 0x77d9d000  F:\WINDOWS\system32\USER32.dll
0x7f000000 - 0x7f041000  F:\WINDOWS\system32\GDI32.dll
0x77da0000 - 0x77e3e000  F:\WINDOWS\system32\ADVAPI32.dll
0x78000000 - 0x78087000  F:\WINDOWS\system32\RPCRT4.dll
0x77290000 - 0x772f6000  F:\WINDOWS\system32\SHLWAPI.dll
0x71700000 - 0x7184a000  F:\WINDOWS\System32\SHDOCVW.dll
0x78090000 - 0x78175000  F:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.2600.1740_x-ww_7cb8ab44\comctl32.dll
0x00900000 - 0x01109000  F:\WINDOWS\system32\SHELL32.dll
0x77300000 - 0x7738b000  F:\WINDOWS\system32\comctl32.dll
0x4fec0000 - 0x4ffe6000  F:\WINDOWS\system32\ole32.dll
0x5b090000 - 0x5b0c4000  F:\WINDOWS\system32\uxtheme.dll
0x10000000 - 0x10005000  F:\Program Files\Stardock\ObjectDock\DockShellHook.dll
0x003e0000 - 0x003ee000  F:\Program Files\MessengerPlus! 3\MsgPlusLoader.dll
0x74690000 - 0x746d4000  F:\WINDOWS\System32\MSCTF.dll
0x71500000 - 0x715fc000  F:\WINDOWS\System32\BROWSEUI.dll
0x723a0000 - 0x723b3000  F:\WINDOWS\System32\browselc.dll
0x75ed0000 - 0x75eef000  F:\WINDOWS\system32\appHelp.dll
0x7a170000 - 0x7a1f0000  F:\WINDOWS\System32\CLBCATQ.DLL
0x770e0000 - 0x7716b000  F:\WINDOWS\system32\OLEAUT32.dll
0x77000000 - 0x770d4000  F:\WINDOWS\System32\COMRes.dll
0x77bd0000 - 0x77bd7000  F:\WINDOWS\system32\VERSION.dll
0x41000000 - 0x41014000  F:\PROGRA~1\Google\GOOGLE~1\GOOGLE~3.DLL
0x60000000 - 0x6001e000  F:\PROGRA~1\Google\GOOGLE~1\GoogleDesktopAPI2.dll
0x62000000 - 0x62031000  F:\PROGRA~1\Google\GOOGLE~1\GoogleDesktopResources_en.dll
0x76610000 - 0x766fc000  F:\WINDOWS\System32\SETUPAPI.dll
0x63000000 - 0x63096000  F:\WINDOWS\system32\WININET.dll
0x76250000 - 0x762da000  F:\WINDOWS\system32\CRYPT32.dll
0x76230000 - 0x76240000  F:\WINDOWS\system32\MSASN1.dll
0x76f40000 - 0x76f50000  F:\WINDOWS\System32\Secur32.dll
0x765b0000 - 0x76601000  F:\WINDOWS\System32\cscui.dll
0x76590000 - 0x765ac000  F:\WINDOWS\System32\CSCDLL.dll
0x02770000 - 0x02a36000  F:\WINDOWS\System32\msi.dll
0x02a40000 - 0x02a63000  F:\Program Files\Fichiers communs\Mediafour\MACVICON.DLL
0x02aa0000 - 0x02aae000  F:\Program Files\Adobe\Acrobat 7.0\ActiveX\AcroIEHelper.dll
0x7c340000 - 0x7c396000  F:\WINDOWS\System32\MSVCR71.dll
0x02ac0000 - 0x02adb000  F:\Program Files\LostGoggles\LGoggles.dll
0x02af0000 - 0x02afc000  F:\DOCUME~1\Flo\APPLIC~1\GLOBAL~1\seekbait.exe
0x71a10000 - 0x71a19000  F:\WINDOWS\System32\WSOCK32.dll
0x719f0000 - 0x71a05000  F:\WINDOWS\System32\WS2_32.dll
0x719e0000 - 0x719e8000  F:\WINDOWS\System32\WS2HELP.dll
0x75e20000 - 0x75ece000  F:\WINDOWS\System32\SXS.DLL
0x1a400000 - 0x1a47c000  F:\WINDOWS\system32\urlmon.dll
0x02ce0000 - 0x02e61000  F:\WINDOWS\System32\shdoclc.dll
0x746e0000 - 0x7476f000  F:\WINDOWS\System32\mlang.dll
0x63580000 - 0x6381e000  F:\WINDOWS\System32\mshtml.dll
0x02c70000 - 0x02c77000  F:\Program Files\Logitech\iTouch\iTchHk.dll
0x75a00000 - 0x75aa7000  F:\WINDOWS\system32\USERENV.dll
0x74660000 - 0x74686000  F:\WINDOWS\System32\msimtf.dll
0x74630000 - 0x74657000  F:\WINDOWS\System32\MSLS31.DLL
0x76320000 - 0x7633c000  F:\WINDOWS\System32\IMM32.DLL
0x32520000 - 0x32532000  F:\Program Files\Microsoft Office\Office10\msohev.dll
0x6d590000 - 0x6d5a1000  F:\Program Files\Java\jre1.5.0_05\bin\npjpi150_05.dll
0x5f140000 - 0x5f15a000  F:\WINDOWS\System32\OLEPRO32.DLL
0x6d400000 - 0x6d417000  F:\Program Files\Java\jre1.5.0_05\bin\jpiexp32.dll
0x71990000 - 0x719cc000  F:\WINDOWS\System32\mswsock.dll
0x76ed0000 - 0x76ef5000  F:\WINDOWS\System32\DNSAPI.dll
0x76f60000 - 0x76f67000  F:\WINDOWS\System32\winrnr.dll
0x76f10000 - 0x76f3d000  F:\WINDOWS\system32\WLDAP32.dll
0x6d450000 - 0x6d468000  F:\Program Files\Java\jre1.5.0_05\bin\jpishare.dll
0x6d640000 - 0x6d7cc000  F:\PROGRA~1\Java\JRE15~3.0_0\bin\client\jvm.dll
0x76ae0000 - 0x76b0e000  F:\WINDOWS\System32\WINMM.dll
0x5d0a0000 - 0x5d0a7000  F:\WINDOWS\System32\serwvdrv.dll
0x5b3c0000 - 0x5b3c7000  F:\WINDOWS\System32\umdmxfrm.dll
0x6d280000 - 0x6d288000  F:\PROGRA~1\Java\JRE15~3.0_0\bin\hpi.dll
0x76ba0000 - 0x76bab000  F:\WINDOWS\System32\PSAPI.DLL
0x6d610000 - 0x6d61c000  F:\PROGRA~1\Java\JRE15~3.0_0\bin\verify.dll
0x6d300000 - 0x6d31d000  F:\PROGRA~1\Java\JRE15~3.0_0\bin\java.dll
0x6d630000 - 0x6d63f000  F:\PROGRA~1\Java\JRE15~3.0_0\bin\zip.dll
0x6d000000 - 0x6d167000  F:\Program Files\Java\jre1.5.0_05\bin\awt.dll
0x72f50000 - 0x72f73000  F:\WINDOWS\System32\WINSPOOL.DRV
0x51000000 - 0x51049000  F:\WINDOWS\System32\ddraw.dll
0x73b10000 - 0x73b16000  F:\WINDOWS\System32\DCIMAN32.dll
0x5c000000 - 0x5c0c8000  F:\WINDOWS\System32\D3DIM700.DLL
 
VM Arguments:
jvm_args: -Xbootclasspath/a:F:\PROGRA~1\Java\JRE15~3.0_0\lib\deploy.jar;F:\PROGRA~1\Java\JRE15~3.0_0\lib\plugin.jar -Xmx96m -Djavaplugin.maxHeapSize=96m -Xverify:remote -Djavaplugin.version=1.5.0_05 -Djavaplugin.nodotversion=150_05 -Dbrowser=sun.plugin -DtrustProxy=true -Dapplication.home=F:\PROGRA~1\Java\JRE15~3.0_0 -Djava.protocol.handler.pkgs=sun.plugin.net.protocol -Djavaplugin.vm.options=-Djava.class.path=F:\PROGRA~1\Java\JRE15~3.0_0\classes -Xbootclasspath/a:F:\PROGRA~1\Java\JRE15~3.0_0\lib\deploy.jar;F:\PROGRA~1\Java\JRE15~3.0_0\lib\plugin.jar -Xmx96m -Djavaplugin.maxHeapSize=96m -Xverify:remote -Djavaplugin.version=1.5.0_05 -Djavaplugin.nodotversion=150_05 -Dbrowser=sun.plugin -DtrustProxy=true -Dapplication.home=F:\PROGRA~1\Java\JRE15~3.0_0 -Djava.protocol.handler.pkgs=sun.plugin.net.protocol  vfprintf
java_command: <unknown>
 
Environment Variables:
CLASSPATH=F:\Program Files\Java\jdk1.5.0_05\bin
PATH=F:\PROGRA~1\Java\JRE15~3.0_0\bin;F:\Program Files\Internet Explorer;;F:\WINDOWS\system32;F:\WINDOWS;F:\WINDOWS\system32\WBEM;F:\Perl\bin\;F:\PROGRA~1\ULTRAE~1;F:\Program Files\Fichiers communs\Ulead Systems\MPEG;F:\WINDOWS\System32;F:\Program Files\Java\jdk1.5.0_05\bin;.
USERNAME=Flo
OS=Windows_NT
PROCESSOR_IDENTIFIER=x86 Family 6 Model 10 Stepping 0, AuthenticAMD
 
 
 
---------------  S Y S T E M  ---------------
 
OS: Windows XP Build 2600 Service Pack 1
 
CPU:total 1 family 6, cmov, cx8, fxsr, mmx, sse
 
Memory: 4k page, physical 523760k(139416k free), swap 1279868k(736776k free)
 
vm_info: Java HotSpot(TM) Client VM (1.5.0_05-b05) for windows-x86, built on Aug 26 2005 15:36:02 by "java_re" with MS VC++ 6.0
 

n°15005
Memphis
Franc Archer
Profil : Habitué
Posté le 22-10-2005 à 12:49:30  profilanswer
 

up!

n°15023
Memphis
Franc Archer
Profil : Habitué
Posté le 23-10-2005 à 19:32:51  profilanswer
 

Au cas ou ca vienne de mon code je vous met, le code source de ma page html:
 

Code :
  1. <HTML>
  2. <HEAD><TITLE>Essai de ma première applet java</TITLE></HEAD>
  3. <BODY>
  4. <b><font color=0000ff>Bonjour ceci est une page html.
  5. Ci-dessous une applet java, qui permet de calculer la surface d'un rectangle
  6. puis de la dessiner.</font color=0000ff></b>
  7. <P>
  8. <APPLET CODE="Calcule_Surface_Applet.class" code= "java" WIDTH=400 HEIGHT=250>
  9.   Votre navigateur ne permet pas de visualiser les applets java.
  10. </APPLET>
  11. <P>
  12. <b><font color=0000ff>Voici le calcul de surface du rectangle, suivi du rectangle en question.</font color=0000ff></b>
  13. </BODY>
  14. </HTML>


 
et mon code source de mon applet java.
 

Code :
  1. import java.applet.*;
  2. import java.awt.*;
  3. public class Calcule_Surface_Applet {
  4. public static void paint(Graphics g) {
  5. int longueur;
  6. int hauteur;
  7. int surface;
  8. longueur=15;
  9. hauteur=10;
  10. if ((longueur<0)||(hauteur<0)) {
  11.   g.drawString("impossible de claculer la surface, une des deux grandeurs est négatives (ou les deux)",0,0) ;
  12.   }
  13. else {
  14.   surface=longueur*hauteur;
  15.   g.drawString("la surface est de:"+surface,0,0);
  16.   g.setColor(Color.red);
  17.   g.drawLine(10,10,10,20) ;
  18.   g.drawLine(10,10,25,10) ;
  19.   g.drawLine(10,20,25,20) ;
  20.   g.drawLine(25,10,25,20) ;
  21.   }
  22. }
  23. }


n°15024
Tastito
So lost in love
Profil : Dinosaure
Posté le 24-10-2005 à 03:25:08  profilanswer
 

Bon j'viens tout juste de commencer le java  et vais peut être me gourrer mais ta classe ne doit pas heriter de applet?
 
Genre : public class Calcule_Surface_Applet extends Applet  
 


---------------
"Oh, that girl, you know she really, blows my, head apart,  
And the sky and the stars, all, synkronized...  
Eh no.... No no no, now me and her,  
We are in love... "  
n°15025
Tastito
So lost in love
Profil : Dinosaure
Posté le 24-10-2005 à 04:09:17  profilanswer
 

Bon ben je viens de bidouiller un peu et j'arrive à ca :
 
http://jaykay75.free.fr/java.JPG
 
 
Mon .java
 

Code :
  1. import java.applet.*;
  2. import java.awt.*;
  3. public class Calcule_Surface_Applet extends Applet {
  4.    public void init()
  5.    {
  6.        //code d'initialistaion
  7.    }
  8.  
  9.    public void paint(Graphics g) {
  10.    // code à executer
  11.      int longueur;
  12.      int hauteur;
  13.      int surface;
  14.      longueur=15;
  15.      hauteur=10;
  16.      if ((longueur<0)||(hauteur<0)) {
  17.         g.drawString("impossible de claculer la surface, une des deux grandeurs est négatives (ou les deux)",0,0) ;
  18.        }
  19.      else {
  20.       surface=longueur*hauteur;
  21.       g.drawString("la surface est de:"+surface,0,0);
  22.       g.setColor(Color.red);
  23.    g.drawLine(10,10,10,20) ;
  24.    g.drawLine(10,10,25,10) ;
  25.    g.drawLine(10,20,25,20) ;
  26.    g.drawLine(25,10,25,20) ;
  27.      }
  28.  }
  29.  
  30.    public void stop()
  31.    {
  32.        //code de suspension de l'execution
  33.    }
  34.  
  35.    public void destroy()
  36.    {
  37.      
  38.    }
  39. }


---------------
"Oh, that girl, you know she really, blows my, head apart,  
And the sky and the stars, all, synkronized...  
Eh no.... No no no, now me and her,  
We are in love... "  
n°15052
Memphis
Franc Archer
Profil : Habitué
Posté le 24-10-2005 à 22:00:00  profilanswer
 

Salut Tastito, c' est génial ca marche, le seul truc qui me tracasse c'est que tu as employé des terme qui me sont inconnnu d'après mes cours, et j'aurai du y arriver avec ce que j'avais.
 
Enfin bon, tu as raison, et je t'en remercie.
Je vais imprimer ton code et en parler avec mon prof.
 
Je te remercie beaucoup, je vais essayer d'etudier ton code et de le comparer au mien pour voir d'ou vient le problème!!!
 
Merci beaucoup
 
Memphis

n°15053
Tastito
So lost in love
Profil : Dinosaure
Posté le 25-10-2005 à 00:16:47  profilanswer
 

Ben c'est juste des notions d'heritages, t'a vu l'heritage?? Parce que si vous faites les applets ( qu'on a tjrs pas commencer :o vive les profs absents), ben faut juste dire que ce que tu ecrit est une "sorte" d'applet. Par exemple tu peux créer une classe Objet_plan qui aura comme attribut longueur et largeur. Aprés tu peux creer une classe rectangle qui herite d'objet plan. Tu peux definir plein d'objet plan qui heritent d'objet plan. Ca permet d'implementer une fois les fonctions dans la classe mère et de les reutiliser dans la classe fille. Enfin je sais pas si j'ai était trés clair ^^ :ddr:


---------------
"Oh, that girl, you know she really, blows my, head apart,  
And the sky and the stars, all, synkronized...  
Eh no.... No no no, now me and her,  
We are in love... "  
n°15055
m@noo
je javaïse, je phpïse ^=^
Profil : Habitué
Posté le 25-10-2005 à 14:07:40  profilanswer
 

c'est le principe de l'héritage: tu hérites des propriétés (attributs) et du fonctionnement d'un objet (méthodes)
En java tous les objets héritent de l'objet Object.
 
 


Aller à :
Ajouter une réponse