phonebookui/Phonebook2/inc/MPbk2FetchDlgObserver.h
changeset 0 e686773b3f54
equal deleted inserted replaced
-1:000000000000 0:e686773b3f54
       
     1 /*
       
     2 * Copyright (c) 2005-2007 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  Phonebook 2 fetch dialog observer interface.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef MPBK2FETCHDLGOBSERVER_H
       
    20 #define MPBK2FETCHDLGOBSERVER_H
       
    21 
       
    22 // INCLUDES
       
    23 #include <e32def.h>
       
    24 
       
    25 // FORWARD DECLARATIONS
       
    26 class MVPbkContactLink;
       
    27 class MVPbkContactLinkArray;
       
    28 
       
    29 // CLASS DECLARATION
       
    30 
       
    31 /**
       
    32  * Phonebook 2 fetch dialog observer interface.
       
    33  */
       
    34 class MPbk2FetchDlgObserver
       
    35     {
       
    36     public: // Interface
       
    37 
       
    38         /**
       
    39          * Fetch accept selection values.
       
    40          */
       
    41         enum TPbk2FetchAcceptSelection
       
    42             {
       
    43             /// Fetch selection is accepted
       
    44             EFetchYes = 0,
       
    45             /// Fetch selection is rejected
       
    46             EFetchNo,
       
    47             /// Fetch selection is delayed
       
    48             EFetchDelayed
       
    49             };
       
    50 
       
    51         /**
       
    52          * Called by a fetch dialog when user makes a selection.
       
    53          *
       
    54          * @param aNumMarkedEntries Number of selected entries.
       
    55          * @param aLastSelection    Lastly selected contact.
       
    56          * @return  Fetch accept selection value.
       
    57          */
       
    58         virtual TPbk2FetchAcceptSelection AcceptFetchSelectionL(
       
    59                 TInt aNumMarkedEntries,
       
    60                 MVPbkContactLink& aLastSelection ) = 0;
       
    61 
       
    62         /**
       
    63          * Called when the fetch dialog is closed.
       
    64          *
       
    65          * @param aMarkedEntries    Link array of marked contacts.
       
    66          *                          Do not take ownership of the links!
       
    67          */
       
    68         virtual void FetchCompletedL(
       
    69                 MVPbkContactLinkArray* aMarkedEntries ) = 0;
       
    70 
       
    71         /**
       
    72          * Called when fetch is canceled.
       
    73          */
       
    74         virtual void FetchCanceled() = 0;
       
    75 
       
    76         /**
       
    77          * Called when fetch is aborted.
       
    78          */
       
    79         virtual void FetchAborted() = 0;
       
    80 
       
    81         /**
       
    82          * Queries is it ok to exit.
       
    83          *
       
    84          * @return  ETrue if it is ok to exit
       
    85          *          EFalse otherwise.
       
    86          */
       
    87         virtual TBool FetchOkToExit() = 0;
       
    88 
       
    89     protected: // Protected functions
       
    90 
       
    91         /**
       
    92          * Protected destructor. Observers are not meant to be
       
    93          * destructed via this interface.
       
    94          */
       
    95         ~MPbk2FetchDlgObserver()
       
    96                 {}
       
    97     };
       
    98 
       
    99 #endif // MPBK2FETCHDLGOBSERVER_H
       
   100 
       
   101 // End of File