HORIZON HASKELLDocslts/ghc-9.10.xc74966e2026-09-27Search names, modules, packages, or :: a typeCtrl K

GHC 9.10.3 · lts/ghc-9.10.x · c74966e · 2026-09-27

Modulewebdriver-0.12.0.1Haskell2010

Test.WebDriver.Common.Profile

A type for profile preferences. These preference values are used by both Firefox and Opera profiles.

  • 4 types
  • 1 class
  • 16 values

Profiles and profile preferences

4 declarations
datadata Profile b
#

This structure allows you to construct and manipulate profiles in pure code, deferring execution of IO operations until the profile is "prepared". This type is shared by both Firefox and Opera profiles; when a distinction must be made, the phantom type parameter is used to differentiate.

Constructors

  • Profile
    • profileFiles :: HashMap FilePath FilePath

      A mapping from relative destination filepaths to source filepaths found on the filesystem. When the profile is prepared, these source filepaths will be moved to their destinations within the profile directory.

      Using the destination path as the key ensures that there is one unique source path going to each destination path.

    • profilePrefs :: HashMap Text ProfilePref

      A map of profile preferences. These are the settings found in the profile's prefs.js, and entries found in about:config

Instances2Eq, Show
  • Eq (Profile b)Defined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • Show (Profile b)Defined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
newtypenewtype PreparedProfile b
#

Represents a profile that has been prepared for network transmission. The profile cannot be modified in this form.

Instances4Eq, Show, FromJSON, ToJSON
datadata ProfilePref
#

A profile preference value. This is the subset of JSON values that excludes arrays, objects, and null.

Instances5Eq, Show, FromJSON, ToJSON, ToPref
classclass ToPref a where
#

A typeclass to convert types to profile preference values

Methods

Instances19ToPref, …
  • ToPref IntegerDefined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref StringDefined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref Int16Defined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref Int32Defined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref Int64Defined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref Int8Defined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref Word16Defined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref Word32Defined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref Word64Defined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref Word8Defined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref BoolDefined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref DoubleDefined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref FloatDefined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref IntDefined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref WordDefined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref TextDefined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • ToPref ProfilePrefDefined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • Integral a => ToPref (Ratio a)Defined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile
  • HasResolution r => ToPref (Fixed r)Defined in webdriver-0.12.0.1 · Test.WebDriver.Common.Profile

Preferences

3 declarations
valuedeletePref :: Text -> Profile b -> Profile b
#

Delete an existing preference entry from a profile. This operation is silent if the preference wasn't found.

Extensions

3 declarations
valueaddExtension :: FilePath -> Profile b -> Profile b
#

Add a new extension to the profile. The file path should refer to a .xpi file or an extension directory on the filesystem.

valuedeleteExtension :: String -> Profile b -> Profile b
#

Delete an existing extension from the profile. The string parameter should refer to an .xpi file or directory located within the extensions directory of the profile. This operation has no effect if the extension was never added to the profile.

valuehasExtension :: String -> Profile b -> Bool
#

Determines if a profile contains the given extension. specified as an .xpi file or directory name

Other files and directories

3 declarations
valueaddFile :: FilePath -> FilePath -> Profile b -> Profile b
#

Add a file to the profile directory. The first argument is the source of the file on the local filesystem. The second argument is the destination as a path relative to a profile directory. Overwrites any file that previously pointed to the same destination

valuedeleteFile :: FilePath -> Profile b -> Profile b
#

Delete a file from the profile directory. The first argument is the name of file within the profile directory.

valuehasFile :: String -> Profile b -> Bool
#

Determines if a profile contains the given file, specified as a path relative to the profile directory.

Miscellaneous profile operations

3 declarations

Preparing profiles from disk

1 declaration

Preparing zipped profiles

3 declarations

Profile errors

1 declaration
newtypenewtype ProfileParseError
#

An error occured while attempting to parse a profile's preference file.

Instances4Eq, Read, Show, Exception