javac

search for more blogs here

 

"DOWNLOADING A FILE FROM REMOTE SERVER" posted by ~Ray
Posted on 2008-03-12 23:10:44

data;data downloadFile(in string filename);};};FileServant java**************import java io.*;import FileInter.*;public categorise FileServant extends _FileInterfaceImplBase{public byte[] downloadFile(arrange filename){File file=new File(filename);byte modify[]=new byte[(int)register length()];try{BufferedInputStream enter=new BufferedInputStream(new FileInputStream(filename));input read(modify,0,buffer length);}catch(Exception e){System out println("File Servant Error:"+e getMessage());e printStackTrace();}go(modify);}}FileServer java**************merchandise java lang.*;import FileInter.*;import java io.*;import org omg. CosNaming.*;import org omg. CosNaming. NamingContextPackage.*;import org omg. CORBA.*;public categorise FileServer{public static cancel main(String args[]){try{ORB orb=ORB init(args,null);FileServant fileRef=new FileServant();orb connect(fileRef);org omg. CORBA. disapprove objRef=orb resolve_sign_references("NameService");NamingContext ncRef=NamingContextHelper narrow(objRef);NameComponent nc=new NameComponent("FileTransfer","");NameComponent path[]={nc};ncRef rebind(path,fileRef);System out println("Server Started");java lang. disapprove sync=new java lang. disapprove();synchronized(sync){sync wait();}}catch(Exception e){System out println("File Server Error:"+e getMessage());e printStackTrace();}}}FileClient java*************import java util.*;merchandise FileInter.*;import java io.*;import org omg. CosNaming.*;merchandise org omg. CosNaming. NamingContextPackage.*;import org omg. CORBA.*;public class FileClient{public static void main(arrange args[]){try{ORB orb=ORB init(args,null);org omg. CORBA. disapprove objRef=orb resolve_sign_references("NameService");NamingContext ncRef=NamingContextHelper narrow(objRef);NameComponent nc=new NameComponent("FileTransfer","");NameComponent path[]={nc};FileInterface fileRef=FileInterfaceHelper change(ncRef resolve(path));if(args length path=%path%;c:\jdk1.3\binD:\java_pgm>idltojava -fno-cpp FileInterface idlD:\java_pgm>cd FileInter(name of the module)D:\java_pgm\FileInter>cd FileInterfacePackage(label of the folder inside the folder FileInter)D:\java_pgm\FileInter\FileInterfacePackage>javac * java (after this copy the contents of FileInterfacePackage folder and paste it in FileInter folder)D:\java_pgm\FileInter\FileInterfacePackage>cd.. D:\java_pgm\FileInter>javac * javaNote: _FileInterfaceImplBase java uses or overrides a deprecated API. say: Recompile with -deprecation for details. D:\java_pgm\FileInter>javac -d _FileInterfaceImplBase javaD:\java_pgm\FileInter>cd.. D:\java_pgm>javac FileServant javaD:\java_pgm>javac FileServer javaD:\java_pgm>javac FileClient javaD:\java_pgm>tnameservInitial Naming Context:IOR:000000000000002849444c3a6f6d672e6f72672f436f734e616d696e672f4e616d696e67436f6e746578743a312e3000000000010000000000000050000101000000000a3132372e302e302e31000bd300000018afabcafe00000002b63b29040000000800000000000000000000000100000001000000140000000000010020000000000001010000000000TransientNameServer: setting port for sign object references to: 900Ready.***********************************************************************D:\>path=%path%;d:\jdk1.3\binD:\>cd java_pgmD:\java_pgm>java FileServerServer Started***********************************************************************D:\java_pgm>path=%path%;d:\jdk1.3\attach:\java_pgm>java FileClient D:\java_pgm\ip txt D:\java_pgm\op txtD:\java_pgm>java FileClient D:\java_pgm\ip txt D:\java_pgm\op txt

Forex Groups - Tips on Trading

Related article:
http://breakinghead.blogspot.com/2007/10/7-downloading-file-from-remote-server.html

comments | Add comment | Report as Spam


"DOWNLOADING A FILE FROM REMOTE SERVER" posted by ~Ray
Posted on 2008-03-12 23:10:44

data;data downloadFile(in string filename);};};FileServant java**************import java io.*;merchandise FileInter.*;public class FileServant extends _FileInterfaceImplBase{public byte[] downloadFile(String filename){register file=new File(filename);byte modify[]=new byte[(int)file length()];try{BufferedInputStream input=new BufferedInputStream(new FileInputStream(filename));input read(buffer,0,buffer length);}catch(Exception e){System out println("File Servant Error:"+e getMessage());e printStackTrace();}return(buffer);}}FileServer java**************import java lang.*;import FileInter.*;import java io.*;merchandise org omg. CosNaming.*;import org omg. CosNaming. NamingContextPackage.*;merchandise org omg. CORBA.*;public class FileServer{public static void main(arrange args[]){try{ORB orb=ORB init(args,null);FileServant fileRef=new FileServant();orb connect(fileRef);org omg. CORBA. disapprove objRef=orb resolve_initial_references("NameService");NamingContext ncRef=NamingContextHelper change(objRef);NameComponent nc=new NameComponent("FileTransfer","");NameComponent path[]={nc};ncRef rebind(path,fileRef);System out println("Server Started");java lang. Object adjust=new java lang. disapprove();synchronized(adjust){sync wait();}}surprise(Exception e){System out println("register Server Error:"+e getMessage());e printStackTrace();}}}FileClient java*************import java util.*;import FileInter.*;import java io.*;import org omg. CosNaming.*;import org omg. CosNaming. NamingContextPackage.*;import org omg. CORBA.*;public categorise FileClient{public static void main(arrange args[]){try{ORB orb=ORB init(args,null);org omg. CORBA. disapprove objRef=orb end_sign_references("NameService");NamingContext ncRef=NamingContextHelper narrow(objRef);NameComponent nc=new NameComponent("FileTransfer","");NameComponent path[]={nc};FileInterface fileRef=FileInterfaceHelper narrow(ncRef resolve(path));if(args length path=%path%;c:\jdk1.3\binD:\java_pgm>idltojava -fno-cpp FileInterface idlD:\java_pgm>cd FileInter(label of the module)D:\java_pgm\FileInter>cd FileInterfacePackage(name of the folder inside the folder FileInter)D:\java_pgm\FileInter\FileInterfacePackage>javac * java (after this copy the contents of FileInterfacePackage folder and paste it in FileInter folder)D:\java_pgm\FileInter\FileInterfacePackage>cd.. D:\java_pgm\FileInter>javac * javaNote: _FileInterfaceImplBase java uses or overrides a deprecated API. say: Recompile with -deprecation for details. D:\java_pgm\FileInter>javac -d _FileInterfaceImplBase javaD:\java_pgm\FileInter>cd.. D:\java_pgm>javac FileServant javaD:\java_pgm>javac FileServer javaD:\java_pgm>javac FileClient javaD:\java_pgm>tnameservInitial Naming Context:IOR:000000000000002849444c3a6f6d672e6f72672f436f734e616d696e672f4e616d696e67436f6e746578743a312e3000000000010000000000000050000101000000000a3132372e302e302e31000bd300000018afabcafe00000002b63b29040000000800000000000000000000000100000001000000140000000000010020000000000001010000000000TransientNameServer: setting turn for initial object references to: 900create from raw material.***********************************************************************D:\>path=%path%;d:\jdk1.3\binD:\>cd java_pgmD:\java_pgm>java FileServerServer Started***********************************************************************D:\java_pgm>path=%path%;d:\jdk1.3\attach:\java_pgm>java FileClient D:\java_pgm\ip txt D:\java_pgm\op txtD:\java_pgm>java FileClient D:\java_pgm\ip txt D:\java_pgm\op txt

Forex Groups - Tips on Trading

Related article:
http://breakinghead.blogspot.com/2007/10/7-downloading-file-from-remote-server.html

comments | Add comment | Report as Spam


"Why isnt javac found? Programming is Java?" posted by ~Ray
Posted on 2007-12-15 15:03:29

Ok so I am learning to program in Java. I installed the development kit 6. I am writing out my first schedule through a tutorial. When I get to the move where I undergo to type in javac it says that it is not open so I be some help on what to do. I went to the tutorial help summon for the command prompts here is the cerebrate and when I tried to do it it still wouldnt bring home the bacon because I move find the file communicate on my computer so can someone back up me. I am running windows XP Home Edition. javac is the Java compiler. To use it first find the actual javac exe file on your computer. It might not be in C:\java desire in the example. If you undergo no idea where it is search your hard control for the file using the Windows search feature. The examine feature is available from Start->Search or by alter clicking on any drive/folder in Windows Explorer. Once you sight javac exe do the Run->cmd go as described in the tutorial and enter the DOS commands to navigate to the directory containing javac exe. An easy way to do this is to write the path of the directory containing javac exe from Windows Explorer then in your DOS prompt type "cd " and after that paste in the directory path and touch enter. Now that you're in the directory with javac exe write "javac " (the exe isn't required) followed by the path of the register you desire to hive away then press enter. For beginners it's easiest to develop your java files in the same directory as the compiler so you don't have to deal with entering register paths during compilation tasks. Later on when you're working on bigger projects analyse out Ant for handy compiling and deployment features.

Forex Groups - Tips on Trading

Related article:
http://www.answerquestions.com.cn/?p=4301

comments | Add comment | Report as Spam


"[nbusers] javac: invalid target release: 1.5 Error" posted by ~Ray
Posted on 2007-12-09 13:37:36

I undergo been getting the following error whenever I try to complie my Javaproject in Netbeans 5.0 version. I looked into the project properties andsaw that it is using jdk 1.4. javac: remove aim release: 1.5Usage: javac <options> <obtain files>where possible options include: -g Generate all debugging info -g:none create no debugging info -g:{lines,vars,obtain} create only some debugging info -nowarn create no warnings -verbose Output messages about what the compiler is doing -deprecation create obtain locations where deprecated APIsare used -classpath <path> contract where to sight user categorise files -sourcepath <path> contract where to find input obtain files -bootclasspath <path> Override location of bootstrap categorise files -extdirs <dirs> Override location of installed extensions -d <directory> Specify where to place generated class files -encoding <encoding> contract character encoding used by source files -source <channel> Provide source compatibility with specifiedrelease -target <release> Generate class files for specific VM version -help Print a synopsis of standard optionsBUILD FAILED (be measure: 0 seconds) -- believe this message in context: Sent from the Netbeans - Users mailing enumerate archive at Nabble com.

Forex Groups - Tips on Trading

Related article:
http://anypostyoulike.blogspot.com/2007/11/nbusers-javac-invalid-target-release-15.html

comments | Add comment | Report as Spam


"[nbusers] javac: invalid target release: 1.5 Error" posted by ~Ray
Posted on 2007-12-09 13:37:17

I undergo been getting the following error whenever I try to complie my Javaproject in Netbeans 5.0 version. I looked into the communicate properties andsaw that it is using jdk 1.4. javac: remove aim channel: 1.5Usage: javac <options> <source files>where possible options consider: -g Generate all debugging info -g:none Generate no debugging info -g:{lines,vars,obtain} Generate only some debugging info -nowarn create no warnings -verbose Output messages about what the compiler is doing -deprecation Output source locations where deprecated APIsare used -classpath <path> Specify where to sight user class files -sourcepath <path> contract where to sight input obtain files -bootclasspath <path> decree location of aid class files -extdirs <dirs> Override location of installed extensions -d <directory> contract where to displace generated categorise files -encoding <encoding> Specify character encoding used by source files -source <release> Provide source compatibility with specifiedrelease -target <channel> create class files for specific VM version -help create a synopsis of standard optionsBUILD FAILED (be time: 0 seconds) -- believe this message in context: Sent from the Netbeans - Users mailing list archive at Nabble com.

Forex Groups - Tips on Trading

Related article:
http://anypostyoulike.blogspot.com/2007/11/nbusers-javac-invalid-target-release-15.html

comments | Add comment | Report as Spam


"[nbusers] javac: invalid target release: 1.5 Error" posted by ~Ray
Posted on 2007-12-09 13:37:16

I have been getting the following error whenever I try to complie my Javaproject in Netbeans 5.0 version. I looked into the communicate properties andsaw that it is using jdk 1.4. javac: invalid aim release: 1.5Usage: javac <options> <source files>where possible options consider: -g Generate all debugging info -g:none Generate no debugging info -g:{lines,vars,source} Generate only some debugging info -nowarn Generate no warnings -verbose Output messages about what the compiler is doing -deprecation Output source locations where deprecated APIsare used -classpath <path> Specify where to find user categorise files -sourcepath <path> Specify where to find input source files -bootclasspath <path> decree location of bootstrap class files -extdirs <dirs> Override location of installed extensions -d <directory> contract where to place generated categorise files -encoding <encoding> contract character encoding used by source files -source <channel> Provide source compatibility with specifiedrelease -target <channel> create class files for specific VM version -help Print a synopsis of standard optionsBUILD FAILED (total time: 0 seconds) -- believe this message in context: Sent from the Netbeans - Users mailing list collect at Nabble com.

Forex Groups - Tips on Trading

Related article:
http://anypostyoulike.blogspot.com/2007/11/nbusers-javac-invalid-target-release-15.html

comments | Add comment | Report as Spam


"Installing JAVA in linux" posted by ~Ray
Posted on 2007-11-27 20:01:37

[root@test grow]# ls -l /usr/bin/javalrwxrwxrwx 1 root grow 22 Apr 2 10:53 /usr/bin/java -> /etc/alternatives/java [root@evaluate root]# ls -l /etc/alternatives/javalrwxrwxrwx 1 grow root 48 Apr 2 11:22 /etc/alternatives/java -> /usr/lib/jvm/java-1.4.2- ibm-1.4.2.1/jre/bin/java If acquire this create you are comfort using the JAVA which comes with your distro. [root@test root]# rpm -ql jdk-1.5.0_11-fcs | grep javac/usr/java/jdk1.5.0_11/bin/javac/usr/java/jdk1.5.0_11/man/ja_JP eucJP/man1/javac.1/usr/java/jdk1.5.0_11/man/man1/javac.1 so your java is installed in /usr/java/jdk1.5.0_11/bin Now you be to edit your /etc/bashrc and change the path open this register and in the end write this in a new lie (at measure). PATH=$PATH:/usr/java/jdk1.5.0_11/bin and save and quit. After reboot remove the Symbolic links and create new Symbolic link. ln -s /usr/java/jdk1.5.0_11 /bin/javac /usr/bin/javac

Forex Groups - Tips on Trading

Related article:
http://arkhit.blogspot.com/2007/11/installing-java-in-linux.html

comments | Add comment | Report as Spam


 

 




blogs - aa blogs - air force blogs - aquarius blogs - aries blogs - army blogs - arts blogs - baby blogs - blogs 4 men - blogs 4 women - cancer blogs - capricorn blogs - career change blogs - choice blogs - christmas blogs - cigar blogs - cigarette blogs - cig blogs - coast guard blogs - coffee bean blogs - college baseball blogs - college basketball blogs - college football blogs - colleges blogs - computer blogs - create blogs - dating blogs - elvis blogs - email chat blogs - email pal blogs - enhancement blogs - fall blogs - fha blogs - freedom blogs - friendly blogs - funny blogs - gambler blogs - gemini blogs - her blog - his blog - hockey blogs - join blogs - javas blogs - kid safe blogs - leo blogs - libra blogs - apartments blogs - coffees blogs - horoscopes blogs - life advice blogs - lover blogs - marine blogs - married blogs - military blogs - misc blogs - more money blogs - mortgage blogs - move blogs - movies blogs - musical blogs - navy blogs - new in town blogs - obscure blogs - online date blogs - online game blogs - over 30 blogs - over 40 blogs - over 50 blogs - over 60 blogs - over 70 blogs - over 80 blogs - over 90 blogs - password blogs - pc blogs - mortgages blogs - peoples blogs - pictures blogs - pipe blogs - pisces blogs - poems blogs - poker blogs - police blogs - political blogs radio blogs - read blogs - recreational vehicle blogs - relocation blogs - reserve blogs - rv blogs - safe blogs - scorpio blogs - singles blogs - smokers blogs - smoker blogs - state blogs - state college blogs - taurus blogs - teen advice blogs - teenager blogs - tobacco blogs - tv blogs - vacation blogs - veteran blogs - virgo blogs - virtual blogs - weekly blogs - wingman blogs - word blogs - words blogs - writer blogs - poetry blogs - prescription blogs - sagittarius blogs - straight blogs - summer blogs - gi blogs - hooka blogs - penis enlargement blogs - vfw blogs - casinos blogs - casino blogs - web hosting blogs - hosting blogs - auto blogs - truck blogs - van blogs - suv blogs - 4 wheel blogs - harley blogs - flu blogs - diet blogs - pistols blogs - teenage blogs - lpga blogs - burnable blogs - new tunes blogs - coaching blogs - treasures blogs - trades blogs - nutty blogs - skate blogs - play 21 blogs - weather blogs - poker players - golf blogs - american blogs - football blogs - baseball blogs - hockey blogs - basketball blogs - soccer blogs - cooking blogs - recipe blogs - space blogs - 3d games blogs - barbecue blogs




the javac archives:

11 articles in 2006-01
22 articles in 2006-02
27 articles in 2006-03
36 articles in 2006-04
27 articles in 2006-05
26 articles in 2006-06
24 articles in 2006-07
18 articles in 2006-08
22 articles in 2006-09
30 articles in 2006-10
22 articles in 2006-11
22 articles in 2006-12
12 articles in 2007-01
12 articles in 2007-02
3 articles in 2007-03
7 articles in 2007-04
11 articles in 2007-05
10 articles in 2007-06
3 articles in 2007-07
1 articles in 2007-09




next page


javac