|
1 /* |
|
2 * Copyright (c) 2004 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: Observer interface to receive presence change notifications. |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef __MPENGAUTHORIZATIONOBSERVER_H |
|
19 #define __MPENGAUTHORIZATIONOBSERVER_H |
|
20 |
|
21 // INCLUDES |
|
22 #include <E32Std.h> |
|
23 |
|
24 |
|
25 //FORWARD DECLARATIONS |
|
26 class MPEngAuthorizationRequest; |
|
27 class MPEngAuthorizationStatus; |
|
28 |
|
29 |
|
30 |
|
31 // CLASS DECLARATION |
|
32 |
|
33 /** |
|
34 * Observer interface to receive Authorization notifications. |
|
35 * |
|
36 * @since 3.0 |
|
37 */ |
|
38 class MPEngAuthorizationObserver |
|
39 { |
|
40 |
|
41 public: //Observer methods |
|
42 |
|
43 /** |
|
44 * Authorization handler |
|
45 * |
|
46 * Called when new reactive authorization request was |
|
47 * received from the Server |
|
48 * State of the such a authorization requeste is EPEngAuthPending |
|
49 * If this method leaves, error code is |
|
50 * reported back to HandlePresenceError(). |
|
51 * |
|
52 * @since 3.0 |
|
53 * @param aPendingAuthorization pending authorization |
|
54 * @param aNotifier The notifier source where notification |
|
55 * is coming from. No ownership transferred. |
|
56 */ |
|
57 virtual void HandleNewPendingAuthorization( |
|
58 MPEngAuthorizationRequest& aNewPendingAuthorization ) = 0; |
|
59 |
|
60 |
|
61 |
|
62 virtual void HandlerNewAuthorizationStatus( |
|
63 const MPEngAuthorizationStatus& aNewAuthorizationStatus ) = 0; |
|
64 |
|
65 /** |
|
66 * Handle Authorization engine update |
|
67 * |
|
68 * Called when some athorization was updated. |
|
69 * |
|
70 * @since 3.0 |
|
71 * @param aNotifier The notifier source where notification |
|
72 * is coming from. No ownership transferred. |
|
73 */ |
|
74 virtual void HandleAuthorizationEngineUpdate() = 0; |
|
75 |
|
76 |
|
77 /** |
|
78 * Notification failure handler. |
|
79 * |
|
80 * @since 3.0 |
|
81 * |
|
82 * @param aError The error resulting from Presence Engine internal |
|
83 * presence change event handling (e.g. out of memory) or |
|
84 * leave error from HandlePresenceChangeL(). |
|
85 * @param aNotifier The notifier of which event handling failed. |
|
86 * No ownership transferred. |
|
87 */ |
|
88 virtual void HandleAuthorizationEngineError( |
|
89 TInt aError ) = 0; |
|
90 |
|
91 protected: //Destructor |
|
92 |
|
93 /** |
|
94 * Protected destructor. |
|
95 * Observers can't be destroyed via this interface. |
|
96 */ |
|
97 virtual ~MPEngAuthorizationObserver() { } |
|
98 |
|
99 |
|
100 }; |
|
101 |
|
102 #endif //__MPENGAUTHORIZATIONOBSERVER_H |
|
103 |
|
104 |
|
105 // End of File |
|
106 |
|
107 |