Class XSLIf

All Implemented Interfaces:
Conditional

public class XSLIf extends XSLObject implements Conditional
Represents an XSLIf Object (xsl:if)
Version:
$Revision: 3633 $ $Date: 2003-03-01 08:38:44 +0100 (Sat, 01 Mar 2003) $
Author:
Keith Visco
  • Constructor Details

    • XSLIf

      public XSLIf()
      Creates a new XSLIf object
  • Method Details

    • getExpression

      public XPathExpression getExpression() throws XPathException
      Returns the XPath Expression of this xsl:if
      Returns:
      the XPath Expression of this xsl:if
      Throws:
      XPathException
    • evaluate

      public BooleanResult evaluate(XPathContext context) throws XPathException
      Evaluates this Conditional using the given XPathContext.
      Specified by:
      evaluate in interface Conditional
      Parameters:
      context - the XPathContext to evaluate this conditional with.
      Returns:
      the resulting BooleanResult
      Throws:
      XPathException
    • setAttribute

      public void setAttribute(String name, String value) throws XSLException
      Sets the attribute with the given name to the given value.
      Overrides:
      setAttribute in class XSLObject
      Parameters:
      name - the name of the attribute to set
      value - the value to set the attribute to
      Throws:
      XSLException - if this XSLObject does not allow attributes with the given name, or if the attribute is read only
    • setExpression

      public void setExpression(XPathExpression expr)
      Sets the test expression for this xsl:if
      Parameters:
      expr - the XPathExpression for this xsl:if