|
1 /** @file |
|
2 * Copyright (c) 2008 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: Definition of CUpnpSoapActionHttpTransaction |
|
15 * |
|
16 */ |
|
17 |
|
18 #include "upnpaction.h" |
|
19 #include "upnpsoapactionhttptransaction.h" |
|
20 #include "upnpcontrolpoint.h" |
|
21 |
|
22 |
|
23 // ---------------------------------------------------------------------------- |
|
24 // CUpnpSoapActionHttpTransaction::~CUpnpSoapActionHttpTransaction |
|
25 // Destructor. |
|
26 // ---------------------------------------------------------------------------- |
|
27 // |
|
28 CUpnpSoapActionHttpTransaction::~CUpnpSoapActionHttpTransaction( ) |
|
29 { |
|
30 } |
|
31 |
|
32 // ---------------------------------------------------------------------------- |
|
33 // CUpnpSoapActionHttpTransaction::NewLC |
|
34 // Two-phased constructor, that takes ownership of a message and guarantee it's |
|
35 // destruction even when leave ocures. |
|
36 // Caller shouldn't place aMsg on cleanupstack before method call |
|
37 // ---------------------------------------------------------------------------- |
|
38 // |
|
39 CUpnpSoapActionHttpTransaction* CUpnpSoapActionHttpTransaction::NewLC( |
|
40 CUpnpHttpMessage* aRequest, TInt aActionId, CUpnpControlPoint& aControlPoint ) |
|
41 { |
|
42 CleanupStack::PushL( aRequest ); |
|
43 CUpnpSoapActionHttpTransaction* self = |
|
44 new (ELeave) CUpnpSoapActionHttpTransaction( aRequest, aActionId, aControlPoint ); |
|
45 CleanupStack::Pop( aRequest );//now msg is safe it will be deleted from destructor |
|
46 CleanupStack::PushL( self ); |
|
47 self->BaseConstructL(); |
|
48 return self; |
|
49 } |
|
50 |
|
51 // ---------------------------------------------------------------------------- |
|
52 // CUpnpSoapActionHttpTransaction::CUpnpSoapActionHttpTransaction |
|
53 // Constructor. |
|
54 // ---------------------------------------------------------------------------- |
|
55 // |
|
56 CUpnpSoapActionHttpTransaction::CUpnpSoapActionHttpTransaction( |
|
57 CUpnpHttpMessage* aRequest, TInt aActionId, CUpnpControlPoint& aControlPoint) : |
|
58 CUpnpHttpTransaction( aRequest ), iActionId( aActionId ), iControlPoint( aControlPoint ) |
|
59 { |
|
60 } |
|
61 |
|
62 // ---------------------------------------------------------------------------- |
|
63 // CUpnpSoapActionHttpTransaction::ProcessResponseL() |
|
64 // Processes response by passing it to control point. |
|
65 // ---------------------------------------------------------------------------- |
|
66 // |
|
67 void CUpnpSoapActionHttpTransaction::ProcessResponseL() |
|
68 { |
|
69 Response()->SetSessionId( iActionId ); |
|
70 iControlPoint.ProcessActionMessageL( Response() ); |
|
71 } |
|
72 |
|
73 // End of File |
|
74 |