log4j.properties basic examples

  • 09 February 2017
  • ADM

log4j.properties basic examples. Output to the console and to the file.


How to make a file read only in Java

  • 26 January 2017
  • ADM

How to make a file read-only in Java. Simple example using File.setReadOnly() and File.setWritable(boolean) methods.


How to decompress files from ZIP format using Java

  • 25 January 2017
  • ADM

How to decompress files from ZIP format using Java. The example will unzip all files to a specific folder.


How to compress files in ZIP format using Java

  • 24 January 2017
  • ADM

How to compress files in ZIP format using Java. The example takes a folder or file and adds all the files and sub-folders.


How to copy directory in Java

  • 21 January 2017
  • ADM

How to copy a directory and all sub-directories or files in Java. The recursive method used to traverse all the subdirectories.


How to display the content of a directory in Java

  • 20 January 2017
  • ADM

How to display the content of a directory in Java. Recursive method used to display all the sub-folders structure.