rem: this.fromLocatorString = function(locatorString) { var locatorType = 'label'; var locatorValue = locatorString;  var result = locatorString.match(/^([a-zA-Z]+)=(.*)/); if (result) { locatorType = result[1]; locatorValue = result[2]; } if ('label' == locatorType) { return new OptionLocatorByLabel(locatorValue); } else if ('index' == locatorType) { return new OptionLocatorByIndex(locatorValue); } else if ('value' == locatorType) { return new OptionLocatorByValue(locatorValue); } throw new Error("Unkown option locator type: " + locatorType); }; 
context: function OptionLocatorFactory() {    this.fromLocatorString = function(locatorString) {        var locatorType = 'label';        var locatorValue = locatorString;        // If there is a locator prefix, use the specified strategy        var result = locatorString.match(/^([a-zA-Z]+)=(.*)/);        if (result) {            locatorType = result[1];            locatorValue = result[2];        }        if ('label' == locatorType) {            return new OptionLocatorByLabel(locatorValue);        } else if ('index' == locatorType) {            return new OptionLocatorByIndex(locatorValue);        } else if ('value' == locatorType) {            return new OptionLocatorByValue(locatorValue);        }        throw new Error("Unkown option locator type: " + locatorType);    };}
meta: 3428	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/3428/3b44b078ad64a491bc2e0d28cd5e2fb1cab0b379/selenium-api.js/buggy/code/javascript/selenium-api.js