|
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 CMTPDELETEOBJECT_H |
|
22 #define CMTPDELETEOBJECT_H |
|
23 |
|
24 #include "cmtprequestprocessor.h" |
|
25 #include "mmtptransactionproxy.h" |
|
26 #include "rmtpframework.h" |
|
27 |
|
28 class CMTPDataProvider; |
|
29 class MMTPRequestProcessor; |
|
30 class CMTPObjectBrowser; |
|
31 class CMTPTypeArray; |
|
32 |
|
33 /** |
|
34 Implements the proxy data provider DeleteObject request processor. |
|
35 @internalComponent |
|
36 |
|
37 */ |
|
38 class CMTPDeleteObject : public CMTPRequestProcessor, public MMTPTransactionProxy |
|
39 { |
|
40 public: |
|
41 |
|
42 static MMTPRequestProcessor* NewL(MMTPDataProviderFramework& aFramework, MMTPConnection& aConnection); |
|
43 ~CMTPDeleteObject(); |
|
44 |
|
45 private: // From CMTPRequestProcessor |
|
46 |
|
47 void ServiceL(); |
|
48 |
|
49 private: // From MMTPTransactionProxy |
|
50 |
|
51 void ProxyReceiveDataL(MMTPType& aData, const TMTPTypeRequest& aRequest, MMTPConnection& aConnection, TRequestStatus& aStatus); |
|
52 void ProxySendDataL(const MMTPType& aData, const TMTPTypeRequest& aRequest, MMTPConnection& aConnection, TRequestStatus& aStatus); |
|
53 void ProxySendResponseL(const TMTPTypeResponse& aResponse, const TMTPTypeRequest& aRequest, MMTPConnection& aConnection, TRequestStatus& aStatus); |
|
54 void ProxyTransactionCompleteL(const TMTPTypeRequest& aRequest, MMTPConnection& aConnection); |
|
55 |
|
56 private: // From CActive |
|
57 |
|
58 void RunL(); |
|
59 |
|
60 private: |
|
61 |
|
62 CMTPDeleteObject(MMTPDataProviderFramework& aFramework, MMTPConnection& aConnection); |
|
63 void ConstructL(); |
|
64 |
|
65 void SendResponseL(TUint16 aCode); |
|
66 void Schedule(TInt aError); |
|
67 |
|
68 void BrowseHandlesL(); |
|
69 void NextObjectHandleL(); |
|
70 static void OnBrowseObjectL( TAny* aSelf, TUint aHandle, TUint32 aCurDepth ); |
|
71 |
|
72 private: |
|
73 __FLOG_DECLARATION_MEMBER_MUTABLE; |
|
74 |
|
75 RMTPFramework iSingletons; |
|
76 TUint iOwnerDp; |
|
77 |
|
78 CMTPObjectBrowser* iObjBrowser; |
|
79 RArray< TUint32 > iHandles; |
|
80 TInt iCurrentHandle; |
|
81 TMTPTypeRequest iCurrentRequest; |
|
82 RArray<TUint> iTargetDps; |
|
83 |
|
84 TUint16 iDeletedObjectsNumber; |
|
85 }; |
|
86 |
|
87 #endif // CMTPDELETEOBJECT_H |
|
88 |