1 16 19 package com.sun.org.apache.xpath.internal.operations; 20 21 import com.sun.org.apache.xpath.internal.XPathContext; 22 import com.sun.org.apache.xpath.internal.objects.XNumber; 23 import com.sun.org.apache.xpath.internal.objects.XObject; 24 25 28 public class Minus extends Operation 29 { 30 31 43 public XObject operate(XObject left, XObject right) 44 throws javax.xml.transform.TransformerException 45 { 46 return new XNumber(left.num() - right.num()); 47 } 48 49 58 public double num(XPathContext xctxt) 59 throws javax.xml.transform.TransformerException 60 { 61 62 return (m_left.num(xctxt) - m_right.num(xctxt)); 63 } 64 65 } 66 | Popular Tags |