#include <TelepathyQt4/Client/Account>
If the Telepathy account is deleted from the AccountManager, this object will not be deleted automatically; however, it will emit invalidated() and will cease to be useful.
Telepathy::Client::Account::Account | ( | AccountManager * | am, | |
const QString & | objectPath, | |||
QObject * | parent = 0 | |||
) |
Telepathy::Client::Account::~Account | ( | ) | [virtual] |
Class destructor.
QSet< uint > Telepathy::Client::Account::actualFeatures | ( | ) | const |
Telepathy::SimplePresence Telepathy::Client::Account::automaticPresence | ( | ) | const |
Set the presence status that this account should have if it is brought online.
void Telepathy::Client::Account::automaticPresenceChanged | ( | const Telepathy::SimplePresence & | ) | const [signal] |
const Telepathy::Avatar & Telepathy::Client::Account::avatar | ( | ) | const |
Get this account avatar.
Note that in order to make this method works you should call Account::becomeReady(FeatureAvatar) and wait for it to finish successfully.
References FeatureAvatar, isReady(), and Telepathy::warning().
void Telepathy::Client::Account::avatarChanged | ( | const Telepathy::Avatar & | ) | [signal] |
AccountInterfaceAvatarInterface * Telepathy::Client::Account::avatarInterface | ( | InterfaceSupportedChecking | check = CheckInterfaceSupported |
) | const [inline] |
Convenience function for getting a Avatar interface proxy.
AccountInterface * Telepathy::Client::Account::baseInterface | ( | ) | const [protected] |
Get the AccountInterface for this Account. This method is protected since the convenience methods provided by this class should generally be used instead of calling D-Bus methods directly.
Referenced by remove(), and updateParameters().
PendingReady * Telepathy::Client::Account::becomeReady | ( | const QSet< uint > & | requestedFeatures = QSet<uint>() |
) |
Return a pending ready account which will succeed when this object finishes its initial setup, or will fail if a fatal error occurs during this initial setup.
If an empty set is used FeatureCore will be considered as the requested feature.
requestedFeatures | The features which should be enabled. |
QString Telepathy::Client::Account::cmName | ( | ) | const |
QSharedPointer< Connection > Telepathy::Client::Account::connection | ( | ) | const |
Get the Connection object for this account.
Note that the Connection object won't be cached by account, and should be done by the application itself.
Remember to call Connection::becomeReady on the new connection, to make sure it is ready before using it.
References Telepathy::Client::DBusProxy::dbusConnection(), and Telepathy::Client::DBusProxy::objectPath().
QString Telepathy::Client::Account::connectionObjectPath | ( | ) | const |
Telepathy::ConnectionStatus Telepathy::Client::Account::connectionStatus | ( | ) | const |
Get the connection status of this account.
void Telepathy::Client::Account::connectionStatusChanged | ( | Telepathy::ConnectionStatus | , | |
Telepathy::ConnectionStatusReason | ||||
) | [signal] |
Telepathy::ConnectionStatusReason Telepathy::Client::Account::connectionStatusReason | ( | ) | const |
Get the connection status reason of this account.
bool Telepathy::Client::Account::connectsAutomatically | ( | ) | const |
Get whether this account should be put online automatically whenever possible.
true
if it should try to connect automatically, false
otherwise. void Telepathy::Client::Account::connectsAutomaticallyPropertyChanged | ( | bool | ) | [signal] |
Telepathy::SimplePresence Telepathy::Client::Account::currentPresence | ( | ) | const |
Get the actual presence of this account.
void Telepathy::Client::Account::currentPresenceChanged | ( | const Telepathy::SimplePresence & | ) | const [signal] |
QString Telepathy::Client::Account::displayName | ( | ) | const |
void Telepathy::Client::Account::displayNameChanged | ( | const QString & | ) | [signal] |
bool Telepathy::Client::Account::haveConnection | ( | ) | const |
Return whether this account have a connection object that can be retrieved using connection().
true
if a connection object can be retrieved, false
otherwise void Telepathy::Client::Account::haveConnectionChanged | ( | bool | haveConnection | ) | [signal] |
QString Telepathy::Client::Account::icon | ( | ) | const |
void Telepathy::Client::Account::iconChanged | ( | const QString & | ) | [signal] |
QStringList Telepathy::Client::Account::interfaces | ( | ) | const |
Referenced by optionalInterface().
bool Telepathy::Client::Account::isEnabled | ( | ) | const |
Get whether this account is enabled.
Gives the users the possibility to prevent an account from being used. This flag does not change the validity of the account.
true
if the account is enabled, false
otherwise. bool Telepathy::Client::Account::isReady | ( | const QSet< uint > & | features = QSet<uint>() |
) | const |
Return whether this object has finished its initial setup.
This is mostly useful as a sanity check, in code that shouldn't be run until the object is ready. To wait for the object to be ready, call becomeReady() and connect to the finished signal on the result.
features | The features which should be tested |
true
if the object has finished its initial setup for basic functionality plus the given features Referenced by avatar(), and protocolInfo().
bool Telepathy::Client::Account::isValidAccount | ( | ) | const |
Get whether this is a valid account.
If true, this account is considered by the account manager to be complete and usable. If false, user action is required to make it usable, and it will never attempt to connect (for instance, this might be caused by the absence of a required parameter).
true
if the account is valid, false
otherwise. AccountManager * Telepathy::Client::Account::manager | ( | ) | const |
Get the AccountManager from which this Account was created.
QSet< uint > Telepathy::Client::Account::missingFeatures | ( | ) | const |
QString Telepathy::Client::Account::nickname | ( | ) | const |
void Telepathy::Client::Account::nicknameChanged | ( | const QString & | ) | [signal] |
QString Telepathy::Client::Account::normalizedName | ( | ) | const |
void Telepathy::Client::Account::normalizedNameChanged | ( | const QString & | ) | [signal] |
Telepathy::Client::Account::optionalInterface | ( | InterfaceSupportedChecking | check = CheckInterfaceSupported |
) | const [inline] |
Get a pointer to a valid instance of a given Account optional interface class, associated with the same remote object the Account is associated with, and destroyed at the same time the Account is destroyed.
If the list returned by interfaces() doesn't contain the name of the interface requested 0
is returned. This check can be bypassed by specifying BypassInterfaceCheck for check
, in which case a valid instance is always returned.
If the object is not ready, the list returned by interfaces() isn't guaranteed to yet represent the full set of interfaces supported by the remote object. Hence the check might fail even if the remote object actually supports the requested interface; using BypassInterfaceCheck is suggested when the Account is not suitably ready.
Interface | Class of the optional interface to get. |
check | Should an instance be returned even if it can't be determined that the remote object supports the requested interface. |
0
. References interfaces().
QVariantMap Telepathy::Client::Account::parameters | ( | ) | const |
void Telepathy::Client::Account::parametersChanged | ( | const QVariantMap & | ) | [signal] |
DBus::propertiesInterface * Telepathy::Client::Account::propertiesInterface | ( | ) | const [inline] |
Convenience function for getting a Properties interface proxy. The Account interface relies on properties, so this interface is always assumed to be present.
References Telepathy::Client::DBusProxy::BypassInterfaceCheck.
Referenced by setAutomaticPresence(), setAvatar(), setConnectsAutomatically(), setDisplayName(), setEnabled(), setIcon(), setNickname(), and setRequestedPresence().
QString Telepathy::Client::Account::protocol | ( | ) | const |
ProtocolInfo * Telepathy::Client::Account::protocolInfo | ( | ) | const |
Get the protocol info for this account protocol.
Note that in order to make this method works you should call Account::becomeReady(FeatureProtocolInfo) and wait for it to finish successfully.
References FeatureProtocolInfo, isReady(), and Telepathy::warning().
PendingOperation * Telepathy::Client::Account::remove | ( | ) |
Delete this account.
References baseInterface().
QSet< uint > Telepathy::Client::Account::requestedFeatures | ( | ) | const |
Telepathy::SimplePresence Telepathy::Client::Account::requestedPresence | ( | ) | const |
Get the requested presence of this account.
When this is changed, the account manager should attempt to manipulate the connection manager to make CurrentPresence match RequestedPresence as closely as possible.
void Telepathy::Client::Account::requestedPresenceChanged | ( | const Telepathy::SimplePresence & | ) | const [signal] |
PendingOperation * Telepathy::Client::Account::setAutomaticPresence | ( | const Telepathy::SimplePresence & | value | ) |
Set the presence status that this account should have if it is brought online.
value | Presence status to set when this account is put online. |
References propertiesInterface(), and TELEPATHY_INTERFACE_ACCOUNT.
PendingOperation * Telepathy::Client::Account::setAvatar | ( | const Telepathy::Avatar & | avatar | ) |
Set this account avatar.
avatar | The avatar's MIME type and data. |
References propertiesInterface(), TELEPATHY_ERROR_NOT_IMPLEMENTED, and TELEPATHY_INTERFACE_ACCOUNT_INTERFACE_AVATAR.
PendingOperation * Telepathy::Client::Account::setConnectsAutomatically | ( | bool | value | ) |
Set whether this account should be put online automatically whenever possible.
value | Value indicating if this account should be put online whenever possible. |
References propertiesInterface(), and TELEPATHY_INTERFACE_ACCOUNT.
PendingOperation * Telepathy::Client::Account::setDisplayName | ( | const QString & | value | ) |
Set this account display name.
value | Account display name. |
References propertiesInterface(), and TELEPATHY_INTERFACE_ACCOUNT.
PendingOperation * Telepathy::Client::Account::setEnabled | ( | bool | value | ) |
Set whether this account is enabled.
value | Whether this account should be enabled or disabled. |
References propertiesInterface(), and TELEPATHY_INTERFACE_ACCOUNT.
PendingOperation * Telepathy::Client::Account::setIcon | ( | const QString & | value | ) |
Set this account icon.
value | Account icon name. |
References propertiesInterface(), and TELEPATHY_INTERFACE_ACCOUNT.
PendingOperation * Telepathy::Client::Account::setNickname | ( | const QString & | value | ) |
Set the account nickname.
value | Account nickname. |
References propertiesInterface(), and TELEPATHY_INTERFACE_ACCOUNT.
PendingOperation * Telepathy::Client::Account::setRequestedPresence | ( | const Telepathy::SimplePresence & | value | ) |
Set the requested presence.
value | The requested presence. |
References propertiesInterface(), and TELEPATHY_INTERFACE_ACCOUNT.
void Telepathy::Client::Account::stateChanged | ( | bool | ) | [signal] |
QString Telepathy::Client::Account::uniqueIdentifier | ( | ) | const |
Get the unique identifier for this account.
This identifier should be unique per AccountManager implementation, i.e. at least per QDBusConnection.
References Telepathy::Client::DBusProxy::objectPath().
PendingOperation * Telepathy::Client::Account::updateParameters | ( | const QVariantMap & | set, | |
const QStringList & | unset | |||
) |
Update this account parameters.
set | Parameters to set. | |
unset | Parameters to unset. |
References baseInterface().
void Telepathy::Client::Account::validityChanged | ( | bool | ) | [signal] |
friend struct Private [friend] |
Reimplemented from Telepathy::Client::StatelessDBusProxy.