source 2 « Development « Java I/O Q&A





2. External source file    forums.oracle.com

3. Java Source File Editor - Which you would Recommend    forums.oracle.com

shamrock08 wrote: Hi Lads. Im looking for a good source file editor and am wondering what you would recommend? Will only be using it for developing simple test programs (for study purposes) - at the moment. I dont mind splashing out a few Euros either. Many Thanks I would stick with notepad (or whatever is the simplest text editor your OS ...

4. source code file name?    forums.oracle.com

Hi jwenting, Unless MAYBE it's a bunch auto-generated classes for which the sourcefiles are thrown away (used only to feed a compiler) in which case automatic name generation might be easier using just a numeric sequence rather than trying to extract the name from the source stream. That's good additional information you provided about which I had not the slightest knowledge.Thanks!. ...

6. File not moving source to destination folder    forums.oracle.com

Hi All, private void moveFile(String fileName) throws Exception { boolean flag = false; File src = new File(sourceDir + fileName); File dst = new File(moveDir + fileName); if(dst.exists()){ dst.delete(); dst = null; dst = new File(moveDir + fileName); } flag=src.renameTo(new File(moveDir + fileName)); if(flag == true){ flag = src.delete(); } } When i am try call this method using scheduler File ...

9. Reading Source Files    forums.oracle.com

Well, it probably depends on what you want to do once you have parsed the java files. You can try to leverage Eclipse's AST API, which provides support for parsing and rewriting. The major downside is that it's quite complicated to get everything up and running (at least if you are not initimately familiar with Eclipse and OSGi).





10. compiling source files    forums.oracle.com

Gen.Java wrote: georgemc wrote: Why do they need to be in the same package? Because their methods may need to call each other and if they are in different packages, they have to be declared public and I wanted to avoid making methods public. Well, I don't really see how you're testing the differences between them if they're calling methods on ...

11. Not able to find the source files for org.w3x Node.java Nodelist.java    forums.oracle.com

hey guys, Im deploying an applet on a users network that only has 1.4.2, and the xml parsing files node.java and nodelist.java are needed. I would like to add the files to my source code myself but i am unable to find them anywhere within my jdeveloper files. I keep finding stubbs. Where might I be able to find these? Thanks ...

12. javac: Different -Xlint options to different source files    forums.oracle.com

Let's say I have two source files A.java and B.java. They reference each other, so when I compile one, the other gets compiled automatically. I want A.java to be compiled with option "-Xlint:all". I want B to be compiled with "-Xlint:all,-fallthrough". How is that possible? If I write "javac -Xlint:all A.java", then B.java gets compiled as well, but with the wrong ...

13. Excluding source files from compilation    forums.oracle.com

14. Moved source file - problem    forums.oracle.com

15. opening java source files from the web    forums.oracle.com

Hello, I was wondering if someone can tell me how to eliminate using Visual Studio to open java source file links from the web. Is there a way to set it up so that when I click on a link on a web page that is a java source file that maybe notepad or textpad or jGrasp opens?





17. PLEASE HELP N00B!! empty output file i have source    forums.oracle.com

// Create a new file output stream // connected to "myfile.txt" PrintWriter pw = new PrintWriter ( new BufferedWriter( new FileWriter("Foobar.java"))); // declare a file output object // declare a print stre p = new PrintStream( out ); // Connect print stream to the output stream System.out.println( "Choose the correct option to create appropriate method(s) for each variable found n"); System.out.println("****Menu****"); ...

18. Source for a Scanner File    forums.oracle.com

19. Download Java source files from VSS    forums.oracle.com

yup.plugin installed for vss The one I used (briefly) didn't give the option of importing, there was a VSS View. Don't know if you're using the same one, though. It was pretty flaky, too, and didn't always work. You're probably better off using the Microsoft VSS client to check the projects out, and then using "Import existing projects into workspace". That's ...

21. Open Source API for Flat Files?    forums.oracle.com

I did some searches on SourceForge for a flat-file serializer and deserializer. I know flat files are simple, but I did want to find something that allowed schema-like validations to be declared and enforced. The projects I saw were either abandoned or too simple. Does anyone know of a good open source flat file API? Thanks! - Saish

22. javac file assumptions on interdependent sources with/without package dcl    forums.oracle.com

For example, if I have A.java and B.java, and each references the other's class, if they do not have the package statement then "javac A.java" or "javac B.java" will result in succesful compilation. However, if they have a package declaration (for the same package name) then both of these files must be given to the compiler, otherwise unknown symbol errors will ...

23. File Transfer using Transferto() function:File not deleted from source    forums.oracle.com

boolean success=true; FileInputStream fIn; FileOutputStream fOut; FileChannel fIChan, fOChan; long fSize; File dest = new File(destination); if(dest.exists()) dest.delete(); try{ fIn = new FileInputStream(source); fOut = new FileOutputStream(destination); fIChan = fIn.getChannel(); fOChan = fOut.getChannel(); fSize = fIChan.size(); fIChan.transferTo(0,fSize,fOChan); fIChan.close(); fIn.close(); fOChan.close(); fOut.close(); success = dest.exists(); if(success=true) { Thread.sleep(5000); File src = new File(source); success = src.delete(); } } catch (IOException exc){ System.out.println("IOException" ...

24. Source of Active Directory    forums.oracle.com