net.sf.saxon.functions

Class TreatFn

public class TreatFn extends SystemFunction

This class supports the XPath 2.0 functions exactly-one(), one-or-more(), zero-or-one(). Because Saxon doesn't do strict static type checking, these are essentially identity functions; the run-time type checking is done as part of the function call mechanism
Method Summary
ItemevaluateItem(XPathContext context)
Evaluate the function
StringgetErrorCodeForTypeErrors()
Return the error code to be used for type errors
SequenceIteratoriterate(XPathContext context)
Iterate over the results of the function

Method Detail

evaluateItem

public Item evaluateItem(XPathContext context)
Evaluate the function

getErrorCodeForTypeErrors

public String getErrorCodeForTypeErrors()
Return the error code to be used for type errors

iterate

public SequenceIterator iterate(XPathContext context)
Iterate over the results of the function