ipsservices/ipssosplugin/inc/ipsplgeventhandler.h
branchRCL_3
changeset 8 e1b6206813b4
parent 0 8466d47a6819
child 24 d189ee25cf9d
equal deleted inserted replaced
4:e7aa27f58ae1 8:e1b6206813b4
   203      * @param aAccount FS mailbox id
   203      * @param aAccount FS mailbox id
   204      */
   204      */
   205     void SignalMailboxOfflineStateL( const TFSMailMsgId& aAccount );
   205     void SignalMailboxOfflineStateL( const TFSMailMsgId& aAccount );
   206 
   206 
   207     /**
   207     /**
   208      * Send user password query request to fs email ui
   208      * Send user password query request to fs email ui.
       
   209      * Request is handled by emailserver.
       
   210      * Only one query at a time is allowed - restriction of CFSMailMessageQueryHandler
       
   211      * Operation callback is registered in handler and will receive notification
       
   212      * on query password finished.
       
   213      * 
   209      * @param aMbox entry id of mailbox service
   214      * @param aMbox entry id of mailbox service
   210      * @param aCallback callback interface to connection operation, defaut NULL
   215      * @param aCallback callback interface to connection operation, defaut NULL
   211      */
   216      * @param aIncoming incoming or outgoing password query
   212     void QueryUsrPassL( TMsvId aMbox, MIpsPlgConnectOpCallback* aCallback=NULL );
   217      * @return ETrue query invoked, wait for notification
       
   218      *         EFalse another query is in progress
       
   219      */
       
   220     TBool QueryUsrPassL(
       
   221         TMsvId aMbox,
       
   222         MIpsPlgConnectOpCallback* aCallback=NULL,
       
   223         TBool aIncoming=ETrue );
       
   224 
       
   225     /**
       
   226      * Query in progress is for incoming or outgoing mail.
       
   227      */
       
   228     TBool IncomingPass() const;
   213 
   229 
   214     /**
   230     /**
   215      * Send user password (=credentials) set signal to all plugin
   231      * Send user password (=credentials) set signal to all plugin
   216      * instances via p&s (property) mechanism
   232      * instances via p&s (property) mechanism
   217      * @param aMailboxId entry id of mailbox
   233      * @param aMailboxId entry id of mailbox
   218      * @param aCancelled indicates is user cancelled password dialog
   234      * @param aCancelled indicates is user cancelled password dialog
   219      */
   235      */
   220     void SignalCredientialsSetL( TInt aMailboxId, TBool aCancelled );
   236     void SignalCredientialsSetL( TInt aMailboxId, TBool aCancelled );
   221 
   237 
   222 private:
   238 private:
       
   239 
       
   240     /** States of Query user password operation */
       
   241     enum TQueryUsrPassState
       
   242         {
       
   243         EReady,                 // ready for action
       
   244         EBusy,                  // request in progress (invoker eventhandler`s state)
       
   245         ENotificationRequest,   // user notification request (emailserver eventhandler`s state)
       
   246         EPasswordRequest,       // password request (emailserver eventhandler`s state)
       
   247         ERequestResponding      // response for request received, handling in progress (invoker eventhandler`s state)
       
   248         };
   223 
   249 
   224     /**
   250     /**
   225     * Checks the source type of event and also
   251     * Checks the source type of event and also
   226     * checks is the event from IPS type  ( imap/pop ) entry
   252     * checks is the event from IPS type  ( imap/pop ) entry
   227     *
   253     *
   441     TPckgBuf<TIpsPlgPropertyEvent>          iPropertyBuf;
   467     TPckgBuf<TIpsPlgPropertyEvent>          iPropertyBuf;
   442 
   468 
   443     // base plugin id
   469     // base plugin id
   444     TUint                                   iPluginId;
   470     TUint                                   iPluginId;
   445 
   471 
   446     //not owned
       
   447     MIpsPlgConnectOpCallback*               iConnOpCallback;
       
   448 
       
   449     RArray<TMsvId>                          iImapFolderIds;
   472     RArray<TMsvId>                          iImapFolderIds;
   450 
   473 
       
   474     // state of the query user password operation
       
   475     // diffrent states are for query invoker and query handler (emailserver)
       
   476     TQueryUsrPassState                      iQueryPassState;
       
   477     // array of operations which wait for query response
       
   478     // or possibilty to perform a query
       
   479     RPointerArray<MIpsPlgConnectOpCallback> iConnOpCallbacks;
       
   480     // query user password for incoming or outgoing
       
   481     TBool                                   iIncomingPass;
   451     };
   482     };
   452 
   483 
   453 
   484 
   454 #endif // IPSPLGEVENTHANDLER_H
   485 #endif // IPSPLGEVENTHANDLER_H
   455 
   486