What is the Java equivalent of JavaScript\'s String.match()
String.match()
I need to get an array or a list of all matches
Example:
var str = \
Take a look at the Pattern and Matcher classes in the regex package. Specifically the Matcher.find method. That does not return an array, but you can use it in a loop to iterate through all matches.
Pattern
Matcher
regex
Matcher.find