serviceproviders/sapi_sensor/inc/sensorservicehandler.h
changeset 5 989d2f495d90
child 23 50974a8b132e
equal deleted inserted replaced
1:a36b1e19a461 5:989d2f495d90
       
     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 the License "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:  Loads the sensor service
       
    15 *
       
    16 */
       
    17 
       
    18 #ifndef C_CSENSORSERVICEHANDLER_H
       
    19 #define C_CSENSORSERVICEHANDLER_H
       
    20 
       
    21 #include <Liwserviceifbase.h>
       
    22 
       
    23 /**
       
    24  * CsensorProvider - inherits the CLiwServiceIfBase to Load the sensor
       
    25  * service class.
       
    26  */
       
    27 class CSensorProvider : public CLiwServiceIfBase
       
    28     {
       
    29     public:
       
    30         /**
       
    31          * Two-phased constructor.
       
    32          * @return CSensorProvider*
       
    33          */
       
    34         static CSensorProvider* NewL();
       
    35         /**
       
    36          * Destructor
       
    37          */
       
    38         ~CSensorProvider();
       
    39 
       
    40     private:
       
    41         /**
       
    42          * Default constructor.
       
    43          */
       
    44         CSensorProvider();
       
    45 
       
    46     public:
       
    47        /**
       
    48         * Called by the Liw framework to initialise provider with necessary information
       
    49         * from the Service Handler. This method is called when the consumer makes
       
    50         * the attach operation.
       
    51         *
       
    52         * @param aFrameworkCallback Framework provided callback for provider to send
       
    53         *                           events to framework.
       
    54         * @param aInterest List of criteria items which invoked the provider.
       
    55         */
       
    56         virtual void InitialiseL( MLiwNotifyCallback& aFrameworkCallback,
       
    57                                   const RCriteriaArray& aInterest );
       
    58        /**
       
    59         * Executes generic service commands included in criteria.
       
    60         *
       
    61         * @param aCmdId Command to be executed.
       
    62         * @param aInParamList Input parameters, can be an empty list.
       
    63         * @param aOutParamList Output parameters, can be an empty list.
       
    64         * @param aCmdOptions Options for the command, see KLiwOpt* in LiwCommon.hrh.
       
    65         * @param aCallback Callback for asynchronous command handling, parameter checking, etc.
       
    66         * @leave KErrArgument Callback is missing when required.
       
    67         * @leave KErrNotSupported No provider supports service.
       
    68         */
       
    69         virtual void HandleServiceCmdL( const TInt& aCmdId,
       
    70                                         const CLiwGenericParamList& aInParamList,
       
    71                                         CLiwGenericParamList& aOutParamList,
       
    72                                         TUint aCmdOptions = 0,
       
    73                                         const MLiwNotifyCallback* aCallback = NULL );
       
    74     };
       
    75 #endif // C_CSENSORSERVICEHANDLER_H