Give each ol.Map instance its own logger

This commit is contained in:
Tom Payne
2012-08-21 18:33:02 +02:00
parent f92d975921
commit 6edc051548

View File

@@ -8,6 +8,7 @@ goog.provide('ol.MapEventType');
goog.provide('ol.MapProperty');
goog.require('goog.array');
goog.require('goog.debug.Logger');
goog.require('goog.dispose');
goog.require('goog.dom');
goog.require('goog.dom.ViewportSizeMonitor');
@@ -89,6 +90,14 @@ ol.Map = function(
goog.base(this);
if (goog.DEBUG) {
/**
* @protected
* @type {goog.debug.Logger}
*/
this.logger = goog.debug.Logger.getLogger('ol.map.' + goog.getUid(this));
}
/**
* @type {ol.TransformFunction}
* @private