omads/omadsappui/AspSyncUtil/src/AspSyncUtilApi.cpp
changeset 0 dab8a81a92de
equal deleted inserted replaced
-1:000000000000 0:dab8a81a92de
       
     1 /*
       
     2 * Copyright (c) 2002-2005 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:  Contains functions that are exported from AspSyncUtil for
       
    15 *                performing data synchronization.
       
    16 *
       
    17 */
       
    18 
       
    19 
       
    20 
       
    21 // INCLUDE FILES
       
    22 
       
    23 #include "AspSyncUtilApi.h"
       
    24 #include "AspSyncUtil.h"
       
    25 #include "AspDebug.h"
       
    26 
       
    27 
       
    28 
       
    29 
       
    30 // ============================ MEMBER FUNCTIONS ===============================
       
    31 
       
    32 
       
    33 
       
    34 // -----------------------------------------------------------------------------
       
    35 // CSyncUtilApi::NewL
       
    36 //
       
    37 // Two-phased constructor.
       
    38 // -----------------------------------------------------------------------------
       
    39 //
       
    40 EXPORT_C CSyncUtilApi* CSyncUtilApi::NewL()
       
    41     {
       
    42     FLOG( _L("CSyncUtilApi::NewL START") );
       
    43     
       
    44     CSyncUtilApi* self = new (ELeave) CSyncUtilApi();
       
    45     CleanupStack::PushL(self);
       
    46 	self->ConstructL();
       
    47     CleanupStack::Pop(self);
       
    48 
       
    49 	FLOG( _L("CSyncUtilApi::NewL END") );
       
    50 	
       
    51 	return self;
       
    52     }
       
    53 
       
    54 
       
    55 // -----------------------------------------------------------------------------
       
    56 // Destructor
       
    57 //
       
    58 // -----------------------------------------------------------------------------
       
    59 //
       
    60 CSyncUtilApi::~CSyncUtilApi()
       
    61     {
       
    62     FLOG( _L("CSyncUtilApi::~CSyncUtilApi START") );
       
    63     
       
    64 	delete iSyncUtil;
       
    65 	
       
    66 	FLOG( _L("CSyncUtilApi::~CSyncUtilApi END") );
       
    67     }
       
    68 
       
    69 
       
    70 // -----------------------------------------------------------------------------
       
    71 // CSyncUtilApi::ConstructL
       
    72 //
       
    73 // Symbian 2nd phase constructor can leave.
       
    74 // -----------------------------------------------------------------------------
       
    75 //
       
    76 void CSyncUtilApi::ConstructL()
       
    77     {
       
    78 	iSyncUtil = CAspSyncUtil::NewL();
       
    79     }
       
    80 
       
    81 
       
    82 // -----------------------------------------------------------------------------
       
    83 // CSyncUtilApi::CSyncUtilApi
       
    84 //
       
    85 // C++ default constructor can NOT contain any code, that
       
    86 // might leave.
       
    87 // -----------------------------------------------------------------------------
       
    88 //
       
    89 CSyncUtilApi::CSyncUtilApi()
       
    90     {
       
    91     }
       
    92 
       
    93 
       
    94 // -----------------------------------------------------------------------------
       
    95 // CSyncUtilApi::SynchronizeL
       
    96 //
       
    97 // -----------------------------------------------------------------------------
       
    98 //
       
    99 EXPORT_C void CSyncUtilApi::SynchronizeL(TInt aApplicationId, TInt aJobId, TInt aInfo1, TDes& aInfo2)
       
   100     {
       
   101 	iSyncUtil->SynchronizeL(aApplicationId, aJobId, aInfo1, aInfo2); 
       
   102     }
       
   103 
       
   104 
       
   105 // -----------------------------------------------------------------------------
       
   106 // CSyncUtilApi::ShowSettingsL
       
   107 //
       
   108 // -----------------------------------------------------------------------------
       
   109 //
       
   110 EXPORT_C void CSyncUtilApi::ShowSettingsL(TInt aApplicationId, TInt aInfo1, TDes& aInfo2)
       
   111     {
       
   112     iSyncUtil->ShowSettingsL(aApplicationId, aInfo1, aInfo2);
       
   113     }
       
   114 
       
   115 
       
   116 // -----------------------------------------------------------------------------
       
   117 // CAspSyncUtil::SynchronizeL
       
   118 //
       
   119 // -----------------------------------------------------------------------------
       
   120 //
       
   121 EXPORT_C void CSyncUtilApi::SynchronizeL(RFile& aScheduleTaskFile)
       
   122 	{
       
   123 	iSyncUtil->SynchronizeL(aScheduleTaskFile);
       
   124 	}
       
   125 
       
   126 
       
   127 
       
   128 // End of file