Become a Better Programmer!

Sven Woltmann
Receive regular tips about Java programming, algorithms and data structures!
Unsubscribe whenever you want. Read my Privacy Policy.
ByteBuffer How to use flip() and compact() - Feature image Java ByteBuffer: How to use flip() and compact()

In this article, I show you (using an example) how the Java ByteBuffer works, and what precisely the Methoden flip() and compact() do.

Read more »
FileChannel, ByteBuffer, Memory-mapped I/O, Locks - Feature image Java files, part 6: FileChannel, ByteBuffer, Memory-mapped I/O, Locks

In this article, I explain the NIO classes FileChannel and ByteBuffer introduced in Java 1.4.

Moreover, I show what possibilities they provide to read and write files and what their advantages are – compared to the methods discussed before.

Read more »
Writing and reading structured data - feature image Java files, part 5: Writing and reading structured data: DataOutputStream, DataInputStream

In this fifth part of the series, you will learn how to write and read structured data with DataOutputStream, DataInputStream, ObjectOutputStream, and ObjectInputStream.

Read more »
Listing directory contents, moving, copying, deleting files - feature image Java files, part 4: Listing directory contents / Moving, copying, deleting files

This fourth part of the series describes the most important directory and file operations.

You will learn how to list files in a directory, how to search for files, how to move, rename, and copy files, and much more.

Read more »
Java files - constructing file and directory names with File, Path, Paths - Feature image Java files, part 3: Constructing file and directory names (with File, Path, and Paths)

This third part of the series of articles shows how to use the classes File, Path, and Paths to construct file and directory paths – regardless of the operating system.

Read more »
Java files - Basics: writing files - Feature image Java files, part 2: How to write files quickly and easily

This second part introduces methods for writing small and large text and binary files in Java.

After reading this article, you will know exactly when to use FileWriter, FileOutputStream, OutputStreamReader, BufferedOutputStream, and BufferedWriter.

Read more »
Java files - Basics: reading files - Feature image Java files, part 1: How to read files easily and fast

This article introduces methods for reading and writing files in Java.

After reading this article, you will know exactly when to use FileReader, FileInputStream, InputStreamReader, BufferedInputStream, and BufferedReader.

Read more »
How to convert String to int in Java - feature image How to Convert String to Int in Java – Peculiarities and Pitfalls

In today's article you will learn which methods you have to parse a String to an int in Java, and what you have to consider when using these methods.

Read more »
Convert int to String Java fastest method - feature image How to Convert Int to String in Java – the Fastest Way

In this article I will show you the fastest method to convert an int to a String in Java. You will be surprised!

Read more »
Jenkins tutorial: Implementing a seed job - feature image Jenkins Tutorial: Implementing a Seed Job

In this concluding third part of the Jenkins series, you'll learn how to extract duplicated Groovy code into utility classes and how you can automatically create Jenkins jobs for new Java projects in the Git monorepo.

Read more »