contextframework/cfw/src/cfoperationpluginservices/cfoperationplugin.cpp
changeset 0 2e3d3ce01487
equal deleted inserted replaced
-1:000000000000 0:2e3d3ce01487
       
     1 /*
       
     2 * Copyright (c) 2006-2006 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:  CCFOperationPlugIn implementation.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 #include <ecom/ecom.h>
       
    21 
       
    22 #include "cfoperationplugin.h"
       
    23 #include "cfoperationservices.h"
       
    24 
       
    25 // CONSTANTS
       
    26 
       
    27 //#ifdef _DEBUG
       
    28 //_LIT( KPanicCat, "CfOperationPlugIn" );
       
    29 //
       
    30 //enum TPanicReason
       
    31 //    {
       
    32 //    ENoPanic,  // ENone - ENone caused a trouble when including w32std.h
       
    33 //    EInvalidInitParam,
       
    34 //    EInvalidContextManager,
       
    35 //    EInvalidFs
       
    36 //    };
       
    37 //    
       
    38 //LOCAL_C void Panic( TPanicReason aReason )
       
    39 //    {
       
    40 //    User::Panic( KPanicCat, aReason );
       
    41 //    }
       
    42 //#endif
       
    43 
       
    44 // MEMBER FUNCTIONS
       
    45 
       
    46 EXPORT_C CCFOperationPlugIn* CCFOperationPlugIn::NewL(
       
    47     const TUid& aImplementationUid,
       
    48     TOperationPluginInitParams* aParams )
       
    49     {
       
    50     CCFOperationPlugIn* self =
       
    51         CCFOperationPlugIn::NewLC( aImplementationUid, aParams );
       
    52     CleanupStack::Pop( self );
       
    53     
       
    54     return self;
       
    55     }
       
    56 
       
    57 EXPORT_C CCFOperationPlugIn* CCFOperationPlugIn::NewLC(
       
    58     const TUid& aImplementationUid,
       
    59     TOperationPluginInitParams* aParams )
       
    60     {
       
    61     //__ASSERT_DEBUG( aParams, Panic( EInvalidInitParam ) );
       
    62 
       
    63     CCFOperationPlugIn* self =
       
    64         reinterpret_cast<CCFOperationPlugIn*>(
       
    65             REComSession::CreateImplementationL(
       
    66                 aImplementationUid,
       
    67                 _FOFF( CCFOperationPlugIn, iDtorKey ),
       
    68                 aParams ) );
       
    69 
       
    70     CleanupStack::PushL( self );
       
    71     
       
    72     return self;
       
    73     }
       
    74 
       
    75 EXPORT_C CCFOperationPlugIn::~CCFOperationPlugIn()
       
    76     {
       
    77     #ifndef _DEBUG
       
    78     REComSession::DestroyedImplementation( iDtorKey );
       
    79     #else
       
    80     if( iDtorKey != KNullUid )
       
    81         {
       
    82         REComSession::DestroyedImplementation( iDtorKey );
       
    83         }
       
    84     #endif
       
    85     }
       
    86 
       
    87 EXPORT_C CCFOperationPlugIn::CCFOperationPlugIn(
       
    88     TOperationPluginInitParams* /*aParams*/ )
       
    89     {
       
    90     }
       
    91     
       
    92 //-----------------------------------------------------------------------------
       
    93 // CCFOperationPlugIn::Extension
       
    94 //-----------------------------------------------------------------------------
       
    95 //
       
    96 EXPORT_C TAny* CCFOperationPlugIn::Extension(
       
    97     const TUid& /*aExtensionUid*/ ) const
       
    98     {
       
    99     return NULL;
       
   100     }
       
   101 
       
   102 // End of File