Top "Apache-commons-io" questions

Apache Commons IO is a library of utilities to assist with developing IO functionality.

Delete all files in directory (but not directory) - one liner solution

I want to delete all files inside ABC directory. When I tried with FileUtils.deleteDirectory(new File("C:/test/ABC/")); …

java file-io apache-commons-io
Is it safe to use Apache commons-io IOUtils.closeQuietly?

Is this code BufferedWriter bw = new BufferedWriter(new FileWriter("test.txt")); try { bw.write("test"); } finally { IOUtils.closeQuietly(bw); } safe …

java apache-commons apache-commons-io
Reading a specific line from a text file in Java

Is there any method to read a specific line from a text file ? In the API or Apache Commons. Something …

java apache-commons-io
Problems deleting a file with Java (apache commons io)

I am calling a C++ Method via JNI which creates two files. A text log file and a pdf file …

java io apache-commons apache-commons-io
Download file using java apache commons?

How can I use the library to download a file and print out bytes saved? I tried using import static …

java apache-commons-io
Failed to delete original file

we are running jar using batch file as window service and place xml files in c:/processed directory; if xml …

java apache-commons-io
Unable to copy files using FileUtils

I am trying to copy the files from one destination to another. I am unable to understand why the error …

java apache-commons-io
Apache Commons IO Tailer example

I am working on a monitoring program that reads the /var/log/auth.log file. I am using Apache Commons …

java apache-commons-io
Compress directory into a zipfile with Commons IO

I am a beginner at programming with Java and am currently writing an application which must be able to compress …

java zip apache-commons-io
Clone InputStream

I'm trying to read data from an InputStream, which could either be a FileInputStream or an ObjectInputStream. In order to …

java inputstream apache-commons apache-commons-io