gi-glib-2.0.24: GLib bindings

Copyright | Will Thompson Iñaki García Etxebarria and Jonas Platte
License | LGPL-2.1
Maintainer | Iñaki García Etxebarria
Safe Haskell | None
Language | Haskell2010

GI.GLib.Structs.PatternSpec

Contents

- Exported types
- Methods
  - Overloaded methods
  - equal
  - free

Description

A GPatternSpec struct is the 'compiled' form of a pattern. This structure is opaque and its fields cannot be accessed directly.

Synopsis

- newtype PatternSpec = PatternSpec (ManagedPtr PatternSpec)
- patternSpecEqual :: (HasCallStack, MonadIO m) => PatternSpec -> PatternSpec -> m Bool
- patternSpecFree :: (HasCallStack, MonadIO m) => PatternSpec -> m ()

# Exported types

newtype PatternSpec Source #

Memory-managed wrapper type.

Constructors

PatternSpec (ManagedPtr PatternSpec) |

#### Instances

Instances details

Eq PatternSpec Source # |
Instance details Defined in GI.GLib.Structs.PatternSpec Methods (==) :: PatternSpec -> PatternSpec -> Bool # (/=) :: PatternSpec -> PatternSpec -> Bool #
ManagedPtrNewtype PatternSpec Source # |
Instance details Defined in GI.GLib.Structs.PatternSpec Methods toManagedPtr :: PatternSpec -> ManagedPtr PatternSpec Source #
BoxedPtr PatternSpec Source # |
Instance details Defined in GI.GLib.Structs.PatternSpec Methods boxedPtrCopy :: PatternSpec -> IO PatternSpec Source # boxedPtrFree :: PatternSpec -> IO () Source #

# Methods

## Overloaded methods

## equal

patternSpecEqual Source #

Arguments

:: (HasCallStack, MonadIO m) |
=> PatternSpec | `pspec1`: a `PatternSpec`
-> PatternSpec | `pspec2`: another `PatternSpec`
-> m Bool | Returns: Whether the compiled patterns are equal

Compares two compiled pattern specs and returns whether they will match the same set of strings.

## free

patternSpecFree Source #

Arguments

:: (HasCallStack, MonadIO m) |
=> PatternSpec | `pspec`: a `PatternSpec`
-> m () |

Frees the memory allocated for the `PatternSpec`.