/** * Get the underlying implementation object representing the value. This method allows * access to lower-level Saxon functionality, including classes and methods that offer * no guarantee of stability across releases. * * @return the underlying implementation object representing the value * @since 9.8 (previously inherited from XdmValue which returns a Sequence) */ @Override public NodeInfo getUnderlyingValue() { return (NodeInfo) super.getUnderlyingValue(); }
/** * Get the underlying implementation object representing the value. This method allows * access to lower-level Saxon functionality, including classes and methods that offer * no guarantee of stability across releases. * * @return the underlying implementation object representing the value * @since 9.8 (previously inherited from XdmValue which returns a Sequence) */ @Override public AtomicValue getUnderlyingValue() { return (AtomicValue)super.getUnderlyingValue(); }
/** * Determine whether the item is an atomic value or some other type of item * * @return true if the item is an atomic value, false if it is a node or a function (including maps and arrays) */ public boolean isAtomicValue() { return getUnderlyingValue() instanceof AtomicValue; }
/** * Get the underlying implementation object representing the value. This method allows * access to lower-level Saxon functionality, including classes and methods that offer * no guarantee of stability across releases. * * @return the underlying implementation object representing the value * @since 9.8 (previously inherited from XdmValue which returns a Sequence) */ @Override public NodeInfo getUnderlyingValue() { return (NodeInfo) super.getUnderlyingValue(); }
/** * Determine whether the item is an atomic value or a node * @return true if the item is an atomic value, false if it is a node */ public boolean isAtomicValue() { return ((Item)getUnderlyingValue()) instanceof AtomicValue; }
@Override public boolean matches(XdmItem item) { return item.getUnderlyingValue() instanceof NumericValue; }
/** * Get the underlying implementation object representing the value. This method allows * access to lower-level Saxon functionality, including classes and methods that offer * no guarantee of stability across releases. * * @return the underlying implementation object representing the value * @since 9.8 (previously inherited from XdmValue which returns a Sequence) */ @Override public AtomicValue getUnderlyingValue() { return (AtomicValue)super.getUnderlyingValue(); }
/** * Determine whether the item is an atomic value or some other type of item * * @return true if the item is an atomic value, false if it is a node or a function (including maps and arrays) */ public boolean isAtomicValue() { return getUnderlyingValue() instanceof AtomicValue; }
/** * Set the initial context item for the transformation. * * @param item the initial context item, or null if there is to be no initial context item * @deprecated since 9.8 - use {@link #setGlobalContextItem} */ public void setInitialContextItem(XdmItem item) { if (primed) { throw new IllegalStateException("Stylesheet has already been evaluated"); } this.globalContextItem = item.getUnderlyingValue(); }
/** * Set the initial context item for the transformation. * * @param item the initial context item, or null if there is to be no initial context item * @deprecated since 9.8 - use {@link #setGlobalContextItem} */ public void setInitialContextItem(XdmItem item) { if (primed) { throw new IllegalStateException("Stylesheet has already been evaluated"); } this.globalContextItem = item.getUnderlyingValue(); }
public boolean matches(XdmItem item) { Item<?> it = item.getUnderlyingValue(); return it instanceof NodeInfo && ((NodeInfo) it).getNodeKind() == Type.COMMENT; }
public boolean matches(XdmItem item) { Item<?> it = item.getUnderlyingValue(); return it instanceof NodeInfo && ((NodeInfo) it).getNodeKind() == Type.TEXT; }
public boolean matches(XdmItem item) { Item<?> it = item.getUnderlyingValue(); return it instanceof NodeInfo && ((NodeInfo) it).getNodeKind() == Type.NAMESPACE; }
/** * Set the initial context item for the query * @param item the initial context item, or null if there is to be no initial context item */ public void setContextItem(XdmItem item) { context.setContextItem(item == null ? null : (Item)item.getUnderlyingValue()); }
public boolean matches(XdmItem item) { Item<?> it = item.getUnderlyingValue(); return it instanceof NodeInfo && ((NodeInfo) it).getNodeKind() == Type.ATTRIBUTE; }
public boolean matches(XdmItem item) { Item<?> it = item.getUnderlyingValue(); return it instanceof NodeInfo && ((NodeInfo) it).getNodeKind() == Type.ELEMENT; }
public boolean matches(XdmItem item) { Item<?> it = item.getUnderlyingValue(); return it instanceof NodeInfo && ((NodeInfo) it).getNodeKind() == Type.DOCUMENT; }
public boolean matches(XdmItem item) { Item value = item.getUnderlyingValue(); if (!(value instanceof AtomicValue)) { return false; } AtomicType type = ((AtomicValue) value).getItemType(); return subsumesUnderlyingType(type); }
public boolean matches(XdmItem item) { Item value = item.getUnderlyingValue(); if (!(value instanceof AtomicValue)) { return false; } AtomicType type = ((AtomicValue) value).getItemType(); return subsumesUnderlyingType(type); }
/** * Determine whether this item type matches a given item. * * @param item the item to be tested against this item type * @return true if the item matches this item type, false if it does not match. */ public boolean matches(XdmItem item) { return underlyingType.matchesItem( (Item)item.getUnderlyingValue(), false, processor.getUnderlyingConfiguration()); }