Package org.apache.openjpa.lib.util

Examples of org.apache.openjpa.lib.util.SimpleRegex


        // and '.*' for '*'
        String wild = args[0].toString().replace('?', '.');
        for (int st = 0, i; (i = wild.indexOf("*", st)) != -1; st = i + 3)
            wild = wild.substring(0, i) + "." + wild.substring(i);

        SimpleRegex re = new SimpleRegex(wild, false);
        return (re.matches(target.toString())) ? Boolean.TRUE : Boolean.FALSE;
    }
View Full Code Here


        // now translate from the single and multi character escape
        // sequences into an escape that conforms to the regexp syntax
        str = Strings.replace(str, _multi, ".*");
        str = Strings.replace(str, _single, ".");

        SimpleRegex re = new SimpleRegex(str, uncase);
        boolean matches = re.matches(o1.toString());
        return _affirmation ? matches : !matches;
    }
View Full Code Here

TOP

Related Classes of org.apache.openjpa.lib.util.SimpleRegex

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.