rem:  switch (type) 
add: try { switch (type) { case nsIPrefBranch.PREF_STRING: return this.prefBranch.getCharPref (prefName);  case nsIPrefBranch.PREF_INT: return this.prefBranch.getIntPref (prefName);  case nsIPrefBranch.PREF_BOOL: return this.prefBranch.getBoolPref (prefName);  default: return defaultValue; }  return null; } catch (ex) 
context: function con_addpref (prefName, defaultValue){    function prefGetter ()    {        var type = this.prefBranch.getPrefType (prefName);        switch (type)        {            case nsIPrefBranch.PREF_STRING:                return this.prefBranch.getCharPref (prefName);                            case nsIPrefBranch.PREF_INT:                return this.prefBranch.getIntPref (prefName);                            case nsIPrefBranch.PREF_BOOL:                return this.prefBranch.getCharPref (prefName);                            default:                return defaultValue;        }                return null;    }        function prefSetter (value)    {        switch (typeof value)        {            case "int":                this.prefBranch.setIntPref (prefName, value);                break;            case "boolean":                this.prefBranch.setBoolPref (prefName, value);                break;            default:                this.prefBranch.setCharPref (prefName, value);                break;               }        this.prefService.savePrefFile(null);        return value;    }    if (prefName in console.prefs)        return;    console.prefs.prefNames.push(prefName);        console.prefs.prefNames.sort();    console.prefs.__defineGetter__(prefName, prefGetter);    console.prefs.__defineSetter__(prefName, prefSetter);}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/69e7d256c057e99685d6a99b1bbee39c44a8a961/venkman-prefs.js/clean/extensions/venkman/resources/content/venkman-prefs.js