• Skip to content
  • Skip to link menu
KDE 4.2 API Reference
  • KDE API Reference
  • KDE-PIM Libraries
  • Sitemap
  • Contact Us
 

akonadi

Akonadi::AgentInstanceModel

Akonadi::AgentInstanceModel Class Reference

#include <agentinstancemodel.h>

Inherits QAbstractItemModel.

List of all members.


Detailed Description

Provides a data model for agent instances.

This class provides the interface of a QAbstractItemModel to access all available agent instances: their name, identifier, supported mimetypes and capabilities.

 Akonadi::AgentInstanceModel *model = new Akonadi::AgentInstanceModel( this );

 QListView *view = new QListView( this );
 view->setModel( model );

To show only agent instances that match a given mime type or special capabilities, use the AgentFilterProxyModel on top of this model.

Author:
Tobias Koenig <tokoe@kde.org>

Definition at line 50 of file agentinstancemodel.h.


Public Types

enum  Roles {
  TypeRole = Qt::UserRole + 1, TypeIdentifierRole, DescriptionRole, MimeTypesRole,
  CapabilitiesRole, InstanceRole, InstanceIdentifierRole, StatusRole,
  StatusMessageRole, ProgressRole, OnlineRole, UserRole = Qt::UserRole + 42
}

Public Member Functions

 AgentInstanceModel (QObject *parent=0)
virtual int columnCount (const QModelIndex &parent=QModelIndex()) const
virtual QVariant data (const QModelIndex &index, int role=Qt::DisplayRole) const
virtual Qt::ItemFlags flags (const QModelIndex &index) const
virtual QVariant headerData (int section, Qt::Orientation orientation, int role=Qt::DisplayRole) const
virtual QModelIndex index (int row, int column, const QModelIndex &parent=QModelIndex()) const
virtual QModelIndex parent (const QModelIndex &index) const
virtual int rowCount (const QModelIndex &parent=QModelIndex()) const
virtual bool setData (const QModelIndex &index, const QVariant &value, int role)
virtual ~AgentInstanceModel ()

Member Enumeration Documentation

enum Akonadi::AgentInstanceModel::Roles

Describes the roles of this model.

Enumerator:
TypeRole  The agent type itself.
TypeIdentifierRole  The identifier of the agent type.
DescriptionRole  A description of the agent type.
MimeTypesRole  A list of supported mimetypes.
CapabilitiesRole  A list of supported capabilities.
InstanceRole  The agent instance itself.
InstanceIdentifierRole  The identifier of the agent instance.
StatusRole  The current status (numerical) of the instance.
StatusMessageRole  A textual presentation of the current status.
ProgressRole  The current progress (numerical in percent) of an operation.
OnlineRole  The current online/offline status.
UserRole  Role for user extensions.

Definition at line 58 of file agentinstancemodel.h.


Constructor & Destructor Documentation

AgentInstanceModel::AgentInstanceModel ( QObject *  parent = 0  )  [explicit]

Creates a new agent instance model.

Parameters:
parent The parent object.

Definition at line 80 of file agentinstancemodel.cpp.

AgentInstanceModel::~AgentInstanceModel (  )  [virtual]

Destroys the agent instance model.

Definition at line 99 of file agentinstancemodel.cpp.


The documentation for this class was generated from the following files:
  • agentinstancemodel.h
  • agentinstancemodel.cpp

akonadi

Skip menu "akonadi"
  • Main Page
  • Modules
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

KDE-PIM Libraries

Skip menu "KDE-PIM Libraries"
  • akonadi
  • kabc
  • kblog
  • kcal
  • kimap
  • kioslave
  •   imap4
  •   mbox
  • kldap
  • kmime
  • kpimidentities
  •   richtextbuilders
  • kpimutils
  • kresources
  • ktnef
  • kxmlrpcclient
  • mailtransport
  • qgpgme
  • syndication
  •   atom
  •   rdf
  •   rss2
Generated for KDE-PIM Libraries by doxygen 1.5.6
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal