Copyright | Will Thompson, Iñaki García Etxebarria and Jonas Platte |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria (garetxe@gmail.com) |
Safe Haskell | None |
Language | Haskell2010 |
MenuAttributeIter
is an opaque structure type. You must access it
using the functions below.
- newtype MenuAttributeIter = MenuAttributeIter (ManagedPtr MenuAttributeIter)
- class GObject o => IsMenuAttributeIter o
- toMenuAttributeIter :: IsMenuAttributeIter o => o -> IO MenuAttributeIter
- noMenuAttributeIter :: Maybe MenuAttributeIter
- data MenuAttributeIterGetNameMethodInfo
- menuAttributeIterGetName :: (HasCallStack, MonadIO m, IsMenuAttributeIter a) => a -> m Text
- data MenuAttributeIterGetNextMethodInfo
- menuAttributeIterGetNext :: (HasCallStack, MonadIO m, IsMenuAttributeIter a) => a -> m (Bool, Text, GVariant)
- data MenuAttributeIterGetValueMethodInfo
- menuAttributeIterGetValue :: (HasCallStack, MonadIO m, IsMenuAttributeIter a) => a -> m GVariant
- data MenuAttributeIterNextMethodInfo
- menuAttributeIterNext :: (HasCallStack, MonadIO m, IsMenuAttributeIter a) => a -> m Bool
Exported types
newtype MenuAttributeIter Source #
GObject MenuAttributeIter Source # | |
IsObject MenuAttributeIter Source # | |
IsMenuAttributeIter MenuAttributeIter Source # | |
((~) * info (ResolveMenuAttributeIterMethod t MenuAttributeIter), MethodInfo * info MenuAttributeIter p) => IsLabel t (MenuAttributeIter -> p) Source # | |
((~) * info (ResolveMenuAttributeIterMethod t MenuAttributeIter), MethodInfo * info MenuAttributeIter p) => IsLabelProxy t (MenuAttributeIter -> p) Source # | |
HasAttributeList * MenuAttributeIter Source # | |
type AttributeList MenuAttributeIter Source # | |
type SignalList MenuAttributeIter Source # | |
class GObject o => IsMenuAttributeIter o Source #
toMenuAttributeIter :: IsMenuAttributeIter o => o -> IO MenuAttributeIter Source #
Methods
getName
data MenuAttributeIterGetNameMethodInfo Source #
((~) * signature (m Text), MonadIO m, IsMenuAttributeIter a) => MethodInfo * MenuAttributeIterGetNameMethodInfo a signature Source # | |
menuAttributeIterGetName Source #
:: (HasCallStack, MonadIO m, IsMenuAttributeIter a) | |
=> a |
|
-> m Text | Returns: the name of the attribute |
Gets the name of the attribute at the current iterator position, as a string.
The iterator is not advanced.
Since: 2.32
getNext
data MenuAttributeIterGetNextMethodInfo Source #
((~) * signature (m (Bool, Text, GVariant)), MonadIO m, IsMenuAttributeIter a) => MethodInfo * MenuAttributeIterGetNextMethodInfo a signature Source # | |
menuAttributeIterGetNext Source #
:: (HasCallStack, MonadIO m, IsMenuAttributeIter a) | |
=> a |
|
-> m (Bool, Text, GVariant) | Returns: |
This function combines menuAttributeIterNext
with
menuAttributeIterGetName
and menuAttributeIterGetValue
.
First the iterator is advanced to the next (possibly first) attribute.
If that fails, then False
is returned and there are no other
effects.
If successful, name
and value
are set to the name and value of the
attribute that has just been advanced to. At this point,
menuAttributeIterGetName
and menuAttributeIterGetValue
will
return the same values again.
The value returned in name
remains valid for as long as the iterator
remains at the current position. The value returned in value
must
be unreffed using variantUnref
when it is no longer in use.
Since: 2.32
getValue
data MenuAttributeIterGetValueMethodInfo Source #
((~) * signature (m GVariant), MonadIO m, IsMenuAttributeIter a) => MethodInfo * MenuAttributeIterGetValueMethodInfo a signature Source # | |
menuAttributeIterGetValue Source #
:: (HasCallStack, MonadIO m, IsMenuAttributeIter a) | |
=> a |
|
-> m GVariant | Returns: the value of the current attribute |
Gets the value of the attribute at the current iterator position.
The iterator is not advanced.
Since: 2.32
next
data MenuAttributeIterNextMethodInfo Source #
((~) * signature (m Bool), MonadIO m, IsMenuAttributeIter a) => MethodInfo * MenuAttributeIterNextMethodInfo a signature Source # | |
menuAttributeIterNext Source #
:: (HasCallStack, MonadIO m, IsMenuAttributeIter a) | |
=> a |
|
-> m Bool | Returns: |
Attempts to advance the iterator to the next (possibly first) attribute.
True
is returned on success, or False
if there are no more
attributes.
You must call this function when you first acquire the iterator to advance it to the first attribute (and determine if the first attribute exists at all).
Since: 2.32