org.apache.xerces.impl.xpath.regex

Class REUtil


public final class REUtil
extends java.lang.Object

Version:
$Id: REUtil.java,v 1.7 2002/11/20 00:49:47 twl Exp $

Method Summary

static RegularExpression
createRegex(String pattern, String options)
Creates a RegularExpression instance.
static void
main(String[] argv)
Sample entry.
static boolean
matches(String regex, String target)
static boolean
matches(String regex, String options, String target)
static String
quoteMeta(String literal)

Method Details

createRegex

public static RegularExpression createRegex(String pattern,
                                            String options)
            throws ParseException
Creates a RegularExpression instance. This method caches created instances.

See Also:
RegularExpression.RegularExpression(java.lang.String, java.lang.String)


main

public static void main(String[] argv)
Sample entry.
Usage: org.apache.xerces.utils.regex.REUtil <regex> <string>


matches

public static boolean matches(String regex,
                              String target)
            throws ParseException

See Also:
RegularExpression.matches(java.lang.String)


matches

public static boolean matches(String regex,
                              String options,
                              String target)
            throws ParseException

See Also:
RegularExpression.matches(java.lang.String)


quoteMeta

public static String quoteMeta(String literal)


Copyright B) 1999-2004 Apache XML Project. All Rights Reserved.