openlayers/ol3 — pull request #41 by twpayne (2012-10-03 14:16:52+00:00)
Title: Refactor exports and externs

This pull request allows the same API to be used when the application uses a separately compiled build of ol3 as when then application and ol3 are compiled together.

When the application and ol3 are compiled together:
- all ol3 classes and properties are available
- all object literal types are type checked
- the build is near optimally minimised
- all Closure library functions (`goog.*`) are available

When ol3 is compiled separately:
- only ol3 classes and properties listed in `src/ol/exports.txt` are available
- object literals from the application are not type checked
- the build contains all classes and properties in `src/ol/exports.txt`, even if they are not used by the application, and these exports make the build larger
- no Closure library functions are available

This pull request completes a framework that makes the difference between the two modes fairly transparent to both the developer and the user.