]> source.dussan.org Git - poi.git/commitdiff
made parenthesis work in and out
authorAndrew C. Oliver <acoliver@apache.org>
Sun, 28 Apr 2002 16:40:37 +0000 (16:40 +0000)
committerAndrew C. Oliver <acoliver@apache.org>
Sun, 28 Apr 2002 16:40:37 +0000 (16:40 +0000)
git-svn-id: https://svn.apache.org/repos/asf/jakarta/poi/trunk@352529 13f79535-47bb-0310-9956-ffa450edef68

src/java/org/apache/poi/hssf/record/formula/ParenthesisPtg.java
src/java/org/apache/poi/hssf/record/formula/Ptg.java

index e6cdc751241864b762cc0c0ea1445122e2ea9c31..cc32670b8f96cd35aaf128a7c20282d1c181b577 100644 (file)
@@ -72,7 +72,21 @@ public class ParenthesisPtg
     private final static int SIZE = 1;
     public final static byte sid  = 0x15;
    
+    public ParenthesisPtg()
+    {
+    }
+
+    public ParenthesisPtg(byte [] data, int offset)
+    {
+
+        // doesn't need anything
+    }
+    
+    protected ParenthesisPtg(String formula, int offset) {
+        
+    }
 
+    
     public void writeBytes(byte [] array, int offset)
     {
         array[ offset + 0 ] = sid;
@@ -102,17 +116,10 @@ public class ParenthesisPtg
     {
         return "";
     }
-    
-    public void manipulate(List source, List results, int pos) {
-    }
-    
+        
     public String toFormulaString(String[] operands) {
         return "("+operands[0]+")";
     }    
-    
-    public int getPrecedence() {
-        return 2;
-    }    
-    
+        
 }
 
index b0e86a1c70d9c644923c00b04734adbc8519d78c..925dd31eb9822a925ff52bfb1f796847108199b8 100644 (file)
@@ -210,9 +210,9 @@ public abstract class Ptg
                 retval = new ValueReferencePtg(data, offset);
                 break;
 
-    //        case ParenthesisPtg.sid :
-      //          retval = new ParenthesisPtg(data, offset);
-        //        break;
+            case ParenthesisPtg.sid :
+                retval = new ParenthesisPtg(data, offset);
+                break;
 
             case ValueVariableFunctionPtg.sid :
                 retval = new ValueVariableFunctionPtg(data, offset);