Copyright | Will Thompson and Iñaki García Etxebarria |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
An opaque type used to iterate over a SoupMessageHeaders
structure.
After intializing the iterator with MessageHeadersIter.init
, call
[methodmessageHeadersIter
.next] to fetch data from it.
You may not modify the headers while iterating over them.
Synopsis
- newtype MessageHeadersIter = MessageHeadersIter (ManagedPtr MessageHeadersIter)
- newZeroMessageHeadersIter :: MonadIO m => m MessageHeadersIter
- messageHeadersIterInit :: (HasCallStack, MonadIO m) => MessageHeaders -> m MessageHeadersIter
- messageHeadersIterNext :: (HasCallStack, MonadIO m) => MessageHeadersIter -> m (Bool, Text, Text)
Exported types
newtype MessageHeadersIter Source #
Memory-managed wrapper type.
MessageHeadersIter (ManagedPtr MessageHeadersIter) |
Instances
Eq MessageHeadersIter Source # | |
Defined in GI.Soup.Structs.MessageHeadersIter (==) :: MessageHeadersIter -> MessageHeadersIter -> Bool # (/=) :: MessageHeadersIter -> MessageHeadersIter -> Bool # | |
BoxedPtr MessageHeadersIter Source # | |
Defined in GI.Soup.Structs.MessageHeadersIter | |
CallocPtr MessageHeadersIter Source # | |
Defined in GI.Soup.Structs.MessageHeadersIter | |
ManagedPtrNewtype MessageHeadersIter Source # | |
Defined in GI.Soup.Structs.MessageHeadersIter toManagedPtr :: MessageHeadersIter -> ManagedPtr MessageHeadersIter | |
tag ~ 'AttrSet => Constructible MessageHeadersIter tag Source # | |
Defined in GI.Soup.Structs.MessageHeadersIter new :: MonadIO m => (ManagedPtr MessageHeadersIter -> MessageHeadersIter) -> [AttrOp MessageHeadersIter tag] -> m MessageHeadersIter |
newZeroMessageHeadersIter :: MonadIO m => m MessageHeadersIter Source #
Construct a MessageHeadersIter
struct initialized to zero.
Methods
Click to display all available methods, including inherited ones
init
messageHeadersIterInit Source #
:: (HasCallStack, MonadIO m) | |
=> MessageHeaders |
|
-> m MessageHeadersIter |
Initializes iter
for iterating hdrs
.
next
messageHeadersIterNext Source #
:: (HasCallStack, MonadIO m) | |
=> MessageHeadersIter |
|
-> m (Bool, Text, Text) | Returns: |
Yields the next name/value pair in the [structmessageHeaders
] being
iterated by iter
.
If iter
has already yielded the last header, then
[methodmessageHeadersIter
.next] will return False
and name
and value
will be unchanged.