Package com.btaz.datautil.xml.model

Examples of com.btaz.datautil.xml.model.XmlModelException


            return new ArrayList<Node>();
        }
        pathQuery = pathQuery.trim();

        if(! reQueryFormat.matcher(pathQuery).matches()) {
            throw new XmlModelException("Invalid pathQuery path: " + pathQuery);
        }

        //
        // build parser
        //
        List<PathQueryMatcher> queryMatchers = new ArrayList<PathQueryMatcher>();

        // extract path query components
        Matcher parts = reQueryParts.matcher(pathQuery);
        int level = 0;
        while(parts.find()) {
            String part = parts.group(1);

            Matcher nodenameMatcher = reQueryNodename.matcher(part);
            if(nodenameMatcher.matches()) {
                queryMatchers.add(new NodenameMatcher(level, part));
            } else {
                throw new XmlModelException("Invalid pathQuery path: \"" + part + "\" in: " + pathQuery);
            }
            level += 1;
        }

        //
View Full Code Here

TOP

Related Classes of com.btaz.datautil.xml.model.XmlModelException

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.