|
1 /* |
|
2 * Copyright (c) 2002 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: invitation interface for UI |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef MCAINVITE_H |
|
20 #define MCAINVITE_H |
|
21 |
|
22 // INCLUDES |
|
23 #include <e32std.h> |
|
24 |
|
25 // INCLUDES |
|
26 #include "CCAInvitationRequest.h" |
|
27 #include "MCAInvitation.h" |
|
28 |
|
29 // FORWARD DECLARATIONS |
|
30 class MCAInviteObserver; |
|
31 |
|
32 // CLASS DECLARATION |
|
33 |
|
34 /** |
|
35 * Invitation handling interface for UI. |
|
36 * |
|
37 * |
|
38 * @lib CAEngine.lib |
|
39 * @since 1.2 |
|
40 */ |
|
41 class MCAInvite |
|
42 { |
|
43 public: |
|
44 |
|
45 /** |
|
46 * Sends an invitation for joining to a group. |
|
47 * @param aInvitation specifies the invitation (texts etc.). |
|
48 */ |
|
49 virtual void SendInvitationL( |
|
50 const CCAInvitationRequest& aInvitation ) = 0; |
|
51 |
|
52 /** |
|
53 * This is the reply to an invitation. |
|
54 * Note that invitation gets removed by this call, so do not try to use |
|
55 * it after calling this!!! |
|
56 * @param aInvitation is the invitation. |
|
57 * @param aInviteAccepted specifies if the invite was accepted or not. |
|
58 * @param aResponse is the response |
|
59 * @param aScreenName is our own screenname |
|
60 */ |
|
61 virtual void ReplyInvitationL( const MCAInvitation* aInvitation, |
|
62 const TBool aInviteAccepted, |
|
63 const TDesC& aResponse, |
|
64 const TDesC& aScreenName ) = 0; |
|
65 |
|
66 /** |
|
67 * Adds an invite observer. Invitation events are guided to this |
|
68 * observer. |
|
69 * @param aObserver specifies the observer. |
|
70 * @return KErrNone if successful, otherwise one of the system error codes |
|
71 */ |
|
72 virtual TInt AddInviteObserver( MCAInviteObserver* aObserver ) = 0; |
|
73 |
|
74 /** |
|
75 * Removes an invite observer. |
|
76 * @param aObserver specifies the observer. |
|
77 */ |
|
78 virtual void RemoveInviteObserver( MCAInviteObserver* aObserver ) = 0; |
|
79 |
|
80 /** |
|
81 * Populates the list with currently unhandled invitations |
|
82 * @since 2.1 |
|
83 */ |
|
84 virtual void PopulateInviteList( RPointerArray<MCAInvitation>& aList ) = 0; |
|
85 |
|
86 /** |
|
87 * Returns the number of unhandled invitations |
|
88 * @since 2.1 |
|
89 * @return The number of received active |
|
90 */ |
|
91 virtual TInt ActiveInvitations() = 0; |
|
92 |
|
93 /** |
|
94 * Removes the invitation |
|
95 * @since 2.1 |
|
96 * @param aInvitation |
|
97 */ |
|
98 virtual void RemoveInvitationL( MCAInvitation* aInvitation ) = 0; |
|
99 |
|
100 /** |
|
101 * Gets the pointer to buffer holding the reject reason |
|
102 * This is stored in the engine side because the last written |
|
103 * reason must be remembered |
|
104 * @since 2.1 |
|
105 * @return The pointer to reject reason, which can be modified |
|
106 */ |
|
107 virtual HBufC* RejectReasonPtr() = 0; |
|
108 |
|
109 /** |
|
110 * Amount of unread invite messages |
|
111 * @return Amount of unread invite messages |
|
112 */ |
|
113 virtual TInt UnreadInvitesCount() const = 0; |
|
114 |
|
115 protected: |
|
116 |
|
117 /** |
|
118 * Deletion through this class is not wanted. |
|
119 */ |
|
120 virtual ~MCAInvite() {}; |
|
121 }; |
|
122 |
|
123 #endif // MCAINVITE_H |
|
124 |
|
125 // End of File |