Package com.icl.saxon.expr
Class BooleanValue
- java.lang.Object
-
- com.icl.saxon.expr.Expression
-
- com.icl.saxon.expr.Value
-
- com.icl.saxon.expr.BooleanValue
-
public final class BooleanValue extends Value
A boolean XPath value
-
-
Field Summary
-
Fields inherited from class com.icl.saxon.expr.Expression
staticContext
-
-
Constructor Summary
Constructors Constructor Description BooleanValue(boolean value)Constructor: create a boolean value
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanasBoolean()Convert to boolean (null operation)doubleasNumber()Convert to numberjava.lang.StringasString()Convert to stringintconversionPreference(java.lang.Class required)Get conversion preference for this value to a Java class.java.lang.ObjectconvertToJava(java.lang.Class target)Convert to Java object (for passing to external functions)voiddisplay(int level)Diagnostic print of expression structureintgetDataType()Determine the data type of the exprssion-
Methods inherited from class com.icl.saxon.expr.Value
compare, equals, evaluate, getDependencies, inverse, notEquals, numericCompare, reduce, simplify, stringToNumber
-
Methods inherited from class com.icl.saxon.expr.Expression
containsReferences, enumerate, evaluateAsBoolean, evaluateAsNodeSet, evaluateAsNumber, evaluateAsString, getStaticContext, indent, isContextDocumentNodeSet, make, outputStringValue, setStaticContext, usesCurrent
-
-
-
-
Method Detail
-
asString
public java.lang.String asString()
Convert to string
-
asNumber
public double asNumber()
Convert to number
-
asBoolean
public boolean asBoolean()
Convert to boolean (null operation)
-
getDataType
public int getDataType()
Determine the data type of the exprssion- Specified by:
getDataTypein classExpression- Returns:
- Value.BOOLEAN,
-
conversionPreference
public int conversionPreference(java.lang.Class required)
Get conversion preference for this value to a Java class. A low result indicates higher preference.- Specified by:
conversionPreferencein classValue
-
convertToJava
public java.lang.Object convertToJava(java.lang.Class target) throws XPathExceptionConvert to Java object (for passing to external functions)- Specified by:
convertToJavain classValue- Parameters:
target- The class required by the external function- Returns:
- an object of the target class
- Throws:
XPathException
-
display
public void display(int level)
Diagnostic print of expression structure- Specified by:
displayin classExpression
-
-