gstreamermm 0.10.11

- Main Page
- Modules
- Namespaces
- Classes

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions
Gst::Iterator< CppType > Class Template Reference

A class used to retrieve multiple reference counted elements in a thread safe way. More...

Inheritance diagram for Gst::Iterator< CppType >:
[legend]
Collaboration diagram for Gst::Iterator< CppType >:
[legend]

List of all members.

## Public Member Functions

| Iterator ()
| Default constructor.
| Iterator (GstIterator* castitem, bool take_ownership=true)
| Creates a Gst::Iterator wrapper for a GstIterator object.
IteratorResult | next ()
| Moves to the next iterator item.
Glib::RefPtr< CppType > | operator* () const
| Dereferences the iterator and obtains the underlying Glib::RefPtr<>.
CppType* | operator-> () const
| Accesses underlying object member through the RefPtr<>.
Iterator< CppType >& | operator++ ()
| Prefix auto-increment operator.
Iterator< CppType > | operator++ (int)
| Postfix auto-increment operator.

## Detailed Description

### template<class CppType>
class Gst::Iterator< CppType >

A class used to retrieve multiple reference counted elements in a thread safe way.

Gst::Iterator iterates specifically through elements that are reference counted and therefore dereferencing the elements of the iterator yields a Glib::RefPtr<> to the C++ element type.

## Constructor & Destructor Documentation

template <class CppType >

Gst::Iterator< CppType >::Iterator | ( |  | ) |

Default constructor.

template <class CppType >

Gst::Iterator< CppType >::Iterator | ( | GstIterator< CppType > * | castitem,
|  | bool | take_ownership = `true`
| ) |  | `[explicit]`

Creates a Gst::Iterator wrapper for a GstIterator object.

The underlying castitem will be freed with the Gst::Iterator destruction if a take_ownership value of true is given.

Parameters:

  castitem | The C instance to wrap.
  take_ownership | Whether to take over the underlying C object. If true, C object is freed when wrapper is destroyed.

## Member Function Documentation

template <class CppType >

IteratorResult Gst::Iterator< CppType >::next | ( |  | ) | `[virtual]`

Moves to the next iterator item.

Returns:
  The result of the iteration. MT safe.

Reimplemented from Gst::IteratorBase< CppType >.

template <class CppType >

Glib::RefPtr<CppType> Gst::Iterator< CppType >::operator* | ( |  | ) | const

Dereferences the iterator and obtains the underlying Glib::RefPtr<>.

Reimplemented from Gst::IteratorBasic< CppType >.

template <class CppType >

Iterator<CppType>& Gst::Iterator< CppType >::operator++ | ( |  | ) |

Prefix auto-increment operator.

It advances to the next item in the iterator. It is faster than the postfix operator.

Exceptions:

  std::runtime_error | (if a Gst::ITERATOR_ERROR is encountered or if a concurrent update to the iterator occurs while it iterates).

Reimplemented from Gst::IteratorBasic< CppType >.

template <class CppType >

Iterator<CppType> Gst::Iterator< CppType >::operator++ | ( | int |  | ) |

Postfix auto-increment operator.

It advances to the next item in the iterator.

Exceptions:

  std::runtime_error | (if a Gst::ITERATOR_ERROR is encountered or if a concurrent update to the iterator occurs while it iterates).

Reimplemented from Gst::IteratorBasic< CppType >.

template <class CppType >

CppType* Gst::Iterator< CppType >::operator-> | ( |  | ) | const

Accesses underlying object member through the RefPtr<>.

Reimplemented from Gst::IteratorBasic< CppType >.

The documentation for this class was generated from the following file:

- gstreamermm/iterator.h