diff --git a/src/java/org/apache/poi/hssf/record/formula/ParenthesisPtg.java b/src/java/org/apache/poi/hssf/record/formula/ParenthesisPtg.java index e6cdc7512..cc32670b8 100644 --- a/src/java/org/apache/poi/hssf/record/formula/ParenthesisPtg.java +++ b/src/java/org/apache/poi/hssf/record/formula/ParenthesisPtg.java @@ -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; - } - + } diff --git a/src/java/org/apache/poi/hssf/record/formula/Ptg.java b/src/java/org/apache/poi/hssf/record/formula/Ptg.java index b0e86a1c7..925dd31eb 100644 --- a/src/java/org/apache/poi/hssf/record/formula/Ptg.java +++ b/src/java/org/apache/poi/hssf/record/formula/Ptg.java @@ -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);