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 |
The SequenceIter
struct is an opaque data type representing an
iterator pointing into a Sequence
.
Synopsis
- newtype SequenceIter = SequenceIter (ManagedPtr SequenceIter)
- sequenceIterCompare :: (HasCallStack, MonadIO m) => SequenceIter -> SequenceIter -> m Int32
- sequenceIterGetPosition :: (HasCallStack, MonadIO m) => SequenceIter -> m Int32
- sequenceIterGetSequence :: (HasCallStack, MonadIO m) => SequenceIter -> m Sequence
- sequenceIterIsBegin :: (HasCallStack, MonadIO m) => SequenceIter -> m Bool
- sequenceIterIsEnd :: (HasCallStack, MonadIO m) => SequenceIter -> m Bool
- sequenceIterMove :: (HasCallStack, MonadIO m) => SequenceIter -> Int32 -> m SequenceIter
- sequenceIterNext :: (HasCallStack, MonadIO m) => SequenceIter -> m SequenceIter
- sequenceIterPrev :: (HasCallStack, MonadIO m) => SequenceIter -> m SequenceIter
Exported types
newtype SequenceIter Source #
Memory-managed wrapper type.
Instances
Eq SequenceIter Source # | |
Defined in GI.GLib.Structs.SequenceIter (==) :: SequenceIter -> SequenceIter -> Bool # (/=) :: SequenceIter -> SequenceIter -> Bool # | |
ManagedPtrNewtype SequenceIter Source # | |
Defined in GI.GLib.Structs.SequenceIter | |
BoxedPtr SequenceIter Source # | |
Defined in GI.GLib.Structs.SequenceIter boxedPtrCopy :: SequenceIter -> IO SequenceIter # boxedPtrFree :: SequenceIter -> IO () # |
Methods
Overloaded methods
compare
:: (HasCallStack, MonadIO m) | |
=> SequenceIter |
|
-> SequenceIter |
|
-> m Int32 | Returns: a negative number if |
Returns a negative number if a
comes before b
, 0 if they are equal,
and a positive number if a
comes after b
.
The a
and b
iterators must point into the same sequence.
Since: 2.14
getPosition
sequenceIterGetPosition Source #
:: (HasCallStack, MonadIO m) | |
=> SequenceIter |
|
-> m Int32 | Returns: the position of |
Returns the position of iter
Since: 2.14
getSequence
sequenceIterGetSequence Source #
:: (HasCallStack, MonadIO m) | |
=> SequenceIter |
|
-> m Sequence | Returns: the |
Returns the Sequence
that iter
points into.
Since: 2.14
isBegin
:: (HasCallStack, MonadIO m) | |
=> SequenceIter |
|
-> m Bool | Returns: whether |
Returns whether iter
is the begin iterator
Since: 2.14
isEnd
:: (HasCallStack, MonadIO m) | |
=> SequenceIter |
|
-> m Bool | Returns: Whether |
Returns whether iter
is the end iterator
Since: 2.14
move
:: (HasCallStack, MonadIO m) | |
=> SequenceIter |
|
-> Int32 |
|
-> m SequenceIter | Returns: a |
Returns the SequenceIter
which is delta
positions away from iter
.
If iter
is closer than -delta
positions to the beginning of the sequence,
the begin iterator is returned. If iter
is closer than delta
positions
to the end of the sequence, the end iterator is returned.
Since: 2.14
next
:: (HasCallStack, MonadIO m) | |
=> SequenceIter |
|
-> m SequenceIter | Returns: a |
Returns an iterator pointing to the next position after iter
.
If iter
is the end iterator, the end iterator is returned.
Since: 2.14
prev
:: (HasCallStack, MonadIO m) | |
=> SequenceIter |
|
-> m SequenceIter | Returns: a |
Returns an iterator pointing to the previous position before iter
.
If iter
is the begin iterator, the begin iterator is returned.
Since: 2.14