poi/src/ooxml
Josh Micich 96cb7321ba Merged revisions 699178,699487,699489,699761 via svnmerge from
https://svn.apache.org/repos/asf/poi/trunk

........
  r699178 | josh | 2008-09-25 21:49:20 -0700 (Thu, 25 Sep 2008) | 1 line
  
  Changed HSSFEvaluationWorkbook to avoid re-parsing cell formulas during execution. (working towards fix for bug 45865)
........
  r699487 | josh | 2008-09-26 13:25:45 -0700 (Fri, 26 Sep 2008) | 1 line
  
  Fix formula parser to properly support the range operator. Small fixes to parsing of sheet names and full column references.
........
  r699489 | josh | 2008-09-26 13:32:06 -0700 (Fri, 26 Sep 2008) | 1 line
  
  Code cleanup in junit
........
  r699761 | josh | 2008-09-27 19:04:31 -0700 (Sat, 27 Sep 2008) | 1 line
  
  Bug 45865 - modified Formula Parser/Evaluator to handle cross-worksheet formulas
........


git-svn-id: https://svn.apache.org/repos/asf/poi/branches/ooxml@700234 13f79535-47bb-0310-9956-ffa450edef68
2008-09-29 20:09:09 +00:00
..
interfaces-jdk14/org/apache/poi/ss Applied patch 45899 - XSSFWorkbook getActiveSheetIndex / setActiveSheet 2008-09-29 04:50:20 +00:00
interfaces-jdk15/org/apache/poi Applied patch 45899 - XSSFWorkbook getActiveSheetIndex / setActiveSheet 2008-09-29 04:50:20 +00:00
java/org/apache/poi Merged revisions 699178,699487,699489,699761 via svnmerge from 2008-09-29 20:09:09 +00:00
testcases Cleaned up test code 2008-09-29 05:46:06 +00:00
README.interfaces [ooxml-branch] Split the common ss interfaces into two sets - one that works with jdk 1.5 and has the full functionality, and another that works with jdk 1.4 and only has dummy functionality. Update build.xml to spit out two versions of the main classes, one for jdk 1.5 with the full interfaces, and one for jdk 1.4 with the dummy ones (but which is otherwise like the current behaviour). Also add readme explaining all this 2008-01-21 18:00:30 +00:00

            Fun with Interfaces
            -------------------

Let us consider a simple case

  public Interface IFoo {}
  public Interface IBar {
     public IFoo getFoo();
  }

  public class RealFoo implements IFoo {}
  public class RealBar implements IBar {
     public RealFoo getFoo() { return new RealFoo(); }
  }

Looks ok, doesn't it? If you access RealBar directly, you get back a
RealFoo. If you access RealBar via the IBar interface, you get back a
IFoo object instead. All looks good.

Only snag - this doesn't work with any JDK older than 1.5. If you're on
JDK 1.3 or JDK 1.4, you will get a compile time error about incompatible
return signatures.


At the moment, we're still committed to having the core of POI work on
JDK 1.3 / JDK 1.4. If you want the OOXML support, then you need to move
to JDK 1.5. This allows us a sort of work-around for the problems:

JDK 1.3 / JDK 1.4:
 You can't use the OOXML stuff anyway, so you probably don't care about
  the new interfaces
 So, have the existing code (hssf) compile against dummy interfaces, which 
  don't actually provide any methods
 You can't then use the interfaces, but you probably didn't want to anyway
 These live in src/ooxml/interfaces-jdk14

JDK 1.5:
 Compile the existing code (hssf) against full interfaces. Users can still
  use the concrete HSSF classes if they want, or if they use the interfaces,
  their code will work with the ooxml support too
 Need to change any methods that take a concrete object (eg HSSFCell) to
  take the interface (eg Cell), and cast, otherwise they're not compatible
  with the interface contract (which specifies Cell not HSSFCell).
 These live in src/ooxml/interfaces-jdk15