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.DBusNodeInfo

Contents

- Exported types
- Methods
  - generateXml
  - lookupInterface
  - newForXml
  - ref
  - unref
- Properties
  - annotations
  - interfaces
  - nodes
  - path
  - refCount

Description

Information about nodes in a remote object hierarchy.

Since: 2.26

Synopsis

- newtype DBusNodeInfo = DBusNodeInfo (ManagedPtr DBusNodeInfo)
- newZeroDBusNodeInfo :: MonadIO m => m DBusNodeInfo
- dBusNodeInfoGenerateXml :: (HasCallStack, MonadIO m) => DBusNodeInfo -> Word32 -> String -> m ()
- dBusNodeInfoLookupInterface :: (HasCallStack, MonadIO m) => DBusNodeInfo -> Text -> m (Maybe DBusInterfaceInfo)
- dBusNodeInfoNewForXml :: (HasCallStack, MonadIO m) => Text -> m DBusNodeInfo
- dBusNodeInfoRef :: (HasCallStack, MonadIO m) => DBusNodeInfo -> m DBusNodeInfo
- dBusNodeInfoUnref :: (HasCallStack, MonadIO m) => DBusNodeInfo -> m ()
- clearDBusNodeInfoAnnotations :: MonadIO m => DBusNodeInfo -> m ()
- getDBusNodeInfoAnnotations :: MonadIO m => DBusNodeInfo -> m (Maybe [DBusAnnotationInfo])
- setDBusNodeInfoAnnotations :: MonadIO m => DBusNodeInfo -> Ptr (Ptr DBusAnnotationInfo) -> m ()
- clearDBusNodeInfoInterfaces :: MonadIO m => DBusNodeInfo -> m ()
- getDBusNodeInfoInterfaces :: MonadIO m => DBusNodeInfo -> m (Maybe [DBusInterfaceInfo])
- setDBusNodeInfoInterfaces :: MonadIO m => DBusNodeInfo -> Ptr (Ptr DBusInterfaceInfo) -> m ()
- clearDBusNodeInfoNodes :: MonadIO m => DBusNodeInfo -> m ()
- getDBusNodeInfoNodes :: MonadIO m => DBusNodeInfo -> m (Maybe [DBusNodeInfo])
- setDBusNodeInfoNodes :: MonadIO m => DBusNodeInfo -> Ptr (Ptr DBusNodeInfo) -> m ()
- clearDBusNodeInfoPath :: MonadIO m => DBusNodeInfo -> m ()
- getDBusNodeInfoPath :: MonadIO m => DBusNodeInfo -> m (Maybe Text)
- setDBusNodeInfoPath :: MonadIO m => DBusNodeInfo -> CString -> m ()
- getDBusNodeInfoRefCount :: MonadIO m => DBusNodeInfo -> m Int32
- setDBusNodeInfoRefCount :: MonadIO m => DBusNodeInfo -> Int32 -> m ()

# Exported types

newtype DBusNodeInfo Source #

Memory-managed wrapper type.

Constructors

DBusNodeInfo (ManagedPtr DBusNodeInfo) |

#### Instances

Instances details

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

newZeroDBusNodeInfo :: MonadIO m => m DBusNodeInfo Source #

Construct a `DBusNodeInfo` struct initialized to zero.

# Methods

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

Expand

#### Methods

generateXml, lookupInterface, ref, unref.

#### Getters

None.

#### Setters

None.

## generateXml

dBusNodeInfoGenerateXml Source #

Arguments

:: (HasCallStack, MonadIO m) |
=> DBusNodeInfo | `info`: A `DBusNodeInfo`.
-> Word32 | `indent`: Indentation level.
-> String | `stringBuilder`: A `String` to to append XML data to.
-> m () |

Appends an XML representation of `info` (and its children) to `stringBuilder`.

This function is typically used for generating introspection XML documents at run-time for handling the `org.freedesktop.DBus.Introspectable.Introspect` method.

Since: 2.26

## lookupInterface

dBusNodeInfoLookupInterface Source #

Arguments

:: (HasCallStack, MonadIO m) |
=> DBusNodeInfo | `info`: A `DBusNodeInfo`.
-> Text | `name`: A D-Bus interface name.
-> m (Maybe DBusInterfaceInfo) | Returns: A `DBusInterfaceInfo` or `Nothing` if not found. Do not free, it is owned by `info`.

Looks up information about an interface.

The cost of this function is O(n) in number of interfaces.

Since: 2.26

## newForXml

dBusNodeInfoNewForXml Source #

Arguments

:: (HasCallStack, MonadIO m) |
=> Text | `xmlData`: Valid D-Bus introspection XML.
-> m DBusNodeInfo | Returns: A `DBusNodeInfo` structure or `Nothing` if `error` is set. Free with `dBusNodeInfoUnref`. (Can throw `GError`)

Parses `xmlData` and returns a `DBusNodeInfo` representing the data.

The introspection XML must contain exactly one top-level `<node>` element.

Note that this routine is using a GMarkup-based parser that only accepts a subset of valid XML documents.

Since: 2.26

## ref

dBusNodeInfoRef Source #

Arguments

:: (HasCallStack, MonadIO m) |
=> DBusNodeInfo | `info`: A `DBusNodeInfo`
-> m DBusNodeInfo | Returns: The same `info`.

If `info` is statically allocated does nothing. Otherwise increases the reference count.

Since: 2.26

## unref

dBusNodeInfoUnref Source #

Arguments

:: (HasCallStack, MonadIO m) |
=> DBusNodeInfo | `info`: A `DBusNodeInfo`.
-> m () |

If `info` is statically allocated, does nothing. Otherwise decreases the reference count of `info`. When its reference count drops to 0, the memory used is freed.

Since: 2.26

# Properties

## annotations

A pointer to a `Nothing`-terminated array of pointers to `DBusAnnotationInfo` structures or `Nothing` if there are no annotations.

clearDBusNodeInfoAnnotations :: MonadIO m => DBusNodeInfo -> m () Source #

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

    clear #annotations

getDBusNodeInfoAnnotations :: MonadIO m => DBusNodeInfo -> m (Maybe [DBusAnnotationInfo]) Source #

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

    get dBusNodeInfo #annotations

setDBusNodeInfoAnnotations :: MonadIO m => DBusNodeInfo -> Ptr (Ptr DBusAnnotationInfo) -> m () Source #

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

    set dBusNodeInfo [ #annotations := value ]

## interfaces

A pointer to a `Nothing`-terminated array of pointers to `DBusInterfaceInfo` structures or `Nothing` if there are no interfaces.

clearDBusNodeInfoInterfaces :: MonadIO m => DBusNodeInfo -> m () Source #

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

    clear #interfaces

getDBusNodeInfoInterfaces :: MonadIO m => DBusNodeInfo -> m (Maybe [DBusInterfaceInfo]) Source #

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

    get dBusNodeInfo #interfaces

setDBusNodeInfoInterfaces :: MonadIO m => DBusNodeInfo -> Ptr (Ptr DBusInterfaceInfo) -> m () Source #

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

    set dBusNodeInfo [ #interfaces := value ]

## nodes

A pointer to a `Nothing`-terminated array of pointers to `DBusNodeInfo` structures or `Nothing` if there are no nodes.

clearDBusNodeInfoNodes :: MonadIO m => DBusNodeInfo -> m () Source #

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

    clear #nodes

getDBusNodeInfoNodes :: MonadIO m => DBusNodeInfo -> m (Maybe [DBusNodeInfo]) Source #

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

    get dBusNodeInfo #nodes

setDBusNodeInfoNodes :: MonadIO m => DBusNodeInfo -> Ptr (Ptr DBusNodeInfo) -> m () Source #

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

    set dBusNodeInfo [ #nodes := value ]

## path

The path of the node or `Nothing` if omitted. Note that this may be a relative path. See the D-Bus specification for more details.

clearDBusNodeInfoPath :: MonadIO m => DBusNodeInfo -> m () Source #

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

    clear #path

getDBusNodeInfoPath :: MonadIO m => DBusNodeInfo -> m (Maybe Text) Source #

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

    get dBusNodeInfo #path

setDBusNodeInfoPath :: MonadIO m => DBusNodeInfo -> CString -> m () Source #

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

    set dBusNodeInfo [ #path := value ]

## refCount

The reference count or -1 if statically allocated.

getDBusNodeInfoRefCount :: MonadIO m => DBusNodeInfo -> m Int32 Source #

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

    get dBusNodeInfo #refCount

setDBusNodeInfoRefCount :: MonadIO m => DBusNodeInfo -> Int32 -> m () Source #

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

    set dBusNodeInfo [ #refCount := value ]