Package org.exist.util

Examples of org.exist.util.FastStringBuffer


        addComponent(qn);
    }

    private void init( Map<String, String> namespaces, String path ) {
        //TODO : compute better length
        final FastStringBuffer token = new FastStringBuffer(path.length());
        int pos = 0;
        while (pos < path.length()) {
            final char ch = path.charAt(pos);
            switch (ch) {
            case '*':
                addComponent(WILDCARD);
                token.setLength(0);
                pos++;
                break;
            case '/':
                final String next = token.toString();
                token.setLength(0);
                if (next.length() > 0)
                    {addComponent(namespaces, next);}
                if (path.charAt(++pos ) == '/')
                    {addComponent(SKIP);}
                break;
            default:
                token.append(ch);
                pos++;
            }
        }
        if (token.length() > 0)
            {addComponent(namespaces, token.toString());}
    }
View Full Code Here

TOP

Related Classes of org.exist.util.FastStringBuffer

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.