🌐
Oracle
docs.oracle.com › javase › 8 › docs › api › java › lang › String.html
String (Java Platform SE 8 )
1 week ago - The Java language provides special support for the string concatenation operator ( + ), and for conversion of other objects to strings. String concatenation is implemented through the StringBuilder(or StringBuffer) class and its append method. String conversions are implemented through the ...
🌐
W3Schools
w3schools.com › java › java_ref_string.asp
Java String Methods
assert abstract boolean break byte case catch char class continue default do double else enum exports extends final finally float for if implements import instanceof int interface long module native new package private protected public return requires short static super switch synchronized this throw throws transient try var void volatile while Java String Methods
Discussions

Java String Methods - You Need To Know

First method of the article is charAt... Great start! Then you realise this is probably every method available order alphabetically... This could be reduce to a "5 methods to know" to be really interesting.

More on reddit.com
🌐 r/programming
1
0
October 6, 2018
ELI5:What is a "String" in Java/programming and why is it known as a "complex added type" and other variable are known as "primitive" ?
In simplest terms, a String is an collection (referred to in programming as an "array") of characters. If you wanted to have a String that said "Reddit", it would literally be an array of character values ['R', 'e', 'd', 'd', 'i', 't']. The most fundamental difference between strings and primitive types such as "int" are that primitives are single values. Strings are collections of values (specifically, a collection of characters.) Characters themselves are primitive types. In addition, primitive types are pieces of data. Strings are objects, which are instances of classes. As far as classes go...basically, the people who made Java built a lot of code so Strings could be easy to use by programmers. (This is also why "String" is capitalized: the name of the class has a capital S.) Sorry if this is too technical...but it should answer your questions. More on reddit.com
🌐 r/explainlikeimfive
5
1
November 21, 2015
New Methods on Java Strings With JDK 11

Looks like they're taking the awful PHP "real_escape_string" approach to API development of finding increasingly strained synonyms when something needs to be fixed by making the Unicode-aware version of String.trim() be named String.strip() instead of just adding an overload for trim() that takes an option parameter to specify the trimming type.

A hypothetical alternative of trim(StringTrimOptions options), used as in these examples:

// First two are equivalent, and use the backward-compatible
// pre-existing trimming logic
str.trim();
str.trim(StringTrimOptions.ASCII_WHITESPACE);

// This example uses new Unicode-compatible trimming logic.
str.trim(StringTrimOptions.UNICODE_WHITESPACE);

... would be a much better solution that wouldn't require every developer going forward, in perpetuity, to have to discover what the non-obvious difference between trim() and strip() is (whereas the hypothetical StringTrimOptions alternative is self-explanatory to a large extent); and is forward-compatible should the need ever arise in the future for yet another type of string trimming.

(And with the isBlank() method being added too, which could probably also benefit from being able to specify the type of whitespace; maybe instead of StringSplitOptions the argument should be WhitespaceType instead so an overload ofisBlank() could read correctly with it too.)

More on reddit.com
🌐 r/programming
16
30
May 3, 2018
New Methods on Java Strings With JDK 11
JDK 11 will probably be bringing a few new methods to the String class! Most of them focus on redefining white space for a… More on reddit.com
🌐 r/java
74
110
May 3, 2018
🌐
GeeksforGeeks
geeksforgeeks.org › java › java-string-methods
Java String Methods - GeeksforGeeks
Java String methods are built-in functions provided by the String class to perform various operations on strings. These methods help in manipulating, comparing, searching, and formatting text efficiently.
Published   May 30, 2026
🌐
Codecademy
codecademy.com › learn › spring-apis-java-ii › modules › learn-java-string-methods › cheatsheet
Java II: String Methods Cheatsheet | Codecademy
This method returns a String representing the text of the combined strings. ... In Java, the equals() string method tests for equality between two Strings.
🌐
BeginnersBook
beginnersbook.com › 2013 › 12 › java-strings
Java – String Class and Methods with examples
public static String join(): This method joins the given strings using the specified delimiter and returns the concatenated Java String
🌐
Medium
medium.com › @salvipriya97 › commonly-used-string-functions-in-java-343543b06132
Commonly used String functions in Java | by Priya Salvi | Medium
January 3, 2024 - The implementation of the String class in Java uses a char array to store the sequence of characters. Operations like concatenation and substring involve creating new String objects, but the original string remains unchanged due to immutability.
🌐
Programiz
programiz.com › java-programming › library › string
Java String Methods | Programiz
Java has a lot of String methods that allow us to work with strings. In this reference page, you will find all the string methods available in Java.
Find elsewhere
🌐
Oracle
docs.oracle.com › en › java › javase › 17 › docs › api › java.base › java › lang › String.html
String (Java SE 17 & JDK 17)
April 21, 2026 - Returns a string whose value is this string, with escape sequences translated as if in a string literal. ... This method does not translate Unicode escapes such as "\u2022". Unicode escapes are translated by the Java compiler when reading input characters and are not part of the string literal specification.
🌐
Particlesin
particlesin.com › course › java-built-in-methods
Java String Methods – Introduction & Commonly Used Methods | Study Plan | Particles In
Here are some important methods you’ll use frequently: Returns the total number of characters in the string. ... Returns the character at the given position (index starts from 0). ... Converts all characters to uppercase or lowercase. ... String text = "hello"; System.out.println(text.toUpperCase()); // Output: HELLO System.out.println(text.toLowerCase()); // Output: hello · Used to compare two strings for equality. ... String a = "Java"; String b = "java"; System.out.println(a.equals(b)); // false System.out.println(a.equalsIgnoreCase(b)); // true
🌐
Oracle
docs.oracle.com › en › java › javase › 11 › docs › api › java.base › java › lang › String.html
String (Java SE 11 & JDK 11 )
January 20, 2026 - Constructs a new String by decoding the specified subarray of bytes using the specified charset. The length of the new String is a function of the charset, and hence may not be equal to the length of the subarray. This method always replaces malformed-input and unmappable-character sequences with this charset's default replacement string.
🌐
Codecademy
codecademy.com › learn › learn-java › modules › learn-java-string-methods › cheatsheet
Learn Java: String Methods Cheatsheet | Codecademy
This method returns a String representing the text of the combined strings. ... In Java, the equals() string method tests for equality between two Strings.
🌐
Tutorialspoint
tutorialspoint.com › java › java_strings.htm
Java - String Class
Note − The String class is immutable, so that once it is created a String object cannot be changed. If there is a necessity to make a lot of modifications to Strings of characters, then you should use String Buffer & String Builder Classes. Methods used to obtain information about an object are known as accessor methods.
🌐
Great Learning
mygreatlearning.com › blog › it/software development › string methods java: a guide to java strings with examples
String Methods Java: A Guide To Java Strings With Examples
October 24, 2024 - static String valueOf(int value)- It is an overloaded method to convert the given type into a string. Let us check some examples of string functions in Java.
🌐
Medium
medium.com › @sunil17bbmp › 15-essential-java-string-methods-every-developer-must-know-2e814f5d77f6
15 Essential Java String Methods Every Developer Must Know | by Code With Sunil | Code Smarter, not harder | Medium
February 23, 2026 - Java provides many built-in String methods that make it easy to perform common operations such as concatenation, comparison, searching, and manipulation.
🌐
W3Schools
w3schools.com › JAVA › java_strings.asp
Java Strings
A String in Java is actually an object, which means it contains methods that can perform certain operations on strings.
🌐
DEV Community
dev.to › arshisaxena26 › strings-basic-methods-in-java-interview-essentials-1k99
Strings: Basic Methods in Java-Interview Essentials - DEV Community
January 10, 2025 - It’s a handy method when you want to check for equality without worrying about uppercase or lowercase differences. ... Converting a string to all lowercase or uppercase is a common task, and Java provides built-in methods to do this.
🌐
Medium
beknazarsuranchiyev.medium.com › string-class-and-its-methods-in-java-147b7aedc3a9
String class and its methods in Java | by Beknazar | Medium
June 15, 2022 - String class and its methods in Java java.lang.String is the most used class in Java. It’s important to understand and be able to manipulate strings fluently. String Class String Methods Comparing …
🌐
Medium
medium.com › @dhanushahasheel › string-methods-in-java-83a601f5b2ef
String Methods in JAVA
November 6, 2025 - String Methods in JAVA · Java provides a variety of built-in features for the String class to help us implement and analyze strings effectively and efficiently. · The following string methods are …
🌐
Crio
crio.do › blog › string-methods-in-java
10 Important String Methods In Java You Must Know
October 20, 2022 - Useful and important methods in Java. indexOf, toCharArray, charAt, concat, replace, substring, split, compareTo, strip, valueOf