Package org.apache.commons.jxpath

Examples of org.apache.commons.jxpath.Pointer.asPath()


                    }
                    JXPathContext localJXPathContext =
                        jxpathContextFactory.newContext(null, value);
                    AttributesImpl attrs = new AttributesImpl();
                    attrs.addAttribute(NS, "ref", "ref", "CDATA",
                                       ptr.asPath());
                    consumer.startElement(NS, "item", "item",
                                          attrs);
                    String path = "";
                    if (contextPath != null) {
                        path = contextPath + "/.";
View Full Code Here


                                          attrs);
                    String path = "";
                    if (contextPath != null) {
                        path = contextPath + "/.";
                    }
                    path += ptr.asPath();
                    execute(consumer,
                            form,
                            currentView,
                            ptr.asPath(),
                            localJXPathContext,
View Full Code Here

                    }
                    path += ptr.asPath();
                    execute(consumer,
                            form,
                            currentView,
                            ptr.asPath(),
                            localJXPathContext,
                            startItemSet.next,
                            startItemSet.endItemSet);
                    consumer.endElement(NS, "item", "item");
                }
View Full Code Here

                    Iterator iter = ref.iteratePointers(jxpathContext);
                    while (iter.hasNext()) {
                        Pointer ptr = (Pointer)iter.next();
                        AttributesImpl attrs = new AttributesImpl();
                        attrs.addAttribute(NS, REF, REF, "CDATA",
                                           ptr.asPath());
                        consumer.startElement(NS, VALUE, VALUE, EMPTY_ATTRS);
                        Object val = ptr.getNode();
                        String str = String.valueOf(val);
                        consumer.characters(str.toCharArray(), 0, str.length());
                        consumer.endElement(NS, VALUE, VALUE);
View Full Code Here

                        currentContext.getRelativeContext(ptr);
                    String path = "";
                    if (contextPath != null) {
                        path = contextPath + "/.";
                    }
                    path += ptr.asPath();
                    execute(consumer,
                            form,
                            currentView,
                            path,
                            rootContext,
View Full Code Here

                    Pointer ptr = (Pointer)iter.next();
                    JXPathContext localJXPathContext =
                        currentContext.getRelativeContext(ptr);
                    AttributesImpl attrs = new AttributesImpl();
                    attrs.addAttribute(null, REF, REF, "CDATA",
                                       ptr.asPath());
                    consumer.startElement(NS, ITEM, ITEM,
                                          attrs);
                    String path = "";
                    if (contextPath != null) {
                        path = contextPath + "/.";
View Full Code Here

                                          attrs);
                    String path = "";
                    if (contextPath != null) {
                        path = contextPath + "/.";
                    }
                    path += ptr.asPath();
                    execute(consumer,
                            form,
                            currentView,
                            path,
                            rootContext,
View Full Code Here

                    Pointer newRowContextPointer = repeaterContext.createPath(
                            this.rowPathForInsert + "[" + indexCount + "]");
                    JXPathContext newRowContext =
                        repeaterContext.getRelativeContext(newRowContextPointer);
                    if (getLogger().isDebugEnabled()) {
                        getLogger().debug("inserted row at " + newRowContextPointer.asPath());
                    }
                    //    + rebind to children for update
                    this.rowBinding.saveFormToModel(thisRow, newRowContext);
                    getLogger().debug("bound new row");
                    indexCount++;
View Full Code Here

                    Pointer newRowContextPointer = repeaterContext.createPath(
                            this.rowPathForInsert + "[" + indexCount + "]");
                    JXPathContext newRowContext =
                            repeaterContext.getRelativeContext(newRowContextPointer);
                    if (getLogger().isDebugEnabled()) {
                        getLogger().debug("inserted row at " + newRowContextPointer.asPath());
                    }
                    //    + rebind to children for update
                    this.rowBinding.saveFormToModel(thisRow, newRowContext);
                    getLogger().debug("bound new row");
                    indexCount++;
View Full Code Here

    }

    public String toString() {
        Pointer ptr = getContextNodePointer();
        return ptr == null ? "Empty expression context" : "Expression context [" + getPosition()
                + "] " + ptr.asPath();
    }

    /**
     * Returns the root context of the path, which provides easy
     * access to variables and functions.
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.