datasourceadaptation/gpsdatasourceadaptation/common/inc/cpositionerq.h
changeset 0 9cfd9a3ee49c
equal deleted inserted replaced
-1:000000000000 0:9cfd9a3ee49c
       
     1 // Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 //
       
    15 
       
    16 /**
       
    17  @file
       
    18  @InternalComponent
       
    19 */
       
    20 
       
    21 #ifndef CPOSITIONERQ_H
       
    22 #define CPOSITIONERQ_H
       
    23 
       
    24 #include <e32base.h>
       
    25 
       
    26 class MPositioner;
       
    27 class CRequestHandler;
       
    28 class CResponseHandler;
       
    29 class CModuleStatusHandler;
       
    30 class CPositionerEnvironment;
       
    31 class TPositionerCall;
       
    32 class TRetBoolPositionerCall;
       
    33 class TRetTUintPositionerCall;
       
    34 
       
    35 /**
       
    36 * CPositionerQ controls access to the queue of MPositioner objects
       
    37 */
       
    38 class CPositionerQ : public CBase
       
    39     {
       
    40     public:
       
    41         static CPositionerQ* NewL();
       
    42         ~CPositionerQ();
       
    43         
       
    44         void RegisterPSYL(MPositioner* aPSY);
       
    45         void UnregisterPSY(MPositioner* aPSY);
       
    46         void PositionerIterator(TPositionerCall& aCall);
       
    47 		TUint IterGreatest(TRetTUintPositionerCall& aCall);
       
    48 		TBool IterETrue(TRetBoolPositionerCall& aCall);
       
    49         TUint Count();
       
    50         
       
    51 		TInt Index(MPositioner& aPSY);
       
    52         MPositioner& Positioner(TUint aIndex);
       
    53 
       
    54 		/**
       
    55 		* Request panic code
       
    56 		*/
       
    57 		enum TRequestQPanic
       
    58 			{
       
    59 			ERequestQIndexToLarge = 0,
       
    60 			ERequestQItemNotFound = 1,
       
    61 			};
       
    62 		
       
    63 	private:
       
    64         CPositionerQ();
       
    65         
       
    66 		TInt FindPsy(MPositioner* aPSY);
       
    67 
       
    68     private:
       
    69         RArray<MPositioner*> iPsyArray;
       
    70     };
       
    71 
       
    72 #endif // CPOSITIONERQ_H
       
    73 
       
    74 // End of File