phonebookui/Phonebook2/ccapplication/ccacontactorservice/src/ccacontactor.cpp
branchRCL_3
changeset 20 f4a778e096c2
equal deleted inserted replaced
19:5b6f26637ad3 20:f4a778e096c2
       
     1 /*
       
     2 * Copyright (c) 2008 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:  Implementation of the ccacontactor
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 // INCLUDE FILES
       
    20 #include "ccacontactorheaders.h"
       
    21 
       
    22 // ============================ MEMBER FUNCTIONS ===============================
       
    23 
       
    24 // -----------------------------------------------------------------------------
       
    25 // CCAContactor::ExecuteServiceL()
       
    26 // -----------------------------------------------------------------------------
       
    27 //
       
    28 void CCAContactor::ExecuteServiceL(VPbkFieldTypeSelectorFactory::TVPbkContactActionTypeSelector aCommMethod, 
       
    29 		const TDesC& aParam, const TDesC& aName, const TDesC8& aContactLinkArray, TUint32 aServiceId)
       
    30     {
       
    31     CCCAContactorOperation* operation = 0;
       
    32     
       
    33     switch (aCommMethod)
       
    34         {
       
    35         case VPbkFieldTypeSelectorFactory::EVoiceCallSelector:              
       
    36             operation = CCCAContactorCallOperation::NewL(aParam, aContactLinkArray);
       
    37             break;
       
    38             
       
    39         case VPbkFieldTypeSelectorFactory::EVideoCallSelector:
       
    40             operation = CCCAContactorVideocallOperation::NewL(aParam, aContactLinkArray);
       
    41             break;
       
    42         case VPbkFieldTypeSelectorFactory::EUniEditorSelector:
       
    43             operation = CCCAContactorUniEditorOperation::NewL(aParam, aName);
       
    44             break;
       
    45         case VPbkFieldTypeSelectorFactory::EEmailEditorSelector:
       
    46             operation = CCCAContactorEmailOperation::NewL(aParam, aName);
       
    47             break;
       
    48         case VPbkFieldTypeSelectorFactory::EURLSelector:
       
    49             operation = CCCAContactorURLOperation::NewL(aParam);
       
    50             break;
       
    51         case VPbkFieldTypeSelectorFactory::EVOIPCallSelector:
       
    52             operation = CCCAContactorVOIPOperation::NewL(aParam, aServiceId, aContactLinkArray);
       
    53             break;
       
    54         case VPbkFieldTypeSelectorFactory::EInstantMessagingSelector:
       
    55             MCmsContactorImPluginParameter* cmsParameter;
       
    56             cmsParameter = CCmsContactorImPluginParameter::NewL(
       
    57                     aName, aContactLinkArray);	   
       
    58             operation = CCCAContactorIMOperation::NewL(aParam,cmsParameter);
       
    59             break;
       
    60         
       
    61         }
       
    62     if (operation)
       
    63         {
       
    64         operation->ExecuteLD();
       
    65         operation = NULL;
       
    66         }
       
    67     }
       
    68 // End of File
       
    69