Examples of UntypedAtomicValue


Examples of net.sf.saxon.value.UntypedAtomicValue

    /**
    * Get the typed value of the item
    */

    public SequenceIterator getTypedValue(Configuration config) {
        return SingletonIterator.makeIterator(new UntypedAtomicValue(getStringValue()));
    }
View Full Code Here

Examples of net.sf.saxon.value.UntypedAtomicValue

                    }
                    if (nextChild instanceof EntityRef) {
                        throw new IllegalStateException("Unexpanded entity in JDOM tree");
                    } else {
                        if (isAtomizing()) {
                            current = new UntypedAtomicValue(getStringValue(node));
                        } else {
                            current = makeWrapper(nextChild, docWrapper, commonParent, ix++);
                        }
                    }
                } else {
                    current = null;
                }
            } else {    // backwards
                if (children.hasPrevious()) {
                    Object nextChild = children.previous();
                    if (nextChild instanceof DocType) {
                        advance();
                        return;
                    }
                    if (nextChild instanceof EntityRef) {
                        throw new IllegalStateException("Unexpanded entity in JDOM tree");
                    } else {
                        if (isAtomizing()) {
                            current = new UntypedAtomicValue(getStringValue(node));
                        } else {
                            current = makeWrapper(nextChild, docWrapper, commonParent, ix--);
                        }
                    }
                } else {
View Full Code Here

Examples of net.sf.saxon.value.UntypedAtomicValue

                        sb.append(charBuffer, start, length);
                    }
                    next++;
                }
                if (sb==null) return UntypedAtomicValue.ZERO_LENGTH_UNTYPED;
                return new UntypedAtomicValue(sb);
            case Type.TEXT:
                int start = alpha[nodeNr];
                int len = beta[nodeNr];
                return new UntypedAtomicValue(
                        new String(charBuffer, start, len));
            case Type.COMMENT:
            case Type.PROCESSING_INSTRUCTION:
                int start2 = alpha[nodeNr];
                int len2 = beta[nodeNr];
                if (len2==0) return UntypedAtomicValue.ZERO_LENGTH_UNTYPED;
                char[] dest = new char[len2];
                commentBuffer.getChars(start2, start2+len2, dest, 0);
                return new UntypedAtomicValue(new String(dest, 0, len2));
            default:
                throw new IllegalStateException("Unknown node kind");
        }
    }
View Full Code Here

Examples of net.sf.saxon.value.UntypedAtomicValue

                } else if (argname.startsWith("+")) {
                    // parameters starting with "+" are taken as input documents
                    List sources = Transform.loadDocuments(arg.substring(eq+1), useURLs, config, true);
                    dynamicEnv.setParameter(argname.substring(1), sources);
                } else {
                    dynamicEnv.setParameter(argname, new UntypedAtomicValue(arg.substring(eq+1)));
                }
            }

            config.displayLicenseMessage();
View Full Code Here

Examples of net.sf.saxon.value.UntypedAtomicValue

            } else if (argname.startsWith("+")) {
                // parameters starting with "+" are taken as input documents
                List sources = loadDocuments(arg.substring(eq+1), useURLs, config, true);
                t.setParameter(argname.substring(1), sources);
      } else {
          t.setParameter(argname, new UntypedAtomicValue(arg.substring(eq+1)));
      }
        }
    }
View Full Code Here

Examples of net.sf.saxon.value.UntypedAtomicValue

    /**
    * Get the typed value of the item
    */

    public SequenceIterator getTypedValue(Configuration config) {
        return SingletonIterator.makeIterator(new UntypedAtomicValue(getStringValue()));
    }
View Full Code Here

Examples of net.sf.saxon.value.UntypedAtomicValue

                    switch (node.getNodeType()) {
                        case Node.DOCUMENT_TYPE_NODE:
                            break;
                        default:
                            if (isAtomizing()) {
                                items.add(new UntypedAtomicValue(
                                        getStringValue(node, node.getNodeType())));
                            } else {
                                items.add(makeWrapper(node, docWrapper, commonParent, i));
                            }
                    }
                }
            } else {
                for (int i=ix; i>=0; i--) {
                    Node node = childNodes.item(i);
                    switch (node.getNodeType()) {
                        case Node.DOCUMENT_TYPE_NODE:
                            break;
                        default:
                            if (isAtomizing()) {
                                items.add(new UntypedAtomicValue(
                                        getStringValue(node, node.getNodeType())));
                            } else {
                                items.add(makeWrapper(node, docWrapper, commonParent, i));
                            }
                    }
View Full Code Here

Examples of net.sf.saxon.value.UntypedAtomicValue

    /**
    * Get the typed value of the item
    */

    public SequenceIterator getTypedValue(Configuration config) {
        return SingletonIterator.makeIterator(new UntypedAtomicValue(uri));
    }
View Full Code Here

Examples of org.exist.xquery.value.UntypedAtomicValue

    /* (non-Javadoc)
     * @see org.exist.xquery.value.Item#atomize()
     */
    public AtomicValue atomize() throws XPathException {
        return( new UntypedAtomicValue( getStringValue() ) );
    }
View Full Code Here

Examples of org.pdf4j.saxon.value.UntypedAtomicValue

    public Expression convertToStringJoin(StaticContext env) {
        if (select.getItemType(env.getConfiguration().getTypeHierarchy()).equals(BuiltInAtomicType.UNTYPED_ATOMIC)) {
            return select;
        } else if (select instanceof StringLiteral) {
            try {
                return new Literal(new UntypedAtomicValue(((StringLiteral)select).getValue().getStringValueCS()));
            } catch (XPathException err) {
                throw new AssertionError(err);
            }
        } else {
            StringFn fn = (StringFn) SystemFunction.makeSystemFunction("string", new Expression[]{select});
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.