All Classes Functions Variables Typedefs Friends Pages
Public Member Functions | List of all members
Glympse::ILinkedAccountsManager Struct Referenceabstract
Inheritance diagram for Glympse::ILinkedAccountsManager:
Inheritance graph
[legend]

Public Member Functions

virtual bool isSynced ()=0
 Determines whether or not the linked accounts manager has completed its initial sync with the server. More...
 
virtual GEventSink confirm (const GString &type, const GPrimitive &profile)=0
 Sends confirmation code required to link account of GC::LINKED_ACCOUNT_TYPE_PHONE of GC::LINKED_ACCOUNT_TYPE_EMAIL type. More...
 
virtual GLinkedAccount link (const GString &type, const GPrimitive &profile)=0
 Links an account of the specified type using the account profile information provided. More...
 
virtual GLinkedAccount link (const GString &type, const GPrimitive &profile, bool force)=0
 Links an account of the specified type using the account profile information provided, forcefully if necessary. More...
 
virtual GLinkedAccount unlink (const GString &type)=0
 Unlinks the account of the specified type. More...
 
virtual GLinkedAccount refresh (const GString &type, const GPrimitive &profile)=0
 Refreshes an account of the specified type using the account profile information provided. More...
 
virtual GPrimitive getAccountProperty (const GString &type, const GString &name)=0
 Retrieves a property previously set for the specified account type by name. More...
 
virtual void setAccountProperty (const GString &type, const GString &name, const GPrimitive &value)=0
 Sets a property for the specified account type by name. More...
 
virtual GLinkedAccount getAccount (const GString &type)=0
 Retrieves the linked account for the specified type. More...
 
virtual GArray< GLinkedAccount >
::ptr 
getAccounts ()=0
 Retrieves the list of all linked accounts. More...
 
virtual int32 getCount (bool loginEnabled)=0
 Retrieves the number of linked accounts satisfying the specified criteria. More...
 
virtual bool refresh ()=0
 Refreshes the entire list of linked accounts and their status ("freshness"). More...
 
virtual bool canSend (const GInvite &invite)=0
 Determines if account required for sending the invite is linked to user's profile. More...
 
- Public Member Functions inherited from Glympse::IEventSink
virtual bool addListener (const GEventListener &eventListener)=0
 Registeres event listener on the sink. More...
 
virtual bool removeListener (const GEventListener &eventListener)=0
 Unsubscribes listener from events coming from this sink.
 
virtual GArray< GEventListener >
::ptr 
getListeners ()=0
 Provides access to the collection of current listeners. More...
 
virtual bool hasContext (int64 key)=0
 Checks, where user context identified by key is already associated with the object.
 
virtual void associateContext (int64 key, const GCommonObj &value)=0
 Associates specific context (user data) with the sink. More...
 
virtual GCommonObj getContext (int64 key)=0
 Returns context associated with the sink, or NULL, if it is not found.
 
virtual void clearContext (int64 key)=0
 Clears context identified by key argument.
 
virtual GEnumeration< GLong >::ptr getContextKeys ()=0
 Gets enumeration of all context keys associated with the sink.
 
virtual void deriveContext (const GEventSink &sink)=0
 Derives context from another sink object.
 
- Public Member Functions inherited from Glympse::IEventListener
virtual void eventsOccurred (const GGlympse &glympse, int32 listener, int32 events, const GCommonObj &obj)=0
 This method is invoked each time, when sink object notifies subscriber on an event. More...
 
- Public Member Functions inherited from Glympse::ICommon
virtual int32 retain ()=0
 Add a reference to our object in a COM-like way.
 
virtual int32 release ()=0
 Release a reference to our object in a COM-like way.
 
virtual int32 hold ()=0
 Add a reference to our object in a COM-like way.
 
virtual int32 unhold ()=0
 Release a reference to our object in a COM-like way.
 
virtual int32 hashCode ()=0
 Returns an integer hash code for this object.
 
virtual bool equals (const GCommonObj &o)=0
 Compares this instance with the specified object and indicates if they are equal. More...
 
virtual GString toString ()=0
 Returns a string containing a concise, human-readable description of this object. More...
 
virtual void attachObject (const GCommon &obj)=0
 Asociates arbitrary object with the instance.
 
virtual GCommon extractObject ()=0
 Extracts associated object or NULL if no association is established.
 

Additional Inherited Members

- Protected Member Functions inherited from Glympse::ICommon
virtual ~ICommon ()
 Destructor is protected to deny explicit object deallocation. More...
 

Member Function Documentation

virtual bool Glympse::ILinkedAccountsManager::canSend ( const GInvite invite)
pure virtual

Determines if account required for sending the invite is linked to user's profile.

Parameters
inviteInvite object to be analyzed.
Returns
true if platform is capable of sending the invite.
virtual GEventSink Glympse::ILinkedAccountsManager::confirm ( const GString type,
const GPrimitive profile 
)
pure virtual

Sends confirmation code required to link account of GC::LINKED_ACCOUNT_TYPE_PHONE of GC::LINKED_ACCOUNT_TYPE_EMAIL type.

Upon success, a GE::CONFIRMATION_CODE_SENT event is fired on LISTENER_CONFIRMATION_CODE. Upon failure, a GE::CONFIRMATION_CODE_FAILED event is fired on LISTENER_CONFIRMATION_CODE.

Parameters
typeThe type of the account to be linked.
profileGPrimitive of CC::PRIMITIVE_TYPE_OBJECT type containing the profile name and associated metadata. Use GlympseFactory static profile factory methods for convenience.
Returns
Event sink of GC::LISTENER_CONFIRMATION_CODE type.
virtual GLinkedAccount Glympse::ILinkedAccountsManager::getAccount ( const GString type)
pure virtual

Retrieves the linked account for the specified type.

Parameters
typeThe type of the account to be retrieved.
Returns
The linked account, or NULL if none exists.
virtual GPrimitive Glympse::ILinkedAccountsManager::getAccountProperty ( const GString type,
const GString name 
)
pure virtual

Retrieves a property previously set for the specified account type by name.

Parameters
typeThe type of the account to be interrogated.
nameThe name of the property to retrieve, qualified by the type.
Returns
The value of the property requested in the form of a GPrimitive or NULL if the type or property does not exist, or if an error occurred.
virtual GArray<GLinkedAccount>::ptr Glympse::ILinkedAccountsManager::getAccounts ( )
pure virtual

Retrieves the list of all linked accounts.

Returns
The list of linked accounts.
virtual int32 Glympse::ILinkedAccountsManager::getCount ( bool  loginEnabled)
pure virtual

Retrieves the number of linked accounts satisfying the specified criteria.

Parameters
loginEnabledOnly consider accounts enabled for login.
Returns
The number of linked accounts matching the specified criteria.
virtual bool Glympse::ILinkedAccountsManager::isSynced ( )
pure virtual

Determines whether or not the linked accounts manager has completed its initial sync with the server.

Returns
true, if the initial sync is complete, false otherwise.
virtual GLinkedAccount Glympse::ILinkedAccountsManager::link ( const GString type,
const GPrimitive profile 
)
pure virtual

Links an account of the specified type using the account profile information provided.

Upon success, a GE::ACCOUNT_LINK_SUCCEEDED event is fired on LISTENER_LINKED_ACCOUNTS. Upon failure, a GE::ACCOUNT_LINK_FAILED event is fired on LISTENER_LINKED_ACCOUNTS.

Parameters
typeThe type of the account to be linked.
profileGPrimitive of CC::PRIMITIVE_TYPE_OBJECT type containing the profile name and associated metadata. Use GlympseFactory static profile factory methods for convenience.
Returns
A linked account object, or NULL if the request was invalid.
virtual GLinkedAccount Glympse::ILinkedAccountsManager::link ( const GString type,
const GPrimitive profile,
bool  force 
)
pure virtual

Links an account of the specified type using the account profile information provided, forcefully if necessary.

Upon success, a GE::ACCOUNT_LINK_SUCCEEDED event is fired on LISTENER_LINKED_ACCOUNTS. Upon failure, a GE::ACCOUNT_LINK_FAILED event is fired on LISTENER_LINKED_ACCOUNTS.

Parameters
typeThe type of the account to be linked.
profileGPrimitive of CC::PRIMITIVE_TYPE_OBJECT type containing the profile name and associated metadata. Use GlympseFactory static profile factory methods for convenience.
forceIf true, and the profile is valid, forces the link, transferring the account from another user account if necessary.
Returns
A linked account object, or NULL if the request was invalid.
virtual GLinkedAccount Glympse::ILinkedAccountsManager::refresh ( const GString type,
const GPrimitive profile 
)
pure virtual

Refreshes an account of the specified type using the account profile information provided.

Upon success, a GE::ACCOUNT_REFRESH_SUCCEEDED event is fired on LISTENER_LINKED_ACCOUNTS. Upon failure, a GE::ACCOUNT_REFRESH_FAILED event is fired on LISTENER_LINKED_ACCOUNTS.

Parameters
typeThe type of the account to be refreshed.
profileGPrimitive of CC::PRIMITIVE_TYPE_OBJECT type containing the profile name and associated metadata. Use GlympseFactory static profile factory methods for convenience.
Returns
A linked account object, or NULL if the request was invalid.
virtual bool Glympse::ILinkedAccountsManager::refresh ( )
pure virtual

Refreshes the entire list of linked accounts and their status ("freshness").

Upon success, a GE::ACCOUNT_LIST_REFRESH_SUCCEEDED event is fired on LISTENER_LINKED_ACCOUNTS. Upon failure, a GE::ACCOUNT_LIST_REFRESH_FAILED event is fired on LISTENER_LINKED_ACCOUNTS.

Returns
true, if the request to refresh the account list was initiated, false otherwise.
virtual void Glympse::ILinkedAccountsManager::setAccountProperty ( const GString type,
const GString name,
const GPrimitive value 
)
pure virtual

Sets a property for the specified account type by name.

Parameters
typeThe type of the account to be updated.
nameThe name of the property to update, qualified by the type.
valueThe value to set for the property.
virtual GLinkedAccount Glympse::ILinkedAccountsManager::unlink ( const GString type)
pure virtual

Unlinks the account of the specified type.

Upon success, a GE::ACCOUNT_UNLINK_SUCCEEDED event is fired on LISTENER_LINKED_ACCOUNTS. Upon failure, a GE::ACCOUNT_UNLINK_FAILED event is fired on LISTENER_LINKED_ACCOUNTS.

Parameters
typeThe type of the account to be unlinked.
Returns
A linked account object, or NULL if the request was invalid.

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