Examples of XString


Examples of org.apache.xpath.objects.XString

     * See above.
     */
    public static XString dayAbbreviation()
    {
      String format = "EEE";
      return new XString(getNameOrAbbrev(format));             
    }
View Full Code Here

Examples of org.apache.xpath.objects.XString

    String s1 = m_arg0.execute(xctxt).str();
    String s2 = m_arg1.execute(xctxt).str();
    int index = s1.indexOf(s2);

    return (-1 == index)
           ? XString.EMPTYSTRING : new XString(s1.substring(0, index));
  }
View Full Code Here

Examples of org.apache.xpath.objects.XString

        // Needs to return the version number of the spec we conform to.
        return new XNumber(1.0);
      }
      catch (Exception ex)
      {
        return new XString(result);
      }
    }
    else
      return new XString(result);
  }
View Full Code Here

Examples of org.apache.xpath.objects.XString

      // already made.
      int tokenQueuePos = m_queueMark - 1;

      m_ops.m_tokenQueue.setElementAt(null,tokenQueuePos);

      Object obj = new XString(m_token.substring(1, last));

      m_ops.m_tokenQueue.setElementAt(obj,tokenQueuePos);

      // lit = m_token.substring(1, last);
      m_ops.setOp(m_ops.getOp(OpMap.MAPINDEX_LENGTH), tokenQueuePos);
View Full Code Here

Examples of org.apache.xpath.objects.XString

        return XString.EMPTYSTRING;
    }
    else
      return XString.EMPTYSTRING;
   
    return ((null == s) ? XString.EMPTYSTRING : new XString(s));
  }
View Full Code Here

Examples of org.apache.xpath.objects.XString

//        int owner = dtm.getDocument();
//        fileLocation = xctxt.getSourceTreeManager().findURIFromDoc(owner);
      }
    }

    return new XString((null != fileLocation) ? fileLocation : "");
  }
View Full Code Here

Examples of xbird.xquery.dm.value.literal.XString

        super(arg0);
    }

    public void testEval() throws XQueryException {
        SequenceExpression seq = new SequenceExpression();
        AtomicValue it1 = new XString("1");
        AtomicValue it2 = new XString("2");
        seq.addExpression(new LiteralExpr(it1));
        seq.addExpression(new LiteralExpr(it2));
        Sequence<Item> res = (Sequence<Item>) seq.eval(null, new DynamicContext(new StaticContext()));
        Iterator<Item> resItor = res.iterator();
        assertTrue(resItor.hasNext());
View Full Code Here

Examples of xbird.xquery.dm.value.literal.XString

    }

    @SuppressWarnings("unchecked")
    public Sequence eval(Sequence<? extends Item> contextSeq, ValueSequence argv, DynamicContext dynEnv)
            throws XQueryException {
        return new XString(expected);
    }
View Full Code Here

Examples of xbird.xquery.dm.value.literal.XString

        // If $qname is the empty sequence, returns the empty sequence.
        Item firstItem = argv.getItem(0);
        if(firstItem.isEmpty()) {
            return ValueSequence.EMPTY_SEQUENCE;
        }
        XString qname = (XString) firstItem;
        String qnameStr = qname.getValue();
        final int pos = qnameStr.indexOf(':');
        final String nsuri;
        if(pos == -1) {
            // If the $qname has no prefix, and there is no namespace binding for $element
            // corresponding to the default (unnamed) namespace, then the resulting expanded-QName
View Full Code Here

Examples of xbird.xquery.dm.value.literal.XString

                final String sv = ((XQNode) firstItem).stringValue();
                ret = XString.valueOf(sv);
            } else if(firstItem instanceof AtomicValue) {
                // If $arg is an atomic value, then the function returns the same string as
                // is returned by the expression "$arg cast as xs:string".
                final XString sv = ((AtomicValue) firstItem).<XString> castAs(StringType.STRING, dynEnv);
                ret = sv;
            } else {
                argItor.closeQuietly();
                throw new IllegalStateException("Illegal argument type: "
                        + arg.getClass().getName());
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.