1 19 20 package jxl.biff.formula; 21 22 import jxl.JXLException; 23 24 27 public class FormulaException extends JXLException 28 { 29 private static class FormulaMessage 30 { 31 34 public String message; 35 40 FormulaMessage(String m) {message = m;} 41 } 42 43 45 static FormulaMessage unrecognizedToken = 46 new FormulaMessage("Unrecognized token"); 47 48 50 static FormulaMessage unrecognizedFunction = 51 new FormulaMessage("Unrecognized function"); 52 53 55 public static FormulaMessage biff8Supported = 56 new FormulaMessage("Only biff8 formulas are supported"); 57 58 static FormulaMessage lexicalError = 59 new FormulaMessage("Lexical error: "); 60 61 static FormulaMessage incorrectArguments = 62 new FormulaMessage("Incorrect arguments supplied to function"); 63 64 static FormulaMessage sheetRefNotFound = 65 new FormulaMessage("Could not find sheet"); 66 67 static FormulaMessage cellNameNotFound = 68 new FormulaMessage("Could not find named cell"); 69 70 71 76 public FormulaException(FormulaMessage m) 77 { 78 super(m.message); 79 } 80 81 86 public FormulaException(FormulaMessage m, int val) 87 { 88 super(m.message + " " + val); 89 } 90 91 96 public FormulaException(FormulaMessage m, String val) 97 { 98 super(m.message + " " + val); 99 } 100 } 101 102 103 104 105 106 | Popular Tags |