imsrv_plat/ximp_core_management_api/inc/ximpclient.inl
changeset 0 e6b17d312c8b
equal deleted inserted replaced
-1:000000000000 0:e6b17d312c8b
       
     1 /*
       
     2 * Copyright (c) 2006, 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:  Root interface used by Presence Framework clients.
       
    15 *
       
    16 */
       
    17 
       
    18 #include <ecom/ecom.h>
       
    19 
       
    20 
       
    21 // -----------------------------------------------------------------------------
       
    22 // MXIMPClient::NewClientL() implementation
       
    23 // Factory method to instantiate the platform default
       
    24 // MXIMPClient implementation through the ECom framework.
       
    25 // -----------------------------------------------------------------------------
       
    26 //
       
    27 inline MXIMPClient* MXIMPClient::NewClientL()
       
    28     {
       
    29     _LIT8( KXimpFwDefaultData, XIMP_ECOM_DEFAULT_DATA_CLIENT_INTERFACE );
       
    30 
       
    31     TEComResolverParams resolvingParams;
       
    32     resolvingParams.SetDataType( KXimpFwDefaultData );
       
    33     resolvingParams.SetWildcardMatch( ETrue );
       
    34 
       
    35     TAny* imp = REComSession::CreateImplementationL( TUid::Uid( MXIMPClient::KInterfaceId ),
       
    36                                                      _FOFF( MXIMPClient, iEcomDtorID ),
       
    37                                                      resolvingParams );
       
    38 
       
    39     return reinterpret_cast< MXIMPClient* >( imp );
       
    40     }
       
    41 
       
    42 
       
    43 // -----------------------------------------------------------------------------
       
    44 // MXIMPClient::MXIMPClient() implementation
       
    45 // Zero initializes the iEcomDtorID member.
       
    46 // -----------------------------------------------------------------------------
       
    47 //
       
    48 inline MXIMPClient::MXIMPClient()
       
    49     {
       
    50     iEcomDtorID = TUid::Null();
       
    51     }
       
    52 
       
    53 
       
    54 // -----------------------------------------------------------------------------
       
    55 // MXIMPClient::~MXIMPClient()
       
    56 // Destructor notifies the ECom from implementation destruction.
       
    57 // -----------------------------------------------------------------------------
       
    58 //
       
    59 inline MXIMPClient::~MXIMPClient()
       
    60     {
       
    61     REComSession::DestroyedImplementation( iEcomDtorID );
       
    62     }
       
    63 
       
    64