add name and title to ol.style.Rule
This commit is contained in:
committed by
Bart van den Eijnden
parent
9a6c1feddc
commit
c75082c75d
@@ -54,6 +54,20 @@ ol.style.Rule = function(options) {
|
||||
this.maxResolution_ = goog.isDef(options.maxResolution) ?
|
||||
options.maxResolution : Infinity;
|
||||
|
||||
/**
|
||||
* @type {?string}
|
||||
* @private
|
||||
*/
|
||||
this.name_ = goog.isDef(options.name) ?
|
||||
options.name : null;
|
||||
|
||||
/**
|
||||
* @type {?string}
|
||||
* @private
|
||||
*/
|
||||
this.title_ = goog.isDef(options.title) ?
|
||||
options.title : null;
|
||||
|
||||
};
|
||||
|
||||
|
||||
@@ -102,3 +116,19 @@ ol.style.Rule.prototype.getMinResolution = function() {
|
||||
ol.style.Rule.prototype.getMaxResolution = function() {
|
||||
return this.maxResolution_;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @return {?string}
|
||||
*/
|
||||
ol.style.Rule.prototype.getName = function() {
|
||||
return this.name_;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @return {?string}
|
||||
*/
|
||||
ol.style.Rule.prototype.getTitle = function() {
|
||||
return this.title_;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user