acoliver    02/04/28 09:40:37

  Modified:    src/java/org/apache/poi/hssf/record/formula
                        ParenthesisPtg.java Ptg.java
  Log:
  made parenthesis work in and out
  
  Revision  Changes    Path
  1.5       +16 -9     
jakarta-poi/src/java/org/apache/poi/hssf/record/formula/ParenthesisPtg.java
  
  Index: ParenthesisPtg.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-poi/src/java/org/apache/poi/hssf/record/formula/ParenthesisPtg.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- ParenthesisPtg.java       27 Apr 2002 14:07:53 -0000      1.4
  +++ ParenthesisPtg.java       28 Apr 2002 16:40:37 -0000      1.5
  @@ -72,7 +72,21 @@
       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 @@
       {
           return "";
       }
  -    
  -    public void manipulate(List source, List results, int pos) {
  -    }
  -    
  +        
       public String toFormulaString(String[] operands) {
           return "("+operands[0]+")";
       }    
  -    
  -    public int getPrecedence() {
  -        return 2;
  -    }    
  -    
  +        
   }
   
  
  
  
  1.7       +3 -3      jakarta-poi/src/java/org/apache/poi/hssf/record/formula/Ptg.java
  
  Index: Ptg.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-poi/src/java/org/apache/poi/hssf/record/formula/Ptg.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- Ptg.java  28 Apr 2002 16:33:57 -0000      1.6
  +++ Ptg.java  28 Apr 2002 16:40:37 -0000      1.7
  @@ -210,9 +210,9 @@
                   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);
  
  
  


Reply via email to