Rename ol.reader to ol.format

This commit is contained in:
Tom Payne
2013-11-08 19:57:27 +01:00
parent 8aa6eb5cb7
commit 979d35b3b3
4 changed files with 34 additions and 34 deletions

17
src/ol/format/format.js Normal file
View File

@@ -0,0 +1,17 @@
goog.provide('ol.format');
/**
* @param {function(Object, function(this: S, ol.Feature): T, S=)} reader
* Reader.
* @param {Object} object Object.
* @return {Array.<ol.Feature>}
* @template S,T
*/
ol.format.readAllFromObject = function(reader, object) {
var features = [];
reader(object, function(feature) {
features.push(feature);
});
return features;
};