• Skip to content
  • Skip to link menu
KDE 4.2 API Reference
  • KDE API Reference
  • kdenetwork
  • Sitemap
  • Contact Us
 

kopete/kopete

KopeteDBusInterface Class Reference

#include <kopetedbusinterface.h>

Inheritance diagram for KopeteDBusInterface:

Inheritance graph
[legend]

List of all members.


Detailed Description

Public D-Bus interface for Kopete.

Author:
Michaƫl Larouche <larouche@kde.org>

Definition at line 30 of file kopetedbusinterface.h.


Public Slots

QStringList accounts () const
bool addContact (const QString &protocolName, const QString &accountId, const QString &contactId, const QString &displayName, const QString &groupName=QString())
void connect (const QString &protocolName, const QString &accountId)
void connectAll ()
QVariantMap contactProperties (const QString &contactId)
QStringList contacts () const
QStringList contactsByFilter (const QString &filter) const
void disconnect (const QString &protocolName, const QString &accountId)
void disconnectAll ()
QString getDisplayName (const QString &contactId)
QStringList identities () const
bool isConnected (const QString &protocolName, const QString &accountId)
bool isContactOnline (const QString &contactId)
QString labelForIdentity (const QString &id) const
void openChat (const QString &contactId)
QStringList protocols () const
void sendFile (const QString &contactId, const QString &fileUrl)
void sendMessage (const QString &contactId, const QString &message)
void setIdentityAvatar (const QString &avatarUrl, const QString &identityId=QString())
void setIdentityNickName (const QString &nickName, const QString &identityId=QString())
void setIdentityOnlineStatus (const QString &status, const QString &message, const QString &identityId=QString())
void setOnlineStatus (const QString &status, const QString &message=QString())
void setStatusMessage (const QString &message)

Signals

void contactChanged (QString contactId)

Public Member Functions

 KopeteDBusInterface (QObject *parent)
 ~KopeteDBusInterface ()

Constructor & Destructor Documentation

KopeteDBusInterface::KopeteDBusInterface ( QObject *  parent  ) 

Constructor.

Parameters:
parent QObject parent

Definition at line 51 of file kopetedbusinterface.cpp.

KopeteDBusInterface::~KopeteDBusInterface (  ) 

Destructor.

Definition at line 61 of file kopetedbusinterface.cpp.


Member Function Documentation

QStringList KopeteDBusInterface::accounts (  )  const [slot]

Get a list of all account's ID.

Returns:
a list of all accounts' ID

Definition at line 224 of file kopetedbusinterface.cpp.

bool KopeteDBusInterface::addContact ( const QString &  protocolName,
const QString &  accountId,
const QString &  contactId,
const QString &  displayName,
const QString &  groupName = QString() 
) [slot]

Adds a contact with the specified params.

Parameters:
protocolName The name of the protocol this contact is for ("Jabber", etc)
accountId The account ID to add the contact to
contactId The unique ID for this protocol
displayName The displayName of the contact (may equal userId for some protocols
groupName The name of the group to add the contact to
Returns:
Weather or not the contact was added successfully

Definition at line 313 of file kopetedbusinterface.cpp.

void KopeteDBusInterface::connect ( const QString &  protocolName,
const QString &  accountId 
) [slot]

Connect a given account in the given protocol.

Parameters:
protocolName The protocol name (ex: Jabber, Yahoo, Messenger)
accountId Account ID

Definition at line 381 of file kopetedbusinterface.cpp.

void KopeteDBusInterface::connectAll (  )  [slot]

Connect all accounts.

Definition at line 236 of file kopetedbusinterface.cpp.

void KopeteDBusInterface::contactChanged ( QString  contactId  )  [signal]

Contact properties have changed: displayName, avatar, pending messages.

..

Parameters:
contactId ID of the contact whose properties have changed

QVariantMap KopeteDBusInterface::contactProperties ( const QString &  contactId  )  [slot]

Look up details for a specific contact.

Parameters:
contactId Contact ID or display Name
Returns:
A QVariantMap containing contact properties like online status, avatar, ...

Todo:
: export status message title as well or merge both?

Definition at line 415 of file kopetedbusinterface.cpp.

QStringList KopeteDBusInterface::contacts (  )  const [slot]

Return all contacts.

Returns:
a list of all contacts display name

Definition at line 75 of file kopetedbusinterface.cpp.

QStringList KopeteDBusInterface::contactsByFilter ( const QString &  filter  )  const [slot]

Get a filered list of contacts based on the filter.

Accetable filters are: online, reachable, filecapable. If no accepted filters are provived, it will return an empty list.

Returns:
list of filtered contacts

Definition at line 80 of file kopetedbusinterface.cpp.

void KopeteDBusInterface::disconnect ( const QString &  protocolName,
const QString &  accountId 
) [slot]

Disconnect a given account in the given protocol.

Parameters:
protocolName The protocol name (ex: Jabber, Yahoo, Messenger)
accountId Account ID

Definition at line 398 of file kopetedbusinterface.cpp.

void KopeteDBusInterface::disconnectAll (  )  [slot]

Disconnect all accounts.

Definition at line 243 of file kopetedbusinterface.cpp.

QString KopeteDBusInterface::getDisplayName ( const QString &  contactId  )  [slot]

Retrieve the Display Name from the given contact ID.

Parameters:
contactId Metacontact contactId

Definition at line 295 of file kopetedbusinterface.cpp.

QStringList KopeteDBusInterface::identities (  )  const [slot]

Get a list of all identities' ID.

Returns:
a list of all identities' ID

Definition at line 198 of file kopetedbusinterface.cpp.

bool KopeteDBusInterface::isConnected ( const QString &  protocolName,
const QString &  accountId 
) [slot]

Get information if we are connected to a given account in the given protocol.

Parameters:
protocolName The protocol name (ex: Jabber, Yahoo, Messenger)
accountId Account ID
Returns:
if the given protocolName and accountId are valid and we are connected then true is returned else false is returned.

Definition at line 367 of file kopetedbusinterface.cpp.

bool KopeteDBusInterface::isContactOnline ( const QString &  contactId  )  [slot]

Get the Online Status of the contact.

Parameters:
contactId Metacontact ID or displayName

Definition at line 304 of file kopetedbusinterface.cpp.

QString KopeteDBusInterface::labelForIdentity ( const QString &  id  )  const [slot]

Get UI labels for identities.

Returns:
a label for a identity.

Definition at line 210 of file kopetedbusinterface.cpp.

void KopeteDBusInterface::openChat ( const QString &  contactId  )  [slot]

Open a chat window for the given contact.

Parameters:
contactId Metacontact ID or displayName

Definition at line 281 of file kopetedbusinterface.cpp.

QStringList KopeteDBusInterface::protocols (  )  const [slot]

Get a list of all protocol names.

Returns:
a list of all protocol names.

Definition at line 65 of file kopetedbusinterface.cpp.

void KopeteDBusInterface::sendFile ( const QString &  contactId,
const QString &  fileUrl 
) [slot]

Send a file to the given contact.

Parameters:
contactId Metacontact ID or displayName to send a file to
fileUrl Url of the file to send

Definition at line 353 of file kopetedbusinterface.cpp.

void KopeteDBusInterface::sendMessage ( const QString &  contactId,
const QString &  message 
) [slot]

Send a message to the given contact.

Parameters:
contactId Metacontact ID or displayName to send a message to
message The message to send

Definition at line 261 of file kopetedbusinterface.cpp.

void KopeteDBusInterface::setIdentityAvatar ( const QString &  avatarUrl,
const QString &  identityId = QString() 
) [slot]

Set the avatar for the given identity.

To set the avatar of the default identity, use an empty identityId

Parameters:
avatarUrl Path to the avatar image
identityId Identity ID to modify. If empty, will use default identity

Definition at line 149 of file kopetedbusinterface.cpp.

void KopeteDBusInterface::setIdentityNickName ( const QString &  nickName,
const QString &  identityId = QString() 
) [slot]

Set the nickname for the given identity.

To set the nickname of the default identity, use an empty identityId

Parameters:
nickName New nickname of the identity
identityId Identity ID to modify. If empty, will use default identity.

Definition at line 128 of file kopetedbusinterface.cpp.

void KopeteDBusInterface::setIdentityOnlineStatus ( const QString &  status,
const QString &  message,
const QString &  identityId = QString() 
) [slot]

Set the online status for the given identity.

To set the online status of the default identity, use an empty identityId

Parameters:
status The english word for the status you want.
message Status message, can be an empty string
identityId Identity ID to modify. If empty, will use default identity

Definition at line 178 of file kopetedbusinterface.cpp.

void KopeteDBusInterface::setOnlineStatus ( const QString &  status,
const QString &  message = QString() 
) [slot]

Change the online status for all accounts.

Accepted values for status are: Online, Busy, Away, Available

Parameters:
status The english word for the status you want.
message Optional status message

Definition at line 249 of file kopetedbusinterface.cpp.

void KopeteDBusInterface::setStatusMessage ( const QString &  message  )  [slot]

Change the status message for all accounts.

Use an empty string to clear the status message

Parameters:
message Status message

Definition at line 256 of file kopetedbusinterface.cpp.


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

kopete/kopete

Skip menu "kopete/kopete"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdenetwork

Skip menu "kdenetwork"
  • kget
  • kopete
  •   kopete
  •   libkopete
  •       libpapillon
  • krfb
Generated for kdenetwork by doxygen 1.5.4
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