gi-gio-2.0.38: Gio bindings

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

GI.Gio.Structs.FileAttributeInfoList

Contents

- Exported types
- Methods
  - add
  - dup
  - lookup
  - new
  - ref
  - unref
- Properties
  - infos
  - nInfos

Description

Acts as a lightweight registry for possible valid file attributes. The registry stores Key-Value pair formats as `GFileAttributeInfos`.

Synopsis

- newtype FileAttributeInfoList = FileAttributeInfoList (ManagedPtr FileAttributeInfoList)
- newZeroFileAttributeInfoList :: MonadIO m => m FileAttributeInfoList
- fileAttributeInfoListAdd :: (HasCallStack, MonadIO m) => FileAttributeInfoList -> Text -> FileAttributeType -> [FileAttributeInfoFlags] -> m ()
- fileAttributeInfoListDup :: (HasCallStack, MonadIO m) => FileAttributeInfoList -> m FileAttributeInfoList
- fileAttributeInfoListLookup :: (HasCallStack, MonadIO m) => FileAttributeInfoList -> Text -> m FileAttributeInfo
- fileAttributeInfoListNew :: (HasCallStack, MonadIO m) => m FileAttributeInfoList
- fileAttributeInfoListRef :: (HasCallStack, MonadIO m) => FileAttributeInfoList -> m FileAttributeInfoList
- fileAttributeInfoListUnref :: (HasCallStack, MonadIO m) => FileAttributeInfoList -> m ()
- clearFileAttributeInfoListInfos :: MonadIO m => FileAttributeInfoList -> m ()
- getFileAttributeInfoListInfos :: MonadIO m => FileAttributeInfoList -> m (Maybe FileAttributeInfo)
- setFileAttributeInfoListInfos :: MonadIO m => FileAttributeInfoList -> Ptr FileAttributeInfo -> m ()
- getFileAttributeInfoListNInfos :: MonadIO m => FileAttributeInfoList -> m Int32
- setFileAttributeInfoListNInfos :: MonadIO m => FileAttributeInfoList -> Int32 -> m ()

# Exported types

newtype FileAttributeInfoList Source #

Memory-managed wrapper type.

Constructors

FileAttributeInfoList (ManagedPtr FileAttributeInfoList) |

#### Instances

Instances details

Eq FileAttributeInfoList Source # |
Instance details Defined in GI.Gio.Structs.FileAttributeInfoList Methods (==) :: FileAttributeInfoList -> FileAttributeInfoList -> Bool Source # (/=) :: FileAttributeInfoList -> FileAttributeInfoList -> Bool Source #
GBoxed FileAttributeInfoList Source # |
Instance details Defined in GI.Gio.Structs.FileAttributeInfoList
ManagedPtrNewtype FileAttributeInfoList Source # |
Instance details Defined in GI.Gio.Structs.FileAttributeInfoList Methods toManagedPtr :: FileAttributeInfoList -> ManagedPtr FileAttributeInfoList Source #
TypedObject FileAttributeInfoList Source # |
Instance details Defined in GI.Gio.Structs.FileAttributeInfoList Methods glibType :: IO GType Source #
HasParentTypes FileAttributeInfoList Source # |
Instance details Defined in GI.Gio.Structs.FileAttributeInfoList
tag ~ 'AttrSet => Constructible FileAttributeInfoList tag Source # |
Instance details Defined in GI.Gio.Structs.FileAttributeInfoList Methods new :: MonadIO m => (ManagedPtr FileAttributeInfoList -> FileAttributeInfoList) -> [AttrOp FileAttributeInfoList tag] -> m FileAttributeInfoList Source #
IsGValue (Maybe FileAttributeInfoList) Source # | Convert `FileAttributeInfoList` to and from `GValue`. See `toGValue` and `fromGValue`.
Instance details Defined in GI.Gio.Structs.FileAttributeInfoList Methods gvalueGType_ :: IO GType Source # gvalueSet_ :: Ptr GValue -> Maybe FileAttributeInfoList -> IO () Source # gvalueGet_ :: Ptr GValue -> IO (Maybe FileAttributeInfoList) Source #
type ParentTypes FileAttributeInfoList Source # |
Instance details Defined in GI.Gio.Structs.FileAttributeInfoList type ParentTypes FileAttributeInfoList = '[] :: [Type]

newZeroFileAttributeInfoList :: MonadIO m => m FileAttributeInfoList Source #

Construct a `FileAttributeInfoList` struct initialized to zero.

# Methods

### Click to display all available methods, including inherited ones

Expand

#### Methods

add, dup, lookup, ref, unref.

#### Getters

None.

#### Setters

None.

## add

fileAttributeInfoListAdd Source #

Arguments

:: (HasCallStack, MonadIO m) |
=> FileAttributeInfoList | `list`: a `FileAttributeInfoList`.
-> Text | `name`: the name of the attribute to add.
-> FileAttributeType | `type`: the `FileAttributeType` for the attribute.
-> [FileAttributeInfoFlags] | `flags`: `FileAttributeInfoFlags` for the attribute.
-> m () |

Adds a new attribute with `name` to the `list`, setting its `type` and `flags`.

## dup

fileAttributeInfoListDup Source #

Arguments

:: (HasCallStack, MonadIO m) |
=> FileAttributeInfoList | `list`: a `FileAttributeInfoList` to duplicate.
-> m FileAttributeInfoList | Returns: a copy of the given `list`.

Makes a duplicate of a file attribute info list.

## lookup

fileAttributeInfoListLookup Source #

Arguments

:: (HasCallStack, MonadIO m) |
=> FileAttributeInfoList | `list`: a `FileAttributeInfoList`.
-> Text | `name`: the name of the attribute to look up.
-> m FileAttributeInfo | Returns: a `FileAttributeInfo` for the `name`, or `Nothing` if an attribute isn't found.

Gets the file attribute with the name `name` from `list`.

## new

fileAttributeInfoListNew Source #

Arguments

:: (HasCallStack, MonadIO m) |
=> m FileAttributeInfoList | Returns: a `FileAttributeInfoList`.

Creates a new file attribute info list.

## ref

fileAttributeInfoListRef Source #

Arguments

:: (HasCallStack, MonadIO m) |
=> FileAttributeInfoList | `list`: a `FileAttributeInfoList` to reference.
-> m FileAttributeInfoList | Returns: `FileAttributeInfoList` or `Nothing` on error.

References a file attribute info list.

## unref

fileAttributeInfoListUnref Source #

Arguments

:: (HasCallStack, MonadIO m) |
=> FileAttributeInfoList | `list`: The `FileAttributeInfoList` to unreference.
-> m () |

Removes a reference from the given `list`. If the reference count falls to zero, the `list` is deleted.

# Properties

## infos

an array of `GFileAttributeInfos`.

clearFileAttributeInfoListInfos :: MonadIO m => FileAttributeInfoList -> m () Source #

Set the value of the “`infos`” field to `Nothing`. When overloading is enabled, this is equivalent to

    clear #infos

getFileAttributeInfoListInfos :: MonadIO m => FileAttributeInfoList -> m (Maybe FileAttributeInfo) Source #

Get the value of the “`infos`” field. When overloading is enabled, this is equivalent to

    get fileAttributeInfoList #infos

setFileAttributeInfoListInfos :: MonadIO m => FileAttributeInfoList -> Ptr FileAttributeInfo -> m () Source #

Set the value of the “`infos`” field. When overloading is enabled, this is equivalent to

    set fileAttributeInfoList [ #infos := value ]

## nInfos

the number of values in the array.

getFileAttributeInfoListNInfos :: MonadIO m => FileAttributeInfoList -> m Int32 Source #

Get the value of the “`n_infos`” field. When overloading is enabled, this is equivalent to

    get fileAttributeInfoList #nInfos

setFileAttributeInfoListNInfos :: MonadIO m => FileAttributeInfoList -> Int32 -> m () Source #

Set the value of the “`n_infos`” field. When overloading is enabled, this is equivalent to

    set fileAttributeInfoList [ #nInfos := value ]