Pattern (Java Platform SE 6) Java.lang.Object java.util.regex.Pattern All Implemented Interfaces: Serializable public final class Patternextends Objectimplements Serializable A compiled representation of a regular expression. A regular expression, specified as a string, must first be compiled into an instance of this class. The resulting pattern can then be used to create a Matcher object that can match arbitrary character sequences against the regular expression. A typical invocation sequence is thus Pattern p = Pattern.compile("a*b"); Matcher m = p.matcher("aaaaab"); boolean b = m.matches(); A matches method is defined by this class as a convenience for when a regular expression is used just once. Boolean b = Pattern.matches("a*b", "aaaaab"); is equivalent to the three statements above, though for repeated matches it is less efficient since it does not allow the compiled pattern to be reused.
Instances of this class are immutable and are safe for use by multiple concurrent threads. Summary of regular-expression constructs. String (Java Platform SE 6) Java.lang.Object java.lang.String All Implemented Interfaces: Serializable, CharSequence, Comparable<String> public final class Stringextends Objectimplements Serializable, Comparable<String>, CharSequence The String class represents character strings. All string literals in Java programs, such as "abc", are implemented as instances of this class. Strings are constant; their values cannot be changed after they are created. String str = "abc"; is equivalent to: char data[] = {'a', 'b', 'c'}; String str = new String(data); Here are some more examples of how strings can be used: System.out.println("abc"); String cde = "cde"; System.out.println("abc" + cde); String c = "abc".substring(2,3); String d = cde.substring(1, 2); The class String includes methods for examining individual characters of the sequence, for comparing strings, for searching strings, for extracting substrings, and for creating a copy of a string with all characters translated to uppercase or to lowercase.
Since: See Also: String. Overview (Java Platform SE 6) Bare Bones Guide to HTML. Version 4.0 Formatted -- February 1999 The latest version of this document is available at where you will also find the text version, translations, and background materials. The Bare Bones Guide to HTML lists all the tags that current browsers are likely to recognize.
I have included all the elements in the official HTML 4.0 recommendation with common attributes, as well as Netscape and Microsoft extensions. This document is a quick reference, not a complete specification; for official information about HTML and its development, see the World Wide Web Consortium site at The Guide is designed to be as concise as possible, and therefore it doesn't go into any detail about how to use the various tags. Table of Contents. JavaScript String Object.