mtpfws/mtpfw/dataproviders/proxydp/inc/cmtpproxydp.h
changeset 0 d0791faffa3f
child 47 63cf70d3ecd8
equal deleted inserted replaced
-1:000000000000 0:d0791faffa3f
       
     1 // Copyright (c) 2006-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 CMTPPROXYDP_H
       
    22 #define CMTPPROXYDP_H
       
    23 
       
    24 #include <mtp/cmtpdataproviderplugin.h>
       
    25 #include "rmtpdpsingletons.h"
       
    26 #include "rmtpproxydpsingletons.h"
       
    27 class MMTPRequestProcessor;
       
    28 
       
    29 /** 
       
    30 Implements the proxy data provider.
       
    31 @internalComponent
       
    32   
       
    33 */
       
    34 class CMTPProxyDataProvider : public CMTPDataProviderPlugin
       
    35     {
       
    36 public:
       
    37 
       
    38     static TAny* NewL(TAny* aParams);
       
    39     ~CMTPProxyDataProvider();
       
    40 	
       
    41 private: // From CMTPDataProviderPlugin
       
    42 
       
    43 	void Cancel();
       
    44     void ProcessEventL(const TMTPTypeEvent& aEvent, MMTPConnection& aConnection);
       
    45     void ProcessNotificationL(TMTPNotification aNotification, const TAny* aParams);
       
    46     void ProcessRequestPhaseL(TMTPTransactionPhase aPhase, const TMTPTypeRequest& aRequest, MMTPConnection& aConnection);
       
    47     void StartObjectEnumerationL(TUint32 aStorageId, TBool aPersistentFullEnumeration);
       
    48     void StartStorageEnumerationL();
       
    49     void Supported(TMTPSupportCategory aCategory, RArray<TUint>& aArray) const;
       
    50     TAny* GetExtendedInterface(TUid aInterfaceUid);
       
    51  	void SupportedL(TMTPSupportCategory aCategory, CDesCArray& aStrings) const;
       
    52 	void ConstructL();
       
    53 
       
    54 private:
       
    55 
       
    56     CMTPProxyDataProvider(TAny* aParams);
       
    57 	
       
    58 	TInt LocateRequestProcessorL(const TMTPTypeRequest& aRequest, MMTPConnection& aConnection);
       
    59 	TInt LocateRequestProcessorL(const TMTPTypeEvent& aEvent, MMTPConnection& aConnection);	 
       
    60     void SessionClosedL(const TMTPNotificationParamsSessionChange& aSession);
       
    61     void SessionOpenedL(const TMTPNotificationParamsSessionChange& aSession);
       
    62 private:
       
    63 
       
    64 	RPointerArray<MMTPRequestProcessor>		iActiveProcessors;	//keep track of the active processors (might from different sessions)
       
    65   
       
    66     /* DP utility singletons
       
    67     */
       
    68     RMTPDpSingletons					iDpSingletons;
       
    69     
       
    70     TInt									iActiveProcessor;
       
    71     TBool									iActiveProcessorRemoved;
       
    72     RMTPProxyDpSingletons   iSingletons;
       
    73 
       
    74  	/**
       
    75     FLOGGER debug trace member variable.
       
    76     */
       
    77     __FLOG_DECLARATION_MEMBER_MUTABLE;
       
    78 
       
    79     };
       
    80 #endif // CMTPPROXYDP_H