Examples of XQItem


Examples of javax.xml.xquery.XQItem

                }
            }

            resultValue = list;
        } else if (XPathConstants.NODE.equals(type)) {
          XQItem item = null;
        if (result.count() > 0) {
          result.first();
          if (result.isOnItem()) {
            item = result.getItem();
          }
View Full Code Here

Examples of javax.xml.xquery.XQItem

                List<Object> results = new ArrayList<Object>();
                Class<?> type = returnType.getType();

                while (result.next())
                {
                    XQItem item = result.getItem();

                    if (Node.class.isAssignableFrom(type) || Node[].class.isAssignableFrom(type))
                    {
                        results.add(getItemValue(item));
                    }
                    else if (String.class.isAssignableFrom(type) || String[].class.isAssignableFrom(type))
                    {
                        results.add(item.getItemAsString(null));
                    }
                    else if (XMLStreamReader.class.isAssignableFrom(type) || XMLStreamReader[].class.isAssignableFrom(type))
                    {
                        try
                        {
                            results.add(item.getItemAsStream());
                        }
                        catch (XQException e)
                        {
                            throw new TransformerException(XmlMessages.streamNotAvailble(getName()));
                        }
                    }
                    else
                    {
                        //This can be a JAXB bound  object instance depending on whether the CommonHandler has been set
                        try
                        {
                            results.add(item.getObject());
                        }
                        catch (XQException e)
                        {
                            throw new TransformerException(XmlMessages.objectNotAvailble(getName()));
View Full Code Here

Examples of javax.xml.xquery.XQItem

                     try {
                         Item item = ((Value) value).asItem();
                         if (item == null) {
                             exp.bindSequence(variable, xqconn.createSequence(Collections.EMPTY_LIST.iterator()));
                         } else {
                             XQItem item2 = new SaxonXQItem(item, saxonConn);
                             exp.bindItem(variable, item2);
                         }
                     } catch (XPathException e) {
                         __log.warn("", e);
                     }
View Full Code Here

Examples of javax.xml.xquery.XQItem

                }
            }

            resultValue = list;
        } else if (XPathConstants.NODE.equals(type)) {
            XQItem item = null;
            if (result.count() > 0) {
                result.first();
                if (result.isOnItem()) {
                    item = result.getItem();
                }
View Full Code Here

Examples of javax.xml.xquery.XQItem

                     try {
                         Item item = ((Value) value).asItem();
                         if (item == null) {
                             exp.bindSequence(variable, xqconn.createSequence(Collections.EMPTY_LIST.iterator()));
                         } else {
                             XQItem item2 = new SaxonXQItem(item, saxonConn);
                             exp.bindItem(variable, item2);
                         }
                     } catch (XPathException e) {
                         __log.warn("", e);
                     }
View Full Code Here

Examples of javax.xml.xquery.XQItem

                }
            }

            resultValue = list;
        } else if (XPathConstants.NODE.equals(type)) {
          XQItem item = null;
        if (result.count() > 0) {
          result.first();
          if (result.isOnItem()) {
            item = result.getItem();
          }
View Full Code Here

Examples of javax.xml.xquery.XQItem

                     try {
                         Item item = ((Value) value).asItem();
                         if (item == null) {
                             exp.bindSequence(variable, xqconn.createSequence(Collections.EMPTY_LIST.iterator()));
                         } else {
                             XQItem item2 = new SaxonXQItem(item, saxonConn);
                             exp.bindItem(variable, item2);
                         }
                     } catch (XPathException e) {
                         __log.warn("", e);
                     }
View Full Code Here

Examples of javax.xml.xquery.XQItem

                }
            }

            resultValue = list;
        } else if (XPathConstants.NODE.equals(type)) {
          XQItem item = null;
        if (result.count() > 0) {
          result.first();
          if (result.isOnItem()) {
            item = result.getItem();
          }
View Full Code Here

Examples of javax.xml.xquery.XQItem

                }
            }

            resultValue = list;
        } else if (XPathConstants.NODE.equals(type)) {
          XQItem item = null;
        if (result.count() > 0) {
          result.first();
          if (result.isOnItem()) {
            item = result.getItem();
          }
View Full Code Here

Examples of javax.xml.xquery.XQItem

                }
            }

            resultValue = list;
        } else if (XPathConstants.NODE.equals(type)) {
          XQItem item = null;
        if (result.count() > 0) {
          result.first();
          if (result.isOnItem()) {
            item = result.getItem();
          }
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.