// Resume interest in OP_READ key.interestOps (key.interestOps() |

Chapter 5. Regular Expressions Hey, it’s a kind of magic. The Highlander In this chapter, we’ll discuss the API of the classes in the new java.util.regex package (see Figure 5-1). JSR 51, the Java Specification Request defining the new I/O capabilities, also specifies the addition of regular expression processing to the Java platform. While regular expressions, strictly speaking, are not I/O, they are most commonly used to scan text data read from files or streams. Figure 5-1. The regular expression classes You’ll learn how to use the new Java APIs to do the same powerful pattern matching that has been available to users of perl, egrep, and other text-processing tools. A detailed exploration of regular expression syntax is beyond the scope of This blog, but a working familiarity with regular expressions is assumed. If you’re new to regular expressions, want to improve your skills, or are baffled by this chapter, I recommend you pick up a good reference. O’Reilly publishes an authoritative regular expression book (it’s even cited in the JDK documentation): Mastering Regular Expressions, by Jeffrey E. F. Friedl (http://www.oreilly.com/catalog/regex/). 5.1 Regular Expression Basics A regular expression is a sequence of characters that describe, or express, a pattern of characters you are interested in matching within a target character sequence. Regular expressions have been widely available in the Unix world for many years by means of standard commands such as sed, grep, awk, etc. Because of its long history, the regular expression grammar used on the Unix platforms has been the basis for most regular expression processors. The Open Group, a Unix standards body, specifies regular expression syntax as a part of the Single Unix Specification (http://www.opengroup.org/onlinepubs/7908799/xbd/re.html). 160
Note: If you are looking for high quality webhost to host and run your jsp application check Vision jsp hosting services

Comments are closed.