Class: Create

Create

new Create(name, fields, allowSets, defaultSetNameopt, associatesWithFoldersopt, definitionJavascriptFileopt, dontRegisteropt)

Parameters:
Name Type Attributes Default Description
name string Name prefix for preferences/fields for this module. As per Mozilla standard, it should be dot-separated and start with 'extensions.' See Firefox url about:config.
fields Array.<SeLiteSettings.Field> Objects, in the order how they will be displayed. Beware: this.fields will not be an array, but an object serving as an associative array { string field name => SeLiteSettings.Field object}
allowSets boolean Whether to allow multiple sets of settings for this module
defaultSetName string | undefined <optional>
Name of the default set. Optional; only allowed (but not required) if allowSets==true
associatesWithFolders boolean <optional>
false Whether the sets are to be used with folder paths (and manifest files in them)
definitionJavascriptFile string <optional>
URL or filepath to the filename (including the extension) of a javascript file which contains a definition of this module. Optional; if present, it lets SeLiteSettings to load a definition automatically by clients that only know the module name but not location of the file. If not set and the module has been already registered, then it stays unchanged (in the preference). Required if you want to register a brand new module; not needed if re-registering (upgrading) an already registered module.
dontRegister boolean <optional>
Whether not to (re)register this module; by default it's false (i.e. do register).
Source:

Members

addedFields :object

{string field name => Field object } for fields added via addField(field).
Type:
  • object
Source:

addedKeys :object

{ string field name => object {key name => default value...}... } for SeLiteSettings.Field.FixedMap instances that have keys added via addKey(key, defaultValue) or addKeys(keys, dontReRegister).
Type:
  • object
Source:

defaultKeys :object

{ string field name => string default value } for SeLiteSettings.Field instances that have default values set (overriden) via setDefaultKey(key).
Type:
  • object
Source:

removedFields :object

{string field name => Field object } for fields removed via removeField(fieldOrName).
Type:
  • object
Source: