O'Reilly logo

Beginning Java 8 Fundamentals: Language Syntax, Arrays, Data Types, Objects, and Regular Expressions by Kishori Sharan

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CHAPTER 14

image

Regular Expressions

In this chapter, you will learn

  • How to create regular expressions
  • How to use convenience methods in the String class to perform regular expression-based find-and-replace
  • How to use the Pattern class to compile regular expressions
  • How to use the Matcher class to match a regular expression against an input string
  • How to use groups in regular expressions
  • How to perform advanced find-and-replace using the Matcher class

What Is a Regular Expression?

A regular expression is a way to describe a pattern in a sequence of characters. The pattern may be used to validate the sequence of characters, to search through the sequence ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required