1 2 17 18 package org.apache.poi.hssf.record.formula; 19 20 import org.apache.poi.hssf.model.Workbook; 21 22 26 27 public class EqualPtg 28 extends OperationPtg 29 { 30 public final static int SIZE = 1; 31 public final static byte sid = 0x0b; 32 33 34 35 public EqualPtg() 36 { 37 } 38 39 public EqualPtg(byte [] data, int offset) 40 { 41 42 } 44 45 public void writeBytes(byte [] array, int offset) 46 { 47 array[ offset + 0 ] = sid; 48 } 49 50 public int getSize() 51 { 52 return SIZE; 53 } 54 55 public int getType() 56 { 57 return TYPE_BINARY; 58 } 59 60 public int getNumberOfOperands() 61 { 62 return 2; 63 } 64 65 public String toFormulaString(Workbook book) 66 { 67 return "="; 68 } 69 70 public String toFormulaString(String [] operands) { 71 StringBuffer buffer = new StringBuffer (); 72 73 74 buffer.append(operands[ 0 ]); 75 buffer.append(toFormulaString((Workbook)null)); 76 buffer.append(operands[ 1 ]); 77 return buffer.toString(); 78 } 79 80 public Object clone() { 81 return new EqualPtg(); 82 } 83 84 85 } 86 | Popular Tags |