-
File

Create new empty file
This is an example of how to create a new empty File. We are using the File class that is…
Read More » -
File

Create directory
With this example we are going to demonstrate how to create a directory. We are using the File class that…
Read More » -
DataOutputStream

Write String as bytes to file with DataOutputStream
In this example we shall show you how to write a String as bytes to file with the DataOutputStream. The…
Read More » -
DataInputStream

Read char from file with DataInputStream
This is an example of how to read a char from a file with the DataInputStream. The DataInputStream lets an…
Read More » -
BufferedOutputStream

Write byte array to file with BufferedOutputStream
In this example we shall show you how to write a byte array to a file using the BufferedOutputStream. This…
Read More » -
BufferedInputStream

StreamTokenizer from BufferedReader example
This is an example of how to get and use a StreamTokenizer from a BufferedReader. The StreamTokenizer class takes an…
Read More » -
BufferedInputStream

Read file with BufferedInputStream
With this example we are going to demonstrate how to read a file with a BufferedInputStream. In short, to read…
Read More » -
io

Serialize arbitrary objects
public static byte[] serializeObject(Serializable object) throws Exception { ByteArrayOutputStream baos = null; ObjectOutputStream oos = null; byte[] res = null;…
Read More » -
ReferenceQueue

Check when an object is no longer referenced
In this example we shall show you how to check when an object is no longer referenced. To check when…
Read More » -
management

Obtain System Properties
This is an example of how to obtain the System Properties. We are using the RuntimeMXBean, that is the management…
Read More »

