MediaSourcesCommand

Stores the list of accessible media sources.

Synopsis:

#include <qplayer/qplayer.h>

namespace QPlayer {

    class MediaSourcesCommand : public BaseCommand
    {
        Q_OBJECT

    public:

        explicit MediaSourcesCommand();
    
        inline QList< MediaSource > result()
        {
            return m_result;
        }
    
        inline void setResult( QList< MediaSource> result )
        {
            m_result = result;
        }
    
    signals:

        void complete( MediaSourcesCommand *command );

        void error( MediaSourcesCommand *command );

    };

}

Library:

libqplayer

Description:

Stores the list of accessible media sources. The media source information contained in the list includes the names, hardware types, and supported operations for every media source that can be browsed and has content playable by the current player. No parameters are needed when creating a MediaSourcesCommand object because this operation is not specific to a media source or media node.

When the underlying player has finished writing the list of media sources, the object emits a complete signal to notify clients that information about all accessible media sources can now be read. Clients can then call the result() method to retrieve the media source information.

If the getMediaSources() command fails, the object emits an error signal. You can then call errorMessage() to retrieve a QString describing the error.