LeechCraft  0.6.70-6645-gcd10d7e
Modular cross-platform feature rich live environment.
Media::IPendingAudioSearch Class Referenceabstract

Pending audio search handle. More...

#include "iaudiopile.h"

Classes

struct  Result
 A structure describing a single entry in search result. More...
 

Public Member Functions

virtual ~IPendingAudioSearch ()
 
virtual QObject * GetQObject ()=0
 Returns this object as a QObject. More...
 
virtual QList< ResultGetResults () const =0
 Returns the list of audio tracks. More...
 

Protected Member Functions

virtual void ready ()=0
 Emitted when the search is completed without error. More...
 
virtual void error ()=0
 Emitted when the search is cancelled due to errors. More...
 

Detailed Description

Pending audio search handle.

Interface for a handle to a pending audio search in an IAudioPile. A descendant of this class is returned from IAudioPile::Search() and is used to track the status of audio search requests.

This class has some signals (ready() and error()), and one can use the GetQObject() method to get an object of this class as a QObject and connect to those signals.

Note
The object of this class should schedule its deletion (via QObject::deleteLater(), for example) after ready() or error() signal is emitted. Thus the calling code should never delete it explicitly, neither it should use this object after ready() or error() signals or connect to this signals via Qt::QueuedConnection.
See also
IAudioPile

Definition at line 59 of file iaudiopile.h.

Constructor & Destructor Documentation

virtual Media::IPendingAudioSearch::~IPendingAudioSearch ( )
inlinevirtual

Definition at line 62 of file iaudiopile.h.

Member Function Documentation

virtual void Media::IPendingAudioSearch::error ( )
protectedpure virtual

Emitted when the search is cancelled due to errors.

Empty result set is not an error. ready() will be emitted in that case.

The object will be invalid after this signal is emitted and the event loop is run.

virtual QObject* Media::IPendingAudioSearch::GetQObject ( )
pure virtual

Returns this object as a QObject.

This function can be used to connect to the signals of this class.

Returns
This object as a QObject.
virtual QList<Result> Media::IPendingAudioSearch::GetResults ( ) const
pure virtual

Returns the list of audio tracks.

This function returns the list of audio tracks that were found during this search, or an empty list if no tracks are found, an error occured on the search isn't finished yet.

Returns
The list of found audio tracks.
virtual void Media::IPendingAudioSearch::ready ( )
protectedpure virtual

Emitted when the search is completed without error.

The object will be invalid after this signal is emitted and the event loop is run.


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