|
1 /* |
|
2 * Copyright (c) 2003 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: Stored group interface (setters) |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef MCAEXTENDEDSTOREDGROUP_H |
|
21 #define MCAEXTENDEDSTOREDGROUP_H |
|
22 |
|
23 #include <e32std.h> |
|
24 #include <badesca.h> |
|
25 |
|
26 #include "MCAStoredGroup.h" |
|
27 #include "TStorageManagerGlobals.h" |
|
28 |
|
29 // FORWARD DECLARATIONS |
|
30 class RReadStream; |
|
31 class RWriteStream; |
|
32 |
|
33 // CLASS DECLARATION |
|
34 |
|
35 /** |
|
36 * Interface for stored groups (setters). |
|
37 * |
|
38 * @lib CAStorage.dll |
|
39 * @since 2.1 |
|
40 */ |
|
41 class MCAExtendedStoredGroup : public MCAStoredGroup |
|
42 { |
|
43 public: // Interface |
|
44 |
|
45 /** |
|
46 * Set whether this group is joined by the user or not |
|
47 * @since 2.1 |
|
48 * @param aJoinStatus ETrue if the group is joined |
|
49 */ |
|
50 virtual void SetJoined( TBool aJoinStatus ) = 0; |
|
51 |
|
52 /** |
|
53 * Add members to the group locally. Makes copies of the |
|
54 * descriptors. |
|
55 * @since 2.1 |
|
56 * @param aMemberList The list of User Ids of members to add |
|
57 */ |
|
58 virtual void AddMembersLocallyL( const MDesCArray& aMemberList ) = 0; |
|
59 |
|
60 /** |
|
61 * Remove members from the group locally |
|
62 * @since 2.1 |
|
63 * @param aMemberList The list of User Ids of members to remove |
|
64 */ |
|
65 virtual void RemoveMembersLocally( const MDesCArray& aMemberList ) = 0; |
|
66 |
|
67 /** |
|
68 * Removes all members from the group locally |
|
69 * @since 2.1 |
|
70 */ |
|
71 virtual void ResetMembersLocally() = 0; |
|
72 |
|
73 /** |
|
74 * Set whether this group is the user's own group |
|
75 * @since 2.1 |
|
76 * @param aOwnGroupStatus ETrue if the group is the user's own |
|
77 */ |
|
78 virtual void SetOwnGroup( TBool aOwnGroupStatus ) = 0; |
|
79 |
|
80 /** |
|
81 * Add a participant to the group. Makes copies of the desciptors. |
|
82 * @since 2.1 |
|
83 * @param aParticipantList The list of participants' User Ids whom to add |
|
84 */ |
|
85 virtual void AddParticipantL( const MDesCArray& aParticipantList ) = 0; |
|
86 |
|
87 /** |
|
88 * Remove participant from the group |
|
89 * @since 2.1 |
|
90 * @param aParticipantList The list of participants' User Ids whom to |
|
91 * remove |
|
92 */ |
|
93 virtual void RemoveParticipantL( const MDesCArray& aParticipantList ) = 0; |
|
94 |
|
95 /** |
|
96 * Remove all participants from the group |
|
97 * @since 2.1 |
|
98 */ |
|
99 virtual void ResetParticipantsL() = 0; |
|
100 |
|
101 /** |
|
102 * Set the storage type |
|
103 * @since 2.1 |
|
104 * @param aStorageType The storage type |
|
105 */ |
|
106 virtual void SetStorageType( TStorageManagerGlobals::TCAStorageType aType ) = 0; |
|
107 |
|
108 /** |
|
109 * Set the Group Id associated with this group. |
|
110 * @since 2.1 |
|
111 * @param The group id |
|
112 */ |
|
113 virtual void SetGroupIdL( const TDesC& aGroupId ) = 0; |
|
114 |
|
115 /** |
|
116 * Set the Group Name associated with this group. |
|
117 * @since 2.1 |
|
118 * @param The group name |
|
119 */ |
|
120 virtual void SetGroupNameL( const TDesC& aGroupName ) = 0; |
|
121 |
|
122 /** |
|
123 * Set the administrator status of the user in this group |
|
124 * @since 2.1 |
|
125 * @param aStatus ETrue if the user is administrator |
|
126 */ |
|
127 virtual void SetAdmin( const TBool aStatus ) = 0; |
|
128 |
|
129 /** |
|
130 * Set the visibility status of the group |
|
131 * @since 2.1 |
|
132 * @param aVisible ETrue if the group can be seen in UI |
|
133 */ |
|
134 virtual void SetVisible( const TBool aVisible ) = 0; |
|
135 |
|
136 /** |
|
137 * Set the home server of this group |
|
138 * @since 2.1 |
|
139 * @param aServer The server in which this group resides |
|
140 */ |
|
141 virtual void SetServerL( const TDesC& aServer ) = 0; |
|
142 |
|
143 /** |
|
144 * Save the changes made to groups |
|
145 * @since 2.1 |
|
146 */ |
|
147 virtual void SaveChangesL() = 0; |
|
148 |
|
149 /** |
|
150 * Externalize the group instance data. |
|
151 * Used by CCAStorage. |
|
152 * @since 2.1 |
|
153 * @param aStream The stream into which to externalize |
|
154 */ |
|
155 virtual void ExternalizeL( RWriteStream& aStream ) const = 0; |
|
156 |
|
157 /** |
|
158 * Internalize the group instance data. |
|
159 * Used by CCAStorage. |
|
160 * @since 2.1 |
|
161 * @param aStream The stream into which to internalize |
|
162 */ |
|
163 virtual void InternalizeL( RReadStream& aStream ) = 0; |
|
164 |
|
165 /** |
|
166 * Return the theoretical maximum size needed by the contact if it is |
|
167 * externalized. |
|
168 * @since 2.1 |
|
169 * @return The maximal size |
|
170 */ |
|
171 virtual TInt32 MaximalSize() const = 0; |
|
172 |
|
173 /** |
|
174 * Get version number of the contact implementation. Needed for |
|
175 * backward compatibility. |
|
176 * @since 2.1 |
|
177 * @return The version number, where 1 is the first version. |
|
178 */ |
|
179 virtual TInt32 Version() const = 0; |
|
180 }; |
|
181 |
|
182 #endif // MCAEXTENDEDSTOREDGROUP_H |
|
183 |
|
184 // End of File |