openlayers/ol3 — pull request #1358 by twpayne (2013-12-11 17:00:19+00:00)
Title: [vector-api] Add ol.geom.GeometryCollection

This PR adds support for GeometryCollections to the `vector-api` branch.

Some notes, following discussions with @elemoine and @tonio:
- Since GeometryCollections behave very differently to "normal" geometries, this adds an intermediate class called `ol.geom.SimpleGeometry` for "normal" geometries.
- The behaviour is of `ol.geom.GeometryCollection` is designed to follow the behaviour of "normal" geometries. For example:

```javascript
var point = new ol.geom.Point([0, 0]);
var coordinates = point.getCoordinates();
coordinates[0] = 1; // point does not fire "change" event
point.setCoordinates(coordinates); // point does fire "change" event

var geometryCollection = new ol.geom.GeometryCollection([new ol.geom.Point(0, 0)]);
var geometries = geometryCollection.getGeometries();
geometries[0] = new ol.geom.Point([1, 0]); // geometryCollection does not fire "change" event
geometryCollection.setGeometries(geometries); // geometryCollection does fire "change" event
```