Package javax.xml.xquery

Examples of javax.xml.xquery.XQPreparedExpression.executeQuery()


      {
        final QName var = new QName(col);
        expression.bindObject(var, parameters.get(col), null)// null = do not override the default object mapping
      }
      // execute query
      final XQResultSequence sequence = expression.executeQuery();
      while (sequence.next())
      {
        final XQItem item = sequence.getItem();
        System.out.println(item.getItemType().getTypeName());
        System.out.println(item.getAtomicValue());
View Full Code Here


                Node requestNode = DOMUtils.parse(request.newXMLStreamReader());
                if (__log.isDebugEnabled()) {
                    __log.debug("request " + request.toString());
                }
                exp.bindItem(XQConstants.CONTEXT_ITEM, xqconn.createItemFromNode(requestNode, xqconn.createNodeType()));
                XQResultSequence result = exp.executeQuery();
                MockQueryResponseDocument response = MockQueryResponseDocument.Factory.parse(result.getSequenceAsStream());
                {
                    XmlOptions opts = new XmlOptions();
                    List<Object> errors = new ArrayList<Object>();
                    opts.setErrorListener(errors);
View Full Code Here

                }
              }
            }
            // evaluate the expression so as to initialize the variables
            try {
                exp.executeQuery();
            } catch (XQException xpee) {
              // swallow errors caused by uninitialized variables
            }
        } catch (XQException xqe) {
            __log.debug(xqe);
View Full Code Here

                funcResolver, null);
            exp.bindItem(XQConstants.CONTEXT_ITEM,
                xqconn.createItemFromNode(contextNode, xqconn.createNodeType()));

            // Execute query
            XQResultSequence result = exp.executeQuery();

            // Cast Saxon result to Java result
            Object evalResult = getResultValue(type, result);

            if ((evalResult != null) && __log.isDebugEnabled()) {
View Full Code Here

                transformer = (XQPreparedExpression) transformerPool.borrowObject();

                bindParameters(transformer, message);

                bindDocument(message.getPayload(), transformer);
                XQResultSequence result = transformer.executeQuery();
                //No support for return Arrays yet
                List<Object> results = new ArrayList<Object>();
                Class<?> type = returnType.getType();

                while (result.next())
View Full Code Here

                funcResolver, null);
            exp.bindItem(XQConstants.CONTEXT_ITEM,
                xqconn.createItemFromNode(contextNode, xqconn.createNodeType()));

            // Execute query
            XQResultSequence result = exp.executeQuery();

            // Cast Saxon result to Java result
            Object evalResult = getResultValue(type, result);

            if ((evalResult != null) && __log.isDebugEnabled()) {
View Full Code Here

                    }
                }
            }
            // evaluate the expression so as to initialize the variables
            try {
                exp.executeQuery();
            } catch (XQException xpee) {
                // swallow errors caused by uninitialized variables
            } finally {
                // reset the expression's user data, in order to avoid
                // serializing the function resolver in the compiled bpel file.
View Full Code Here

                funcResolver, null);
            exp.bindItem(XQConstants.CONTEXT_ITEM,
                xqconn.createItemFromNode(contextNode, xqconn.createNodeType()));

            // Execute query
            XQResultSequence result = exp.executeQuery();

            // Cast Saxon result to Java result
            Object evalResult = getResultValue(type, result);

            if ((evalResult != null) && __log.isDebugEnabled()) {
View Full Code Here

                }
              }
            }
            // evaluate the expression so as to initialize the variables
            try {
                exp.executeQuery();
            } catch (XQException xpee) {
              // swallow errors caused by uninitialized variables
            } finally {
              // reset the expression's user data, in order to avoid
              // serializing the function resolver in the compiled bpel file.
View Full Code Here

                }
              }
            }
            // evaluate the expression so as to initialize the variables
            try {
                exp.executeQuery();
            } catch (XQException xpee) {
              // swallow errors caused by uninitialized variables
            } finally {
              // reset the expression's user data, in order to avoid
              // serializing the function resolver in the compiled bpel file.
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.