emailcontacts/remotecontactlookup/engine/inc/cpbkxrclprotocolenvimpl.h
branchRCL_3
changeset 12 4ce476e64c59
parent 11 0396474f30f5
child 13 8592a65ad3fb
equal deleted inserted replaced
11:0396474f30f5 12:4ce476e64c59
     1 /*
       
     2 * Copyright (c) 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:  Definition of the class CPbkxRclProtocolEnvImpl.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef CPBKXRCLPROTOCOLENVIMPL_H
       
    20 #define CPBKXRCLPROTOCOLENVIMPL_H
       
    21 
       
    22 #include "mpbkxremotecontactlookupprotocolenv.h"
       
    23 
       
    24 /**
       
    25 * Factory class for creating data objects.
       
    26 *
       
    27 * @lib pbkxengine.lib
       
    28 * @since S60 3.1
       
    29 */
       
    30 class CPbkxRclProtocolEnvImpl : 
       
    31     public CBase,
       
    32     public MPbkxRemoteContactLookupProtocolEnv
       
    33     {
       
    34 public: // constructors and destructor
       
    35 
       
    36     /**
       
    37     * Two-phased constructor.
       
    38     *
       
    39     * @return Created object.
       
    40     */
       
    41     static CPbkxRclProtocolEnvImpl* NewL();
       
    42     
       
    43     /**
       
    44     * Two-phased constructor.
       
    45     *
       
    46     * Leaves pointer to the created object on cleanupstack.
       
    47     *
       
    48     * @return Created object.
       
    49     */
       
    50     static CPbkxRclProtocolEnvImpl* NewLC();
       
    51 
       
    52     /**
       
    53     * Destructor.
       
    54     */
       
    55     virtual ~CPbkxRclProtocolEnvImpl();
       
    56 
       
    57 public: // functions from MPbkxRemoteContactLookupProtocolEnv
       
    58 
       
    59     /**
       
    60     * Creates a new protocol account instance.
       
    61     *
       
    62     * Ownership is transferred to caller.
       
    63     *
       
    64     * @param aId protocol account ID
       
    65     * @param aName protocol account name
       
    66     * @return Created account.
       
    67     */
       
    68     virtual CPbkxRemoteContactLookupProtocolAccount* NewProtocolAccountL( 
       
    69         TPbkxRemoteContactLookupProtocolAccountId aId, 
       
    70         const TDesC& aName );
       
    71         
       
    72     /**
       
    73     * Creates a new protocol result instance.
       
    74     *
       
    75     * Ownership is transferred to caller.
       
    76     *
       
    77     * @param aIsComplete is search result complete?
       
    78     * @param aContactItem contact item, owernship is transfered to this object
       
    79     * @param aExtraProtocolData extra protocol data for two-phase search
       
    80     * @return Created protocol result.
       
    81     */
       
    82     virtual CPbkxRemoteContactLookupProtocolResult* NewProtocolResultL(
       
    83         TBool aIsComplete, 
       
    84         CContactItem& aContactItem, 
       
    85         const TDesC& aExtraProtocolData );
       
    86 
       
    87 private: // constructors
       
    88 
       
    89     /**
       
    90     * Constructor.
       
    91     */
       
    92     CPbkxRclProtocolEnvImpl();
       
    93 
       
    94     /**
       
    95     * Second-phase constructor.
       
    96     */
       
    97     void ConstructL();
       
    98 
       
    99     };
       
   100 
       
   101 #endif