1 sipresolvedclient.h |
1 /* |
|
2 * Copyright (c) 2004-2009 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 "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.symbianfoundation.org/legal/licencesv10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: |
|
15 * Name : SipResolvedClient.h |
|
16 * Part of : SDK API, SIP Client Resolver API |
|
17 * Version : 1.0 |
|
18 * |
|
19 */ |
|
20 |
|
21 |
|
22 |
|
23 #ifndef CSIPRESOLVEDCLIENT_H |
|
24 #define CSIPRESOLVEDCLIENT_H |
|
25 |
|
26 // INCLUDES |
|
27 #include <ecom/ecom.h> |
|
28 #include <stringpool.h> |
|
29 |
|
30 //FORWARD DECLARATIONS |
|
31 class CSIPHeaderBase; |
|
32 class CSIPContentTypeHeader; |
|
33 |
|
34 // CONSTANTS |
|
35 /** Interface UID of this ECOM interface*/ |
|
36 const TUid KSIPResolvedClientIFUid = { 0x102010dd }; |
|
37 |
|
38 // CLASS DEFINITION |
|
39 /** |
|
40 * @publishedAll |
|
41 * @released |
|
42 * |
|
43 * Interface that clients must realize |
|
44 * in order to enable client resolution mechanism upon the reception |
|
45 * of SIP request outside the SIP dialog. Data provided in |
|
46 * the ECOM resource file or optionally requested from the interface implementation |
|
47 * will be used for target client determination by the SIP implementation. |
|
48 * Note that channel UIDs must be unique accross all SIP clients e.g. clients may |
|
49 * use UIDs assigned for binaries. |
|
50 */ |
|
51 class CSIPResolvedClient : public CBase |
|
52 { |
|
53 public: // Destructor |
|
54 |
|
55 /** |
|
56 * Destructor |
|
57 */ |
|
58 virtual inline ~CSIPResolvedClient(); |
|
59 |
|
60 public: // Abstract methods |
|
61 |
|
62 /** |
|
63 * Returns the SIP client's channel UID that indicates client's |
|
64 * channel UID for connection with SIP e.g. CSIP::NewL() |
|
65 * @param aMethod the method of the SIP request |
|
66 * @param aRequestUri the request-URI of the SIP request |
|
67 * @param aHeaders all the headers in the SIP request |
|
68 * @param aContent SIP request body; zero-length descriptor if not present |
|
69 * @param aContentType the content-type of the SIP request. |
|
70 * Zero-pointer if body is not present. |
|
71 * @return SIP client's communication channel's UID |
|
72 */ |
|
73 virtual TUid ChannelL(RStringF aMethod, |
|
74 const TDesC8& aRequestUri, |
|
75 const RPointerArray<CSIPHeaderBase>& aHeaders, |
|
76 const TDesC8& aContent, |
|
77 const CSIPContentTypeHeader* aContentType=0) = 0; |
|
78 |
|
79 /** |
|
80 * Requests the client to connect to SIP with resolved |
|
81 * UID in case there's no connection with resolved channel UID. |
|
82 * @param aUid previously resolved channel UID |
|
83 * @leave KErrNoMemory if out of memory |
|
84 * @leave KErrNotFound in case non-existing channel UID was provided |
|
85 */ |
|
86 virtual void ConnectL(TUid aUid) = 0; |
|
87 |
|
88 /** |
|
89 * Requests the implementation to provide capabilities in XML format |
|
90 * in case they were not defined in the ECOM resource file. The cabablities |
|
91 * to be returned must be defined according to the same DTD. |
|
92 * This function will be invoked only if the capabilities are not |
|
93 * defined in the ECOM resource file. |
|
94 */ |
|
95 virtual const TDesC8& Capabilities(); |
|
96 |
|
97 public: // Data |
|
98 |
|
99 /// Unique key for implementations of this interface. |
|
100 TUid iInstanceKey; |
|
101 |
|
102 protected: // Constructors: |
|
103 |
|
104 inline CSIPResolvedClient(); |
|
105 }; |
|
106 |
|
107 #include <sipresolvedclient.inl> |
|
108 |
|
109 #endif // CSIPRESOLVEDCLIENT_H |