# Extract Preference Set

There are various preference sets and lists which can be accessed when running an action. Replacement Sets in particular, can be convenient means of retaining static information that you might want to use in more than one action.

In all of the available functions list items are separated by the default list delimiter \~. When a key-value list is being produced, the default key-value separator \k is used. The named variable and source fields may contain any of the escape sequences described in Escape Sequences. The following items can be extracted:

Named Exception Set
  The set name can be directly or indirectly specified (via escape sequences). You can choose two scenarios as to how to handle the named exception set not existing at runtime. You can have the action terminate or you can set the action test state where true means it existed and false means it did not. The set is extracted in one of the following ways:
  Extract list to named variable
    The exception set will be be stored to the specified named variable as a list of the exception fields.
  Extract key-value list to named variable
    The exception set will be be stored to the specified named variable as a key-value list. The exception fields become the keys. The values are encoded as a single character as follows:
    N
      No case change.
    L
      lower case
    U
      UPPER CASE
    C
      Capitalize
    F
      Force Exception
    n, l, u, c, f
      Same as above with No Change on Exact Match specified
Named Replacement Set
  The set name can be directly or indirectly specified (via escape sequences). You can choose two scenarios as to how to handle the named replacement set not existing at runtime. You can have the action terminate or you can set the action test state where true means it existed and false means it did not. The set is extracted in one of the following ways:
  Extract named variables
    Every item in the replacement set will become a named variable where the from field is the name and the to field is the value.
  Extract list to named variable
    The replacement set will be be stored to the specified named variable as a list of the from fields.
  Extract key-value list to named variable
    The replacement set will be be stored to the specified named variable as a key-value list. The from fields become the keys and the to fields are the values.
Named Runtime Settings Set
  The set name can be directly or indirectly specified (via escape sequences). You can choose two scenarios as to how to handle the named runtim settings set not existing at runtime. You can have the action terminate or you can set the action test state where true means it existed and false means it did not. The set is extracted in one of the following ways:
  Extract named variables
    Every item in the action runtime settings set will become a named variable where the from field is the name and the to field is the value.
  Extract list to named variable
    The action runtime settings set will be be stored to the specified named variable as a list of the from fields.
  Extract key-value list to named variable
    The action runtime settings set will be be stored to the specified named variable as a key-value list. The from fields become the keys and the to fields are the values.
Named Tag Set
  The set name can be directly or indirectly specified (via escape sequences). You can choose two scenarios as to how to handle the named tag set not existing at runtime. You can have the action terminate or you can set the action test state where true means it existed and false means it did not. A list of the fields enabled in a tag set is returned. If the tag set is inverted, the non inverted equivalent fields are returned. ie. an inverted set with all fields except Artist selected will return Artist. Note that Track Variables may be returned.
Supplied Fields Set
  The list of retured fields is determined as follows:
  - If the action was started from the Multi Field Editor and had a Supported Fields statement, the fields selected in the Multi Field Editor after removing all fields which are known to be invalid, will be returned.
  - If the action was started from the Multi Field Editor and the started action did not have a Supported Fields statement, the fields selected in the Multi Field Editor will be returned.
  - If the action was started from a function button, the button's associated field will be returned.
  - If none of the previous conditions hold, nothing will be returned.
preference List
  The Artist, Composer, Conductor, Custom #, File Type, Genre, Grouping, Label, Lyricist, Media Type, Mood, Publisher, Remixer and Work Name lists can be stored to the specified named variable as a list of the items.
Indirect Preference List
  Named variable Indirect Preference List must contain the name of a preference list as returned by the Names of Preference Lists function. If a preference list has been renamed the default name of the list will also be accepted. The preference list associated with the extracted name will have its items stored to the specified named named variable.
Names of Preference Lists
  A list of all the preference list names. (Preference lists can be renamed).
Current Preference List Names to Default
  A key-value list where keys are the current preference list names and values are the default names.
Default Preference List Names to Current
  A key-value list where keys are the default preference list names and values are the current names.
Preference Lists to Fields
  A key-value list where keys are the current preference list names and values are the names of fields associated with the list. Field names are separated by the secondary list delimiter (\:)
Preference Fields to Lists
  A key-value list where keys are the field names currently associated with a preference list. The value is the name of the associated preference list
Name of Default Replacement Set
  The name of the default replacement set will be saved to the specified named variable. If the item is not assigned, the named variable will be set to empty.
Name of Case Replacement Set
  The name of the case replacement set will be saved to the specified named variable. If the item is not assigned, the named variable will be set to empty.
Name of Fold Characters Replacement Set
  The name of the fold characters replacement set will be saved to the specified named variable. If the item is not assigned, the named variable will be set to empty.
Name of Rename Replacement Set
  The name of the rename replacement set will be saved to the specified named variable. If the item is not assigned, the named variable will be set to empty.
Name of Default Exception Set
  The name of the default exception set will be saved to the specified named variable. If the item is not assigned, the named variable will be set to empty.
Name of Names Exception Set
  The name of the names exception set will be saved to the specified named variable. If the item is not assigned, the named variable will be set to empty.
Name of Natural Sort Exception Set
  The name of the natural sort exception set will be saved to the specified named variable. If the item is not assigned, the named variable will be set to empty.
Name of Title Case Exception Set
  The name of the title case exception set will be saved to the specified named variable. If the item is not assigned, the named variable will be set to empty.
Name of Weight Exception Set
  The name of the weight exception set will be saved to the specified named variable. If the item is not assigned, the named variable will be set to empty.
List of Action Runtime Settings Sets
  A list containing the names of all action runtime settings sets will be saved to the specified named variable.
List of Mapped Action Runtime Settings
  A list containing the names of all Action Runtime Settings will be saved to the specified named variable. The list always represents the contents of the replacement set currently mapped to the runtime setting functionality. See Action Runtime Settings for more information.
List of Actions
  A list containing the names of all actions will be saved to the specified named variable. Note that the list is flat. The action folder structure is ignored.
List of Discogs Import Sets
  A list containing the names of all Discogs import sets will be saved to the specified named variable. There's not much you can do with an import set but the list can be used to test for existence.
List of Exception Sets
  A list containing the names of all exception sets will be saved to the specified named variable.
List of Export Sets
  A list containing the names of all export sets will be saved to the specified named variable.
List of Export Sets (Album)
  A list containing the names of all export sets suitable to be used in the create of a track database will be saved to the specified named variable.
List of Export Sets (Track)
  A list containing the names of all export sets suitable to be used in the create of a track database will be saved to the specified named variable.
List of File to Tag Templates
  A list containing the names of all File to Tag templates will be saved to the specified named variable.
List of MusicBrainz Import Sets
  A list containing the names of all MusicBrainz import sets will be saved to the specified named variable. There's not much you can do with an import set but the list can be used to test for existence.
List of Rename Templates
  A list containing the names of all Rename templates will be saved to the specified named variable.
List of Replacement Sets
  A list containing the names of all replacement sets will be saved to the specified named variable.
List of Search Templates
  A list containing the names of all Search templates will be saved to the specified named variable.
List of Tag Sets
  A list containing the names of all tag sets will be saved to the specified named variable.
Action Runtime Settings with Prefix
  A named variable will be created for every Action Runtime Setting which starts with the supplied prefix. The named variables will have the same name as the runtime settings. The produced variables always represent the contents of the replacement set currently mapped to the runtime setting functionality. See Action Runtime Settings for more information. This function is deprecated. as the usefulness of this function is dubious. It was introduced at a time when the runtime settings were always grouped together. Being able to partition the settings into separate replacement sets eliminates the need to prefix the settings.