Java Apache Commons Text Tutorial
In this Java Apache Commons Text tutorial we learn how to use the Apache Commons Text library.
In this Java Apache Commons Text tutorial we learn how to use the Apache Commons Text library.
In this post we are going to learn how to use StringEscapeUtils class in Apache Commons Text library to escape a String for CSV file format. If the input String value contains a comma, newline or double quote, then the output String value is returned enclosed in double quotes.
In this article we are going to explore Apache Commons Text library by using CaseUtils utility class to convert a String of separated words into a camelCase String.
In this post we are going to learn how to substitute a String in Java which replaces variables into placeholders in a template String. To do this task we will use the Apache Commons Text library with support of StringSubstitutor class. Via different Java example code we will learn how to apply StringSubstitutor in different scenarios in your Java applications.
In this article we will explore the WordUtils.uncapitalize() method of Apache Commons Text library to uncapitalize a String. With Java code example we will learn how to use the WordUtils.uncapitalize() method to convert the first character of all words in a String to lowercase character.
In this article we are going to learn how to swap the case of a String in Java application. We provide a Java code example to show how to use WordUtils.swapCase() method of Apache Commons Text library to swap the case of each character of a given String.
In this post we learn how to use WordUtils class of Apache Commons Text library to extract initial characters from all words of a String in Java. We will show the Java code example that uses WordUtils.initials() method to extract initial letters of people names.
In this article we show how to check if a String contains all words in an array in Java. By using WordUtils utility class of Apache Commons Text library you can check if the String contains all words in the given array using containsAllWords() method.
In this post we learn how to wrap a String in Java using WordUtils utility class of Apache Commons Text library. By using WordUtils.wrap() method we can break a long line of text into multiple lines with a given input text and the length. The output String will be wrapped words and separated by system line separator character or by your custom provided separator.
In this article we show how to generate random String values in Java using the RandomStringGenerator class of Apache Commons Text library. We provide multiple Java code examples with different settings to generate different kinds of data that may be useful for your daily programming scenarios.