gi-vte-2.91.35: Vte bindings
CopyrightWill Thompson and Iñaki García Etxebarria
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria
Safe HaskellNone
LanguageHaskell2010

GI.Vte.Structs.Regex

Description

No description available in the introspection data.

Synopsis

Exported types

newtype Regex Source #

Memory-managed wrapper type.

Constructors

Regex (ManagedPtr Regex) 

Instances

Instances details
Eq Regex Source # 
Instance details

Defined in GI.Vte.Structs.Regex

Methods

(==) :: Regex -> Regex -> Bool #

(/=) :: Regex -> Regex -> Bool #

GBoxed Regex Source # 
Instance details

Defined in GI.Vte.Structs.Regex

ManagedPtrNewtype Regex Source # 
Instance details

Defined in GI.Vte.Structs.Regex

TypedObject Regex Source # 
Instance details

Defined in GI.Vte.Structs.Regex

Methods

glibType :: IO GType #

HasParentTypes Regex Source # 
Instance details

Defined in GI.Vte.Structs.Regex

IsGValue (Maybe Regex) Source #

Convert Regex to and from GValue. See toGValue and fromGValue.

Instance details

Defined in GI.Vte.Structs.Regex

type ParentTypes Regex Source # 
Instance details

Defined in GI.Vte.Structs.Regex

type ParentTypes Regex = '[] :: [Type]

Methods

Click to display all available methods, including inherited ones

Expand

Methods

jit, ref, substitute, unref.

Getters

None.

Setters

None.

jit

regexJit Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Regex

regex: a Regex

-> Word32

flags: PCRE2 JIT flags, or 0

-> m ()

(Can throw GError)

If the platform supports JITing, JIT compiles regex.

newForMatch

regexNewForMatch Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Text

pattern: a regex pattern string

-> Int64

patternLength: the length of pattern in bytes, or -1 if the string is NUL-terminated and the length is unknown

-> Word32

flags: PCRE2 compile flags

-> m Regex

Returns: a newly created Regex, or Nothing with error filled in (Can throw GError)

Compiles pattern into a regex for use as a match regex with terminalMatchAddRegex or vte_terminal_event_check_regex_simple().

See man:pcre2pattern(3) for information about the supported regex language, and man:pcre2api(3) for information about the supported flags.

The regex will be compiled using <literal>PCRE2_UTF</literal> and possibly other flags, in addition to the flags supplied in flags.

newForMatchFull

regexNewForMatchFull Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Text

pattern: a regex pattern string

-> Int64

patternLength: the length of pattern in bytes, or -1 if the string is NUL-terminated and the length is unknown

-> Word32

flags: PCRE2 compile flags

-> Word32

extraFlags: PCRE2 extra compile flags

-> m (Regex, CSize)

Returns: a newly created Regex, or Nothing (Can throw GError)

Compiles pattern into a regex for use as a match regex with terminalMatchAddRegex or vte_terminal_event_check_regex_simple().

See man:pcre2pattern(3) for information about the supported regex language, and man:pcre2api(3) for information about the supported flags and extraFlags.

The regex will be compiled using <literal>PCRE2_UTF</literal> and possibly other flags, in addition to the flags supplied in flags.

If regex compilation fails, error will be set and errorOffset point to error as an offset into pattern.

Since: 0.76

newForSearch

regexNewForSearch Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Text

pattern: a regex pattern string

-> Int64

patternLength: the length of pattern in bytes, or -1 if the string is NUL-terminated and the length is unknown

-> Word32

flags: PCRE2 compile flags

-> m Regex

Returns: a newly created Regex, or Nothing with error filled in (Can throw GError)

Compiles pattern into a regex for use as a search regex with terminalSearchSetRegex.

See man:pcre2pattern(3) for information about the supported regex language, and man:pcre2api(3) for information about the supported flags.

The regex will be compiled using <literal>PCRE2_UTF</literal> and possibly other flags, in addition to the flags supplied in flags.

newForSearchFull

regexNewForSearchFull Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Text

pattern: a regex pattern string

-> Int64

patternLength: the length of pattern in bytes, or -1 if the string is NUL-terminated and the length is unknown

-> Word32

flags: PCRE2 compile flags

-> Word32 
-> m (Regex, CSize)

Returns: a newly created Regex, or Nothing (Can throw GError)

Compiles pattern into a regex for use as a search regex with terminalSearchSetRegex.

See man:pcre2pattern(3) for information about the supported regex language, and man:pcre2api(3) for information about the supported flags and extraFlags.

The regex will be compiled using <literal>PCRE2_UTF</literal> and possibly other flags, in addition to the flags supplied in flags.

If regex compilation fails, error will be set and errorOffset point to error as an offset into pattern.

Since: 0.76

ref

regexRef Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Regex

regex: a Regex

-> m Regex

Returns: regex

Increases the reference count of regex by one.

substitute

regexSubstitute Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Regex

regex: a Regex

-> Text

subject: the subject string

-> Text

replacement: the replacement string

-> Word32

flags: PCRE2 match flags

-> m Text

Returns: the substituted string, or Nothing if an error occurred (Can throw GError)

See man:pcre2api(3) and man:pcre2_substitute(3) for more information.

Since: 0.56

unref

regexUnref Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Regex

regex: a Regex

-> m Regex

Returns: Nothing

Decreases the reference count of regex by one, and frees regex if the refcount reaches zero.