Package org.apache.oro.text.regex
Class Perl5Pattern
- java.lang.Object
-
- org.apache.oro.text.regex.Perl5Pattern
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Cloneable
,Pattern
public final class Perl5Pattern extends java.lang.Object implements Pattern, java.io.Serializable, java.lang.Cloneable
An implementation of the Pattern interface for Perl5 regular expressions. This class is compatible with the Perl5Compiler and Perl5Matcher classes. When a Perl5Compiler instance compiles a regular expression pattern, it produces a Perl5Pattern instance containing internal data structures used by Perl5Matcher to perform pattern matches. This class cannot be subclassed and cannot be directly instantiated by the programmer as it would not make sense. Perl5Pattern instances should only be created through calls to a Perl5Compiler instance's compile() methods. The class implements the Serializable interface so that instances may be pre-compiled and saved to disk if desired.- Since:
- 1.0
- See Also:
Perl5Compiler
,Perl5Matcher
, Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description (package private) int
_anchor
(package private) int
_back
(package private) java.lang.String
_expression
(package private) boolean
_isCaseInsensitive
(package private) boolean
_isExpensive
(package private) int
_minLength
(package private) char[]
_mustString
(package private) int
_mustUtility
(package private) int
_numParentheses
(package private) static int
_OPT_ANCH
(package private) static int
_OPT_ANCH_BOL
(package private) static int
_OPT_ANCH_MBOL
(package private) static int
_OPT_IMPLICIT
(package private) static int
_OPT_SKIP
(package private) int
_options
(package private) char[]
_program
(package private) int
_startClassOffset
(package private) char[]
_startString
private static long
serialVersionUID
-
Constructor Summary
Constructors Constructor Description Perl5Pattern()
A dummy constructor with default visibility to override the default public constructor that would be created otherwise by the compiler.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getOptions()
This method returns an integer containing the compilation options used to compile this pattern.java.lang.String
getPattern()
This method returns the string representation of the pattern.
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
- See Also:
- Constant Field Values
-
_OPT_ANCH_BOL
static final int _OPT_ANCH_BOL
- See Also:
- Constant Field Values
-
_OPT_ANCH_MBOL
static final int _OPT_ANCH_MBOL
- See Also:
- Constant Field Values
-
_OPT_SKIP
static final int _OPT_SKIP
- See Also:
- Constant Field Values
-
_OPT_IMPLICIT
static final int _OPT_IMPLICIT
- See Also:
- Constant Field Values
-
_OPT_ANCH
static final int _OPT_ANCH
- See Also:
- Constant Field Values
-
_expression
java.lang.String _expression
-
_program
char[] _program
-
_mustUtility
int _mustUtility
-
_back
int _back
-
_minLength
int _minLength
-
_numParentheses
int _numParentheses
-
_isCaseInsensitive
boolean _isCaseInsensitive
-
_isExpensive
boolean _isExpensive
-
_startClassOffset
int _startClassOffset
-
_anchor
int _anchor
-
_options
int _options
-
_mustString
char[] _mustString
-
_startString
char[] _startString
-
-
Method Detail
-
getPattern
public java.lang.String getPattern()
This method returns the string representation of the pattern.- Specified by:
getPattern
in interfacePattern
- Returns:
- The original string representation of the regular expression pattern.
-
getOptions
public int getOptions()
This method returns an integer containing the compilation options used to compile this pattern.- Specified by:
getOptions
in interfacePattern
- Returns:
- The compilation options used to compile the pattern.
-
-