Skip to Content
The Java Workshop
book

The Java Workshop

by David Cuartielles, Pradeep Kumar Gupta, Scott Cosentino, Andreas Göransson, Eric Foster-Johnson, Avinash Kate
October 2019
Beginner
606 pages
10h 37m
English
Packt Publishing
Content preview from The Java Workshop

12. Regular Expressions

Overview

This chapter discusses regular expressions and considers both how and why they are so useful in Java. To begin, you will first explore how to construct these expressions in order to search for information in your program—a fundamental skill for any developer. When you have a firm understanding of the nature and function of these regular expressions, you will be able to use them to perform simple full-body matches in your search, and, later in the chapter, to extract substrings from a text using groups and non-capturing groups. In the final exercise, you have to employ all of these skills to perform recursive matches and extract a set of similar elements (i.e. a pattern) from a text.

Introduction

In your ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Modern Java Collections

Modern Java Collections

Simon Roberts
Java By Comparison

Java By Comparison

Simon Harrer, Linus Dietz, Jörg Lenhard

Publisher Resources

ISBN: 9781838986698Supplemental Content