Package org.exist.xquery

Examples of org.exist.xquery.LocalVariable


  public Sequence eval(Sequence contextSequence, Item contextItem) throws XPathException {
//    System.out.println("enter "+toString());//+" : contextItem = "+contextItem.toString());//TODO: remove
   
        // Save the local variable stack
        LocalVariable mark = context.markLocalVariables(false);

    Sequence value = null;
    for (Entry<String, WithParam> entry : params.entrySet()) {
      value = entry.getValue().eval(contextSequence, contextItem);

            // Declare the iteration variable
            LocalVariable var = new LocalVariable(entry.getValue().getName());
//            var.setSequenceType(sequenceType);
            context.declareVariableBinding(var);
            var.setValue(value);
    }
   
    XSLStylesheet xslt = getXSLContext().getXSLStylesheet();

    Sequence result = xslt.template(name, contextSequence, contextItem);
View Full Code Here


    Sequence result = new ValueSequence();
     
        context.pushDocumentContext();

        LocalVariable mark = context.markLocalVariables(false);
        try {
      Sequence selected;
        if (select == null) {
          selected = anyChild.eval(contextSequence, contextItem);
        } else {
View Full Code Here

        }

        // save some context properties
        evalContext.pushNamespaceContext();

        final LocalVariable mark = evalContext.markLocalVariables(false);

        final DocumentSet oldDocs = evalContext.getStaticallyKnownDocuments();
        if(exprContext != null) {
            evalContext.setStaticallyKnownDocuments(exprContext.getDocumentSet());
        }
View Full Code Here

        Sequence result = null;
        // Try to evaluate try-code
        try {
            context.pushDocumentContext();
            final LocalVariable mark = context.markLocalVariables(false);

            try {
                // Actually execute try-code
                result = getArgument(1).eval(contextSequence, contextItem);
                return result;
View Full Code Here

TOP

Related Classes of org.exist.xquery.LocalVariable

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.