| java.lang.Object net.sf.saxon.value.Value net.sf.saxon.value.AtomicValue net.sf.saxon.value.StringValue net.sf.saxon.value.AnyURIValue
AnyURIValue | final public class AnyURIValue extends StringValue (Code) | | An XPath value of type xs:anyURI.
This is implemented as a subtype of StringValue even though xs:anyURI is not a subtype of
xs:string in the XPath type hierarchy. This enables type promotion from URI to String to happen
automatically in most cases where it is appropriate.
This implementation of xs:anyURI allows any string to be contained in the value space. It is possible
to validate that the string is a "valid URI" in the sense of XML Schema Part 2 (which refers to the XLink
specification and to RFC 2396); however, this validation is optional, and is not carried out by default.
In particular, there is no constraint that namespace URIs, collation URIs, and the like should be valid
URIs. However, casting from strings to xs:anyURI does invoke validation.
|
AnyURIValue | public AnyURIValue(CharSequence value)(Code) | | Constructor
Parameters: value - the String value. Null is taken as equivalent to "". |
convertPrimitive | public AtomicValue convertPrimitive(BuiltInAtomicType requiredType, boolean validate, XPathContext context)(Code) | | Convert to target data type
Parameters: requiredType - integer code representing the item type required Parameters: context - the result of the conversion, or an ErrorValue |
convertToJava | public Object convertToJava(Class target, XPathContext context) throws XPathException(Code) | | Convert to Java object (for passing to external functions)
Parameters: target - the Java class to which conversion is required the result of the conversion throws: XPathException - if conversion to this target type is not possible |
effectiveBooleanValue | public boolean effectiveBooleanValue(XPathContext context) throws XPathException(Code) | | Get the effective boolean value of the value
Parameters: context - the evaluation context (not used in this implementation) true, unless the value is boolean false, numeric zero, orzero-length string |
equals | public boolean equals(Object other)(Code) | | Determine if two AnyURIValues are equal, according to XML Schema rules. (This method
is not used for XPath comparisons, which are always under the control of a collation.)
throws: ClassCastException - if the values are not comparable |
getItemType | public ItemType getItemType(TypeHierarchy th)(Code) | | Return the type of the expression
Type.ANY_URI_TYPE (always) Parameters: th - |
isValidURI | public static boolean isValidURI(CharSequence value)(Code) | | Check whether a string consititutes a valid URI
|
Fields inherited from net.sf.saxon.value.Value | final public static Class[] EMPTY_CLASS_ARRAY(Code)(Java Doc)
|
Methods inherited from net.sf.saxon.value.Value | public static Item asItem(ValueRepresentation value, XPathContext context) throws XPathException(Code)(Java Doc) public static SequenceIterator asIterator(ValueRepresentation val, XPathContext context) throws XPathException(Code)(Java Doc) public static Value asValue(ValueRepresentation val)(Code)(Java Doc) public void checkPermittedContents(SchemaType parentType, StaticContext env, boolean whole) throws XPathException(Code)(Java Doc) public static CharSequence collapseWhitespace(CharSequence in)(Code)(Java Doc) public static Object convert(Item item) throws XPathException(Code)(Java Doc) public static Value convertJavaObjectToXPath(Object object, SequenceType requiredType, Configuration config) throws XPathException(Code)(Java Doc) public Object convertToJava(Class target, XPathContext context) throws XPathException(Code)(Java Doc) public void display(int level, NamePool pool, PrintStream out)(Code)(Java Doc) public boolean effectiveBooleanValue(XPathContext context) throws XPathException(Code)(Java Doc) public boolean equals(Object obj)(Code)(Java Doc) public String evaluateAsString(XPathContext context) throws XPathException(Code)(Java Doc) public Item evaluateItem(XPathContext context) throws XPathException(Code)(Java Doc) public int getCardinality()(Code)(Java Doc) final public int getDependencies()(Code)(Java Doc) public ItemType getItemType(TypeHierarchy th)(Code)(Java Doc) public static SequenceIterator getIterator(ValueRepresentation val) throws XPathException(Code)(Java Doc) public int getLength() throws XPathException(Code)(Java Doc) final public Container getParentExpression()(Code)(Java Doc) public int getSpecialProperties()(Code)(Java Doc) public String getStringValue() throws XPathException(Code)(Java Doc) public int hashCode()(Code)(Java Doc) public Item itemAt(int n) throws XPathException(Code)(Java Doc) final public Iterator iterateSubExpressions()(Code)(Java Doc) public static QNameValue makeQNameValue(Object object, Configuration config)(Code)(Java Doc) public static CharSequence normalizeWhitespace(CharSequence in)(Code)(Java Doc) final public Expression optimize(Optimizer opt, StaticContext env, ItemType contextItemType)(Code)(Java Doc) public void process(XPathContext context) throws XPathException(Code)(Java Doc) final public Expression promote(PromotionOffer offer)(Code)(Java Doc) public Value reduce() throws XPathException(Code)(Java Doc) public boolean schemaEquals(Value obj)(Code)(Java Doc) final public Expression simplify(StaticContext env)(Code)(Java Doc) public static double stringToNumber(CharSequence s) throws NumberFormatException(Code)(Java Doc) public String toString()(Code)(Java Doc) public static CharSequence trimWhitespace(CharSequence in)(Code)(Java Doc) final public Expression typeCheck(StaticContext env, ItemType contextItemType)(Code)(Java Doc)
|
|
|