|
1 /* |
|
2 * Copyright (c) 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 "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: Declaration of CCDSYMessagesServiceLogic class |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef CDSYMESSAGESSERVICELOGIC_H |
|
20 #define CDSYMESSAGESSERVICELOGIC_H |
|
21 |
|
22 // INCLUDES |
|
23 #include <e32base.h> |
|
24 |
|
25 |
|
26 |
|
27 // CONSTANTS |
|
28 // MACROS |
|
29 // DATA TYPES |
|
30 // FUNCTION PROTOTYPES |
|
31 // FORWARD DECLARATIONS |
|
32 class MCDSYServiceLogic; |
|
33 |
|
34 |
|
35 |
|
36 /** |
|
37 * CCDSYMessagesServiceLogic |
|
38 * This class implements the CCDSYMessagesServiceLogic, which stores the message and service logic binding. |
|
39 */ |
|
40 NONSHARABLE_CLASS( CCDSYMessagesServiceLogic ): public CBase |
|
41 { |
|
42 public: |
|
43 /** |
|
44 * Destructor. |
|
45 */ |
|
46 ~CCDSYMessagesServiceLogic(); |
|
47 |
|
48 /** |
|
49 * Creates a new instance of CCDSYMessagesServiceLogic. |
|
50 * @param const TUint32 aMessageGroup Message group to which the service logic is registered. |
|
51 * @param const TUint32 aMessageID Message ID to which the service logic is registered. |
|
52 * @param MCDSYServiceLogic* aCDSYServiceLogic Pointer to service logic. |
|
53 * @return static CCDSYMessagesServiceLogic* Pointer to an instance of CCDSYMessagesServiceLogic. |
|
54 */ |
|
55 static CCDSYMessagesServiceLogic* NewL( const TUint32 aMessageGroup, const TUint32 aMessageID, MCDSYServiceLogic* aCDSYServiceLogic ); |
|
56 |
|
57 /** |
|
58 * Creates a new instance of CCDSYMessagesServiceLogic. |
|
59 * @param const TUint32 aMessageGroup Message group to which the service logic is registered. |
|
60 * @param const TUint32 aMessageID Message ID to which the service logic is registered. |
|
61 * @param const TUint32 aMessageTransactionID Message's transaction ID to which the service logic is registered. |
|
62 * @param MCDSYServiceLogic* aCDSYServiceLogic Pointer to service logic. |
|
63 * @return static CCDSYMessagesServiceLogic* Pointer to an instance of CCDSYMessagesServiceLogic. |
|
64 */ |
|
65 static CCDSYMessagesServiceLogic* NewL( const TUint32 aMessageGroup, const TUint32 aMessageID, const TUint32 aMessageTransactionID, MCDSYServiceLogic* aCDSYServiceLogic ); |
|
66 |
|
67 /** |
|
68 * Returns the message group to which the service logic is registered. |
|
69 * @return inline TUint32 Message group to which the service logic is registered. |
|
70 */ |
|
71 inline TUint32 MessageGroup() const |
|
72 { |
|
73 return iMessageGroup; |
|
74 } |
|
75 |
|
76 /** |
|
77 * Returns the message ID to which the service logic is registered. |
|
78 * @return TUint32 Message ID to which the service logic is registered. |
|
79 */ |
|
80 inline TUint32 MessageID() const |
|
81 { |
|
82 return iMessageID; |
|
83 } |
|
84 |
|
85 /** |
|
86 * Returns the service logic related to the message. |
|
87 * @return inline MCDSYServiceLogic* Pointer to service logic related to the message. |
|
88 */ |
|
89 inline MCDSYServiceLogic* CDSYServiceLogic() |
|
90 { |
|
91 return iCDSYServiceLogic; |
|
92 } |
|
93 |
|
94 /** |
|
95 * Returns if the service logic is dynamically registered. |
|
96 * @return TBool Registration status. |
|
97 */ |
|
98 inline TBool DynamicRegistration() const |
|
99 { |
|
100 return iDynamicRegistration; |
|
101 } |
|
102 |
|
103 /** |
|
104 * Returns the tranasaction ID to which the service logic is registered. |
|
105 * @return TUint32 Transaction ID. |
|
106 */ |
|
107 inline TUint32 MessageTransactionID() const |
|
108 { |
|
109 return iMessageTransactionID; |
|
110 } |
|
111 |
|
112 private: |
|
113 /** |
|
114 * Constructor. |
|
115 * @param const TUint32 aMessageGroup Message group to which the service logic is registered. |
|
116 * @param const TUint32 aMessageID Message ID to which the service logic is registered. |
|
117 * @param const TUint32 aMessageTransactionID Message's transaction ID to which the service logic is registered. |
|
118 * @param const TBool aDynamicRegistration Dynamic registration. |
|
119 * @param MCDSYServiceLogic* aCDSYServiceLogic Pointer to service logic. |
|
120 */ |
|
121 CCDSYMessagesServiceLogic( const TUint32 aMessageGroup, const TUint32 aMessageID, const TUint32 aMessageTransactionID, const TBool aDynamicRegistration, MCDSYServiceLogic* aCDSYServiceLogic ); |
|
122 |
|
123 private: |
|
124 TUint32 iMessageGroup; |
|
125 TUint32 iMessageID; |
|
126 TUint32 iMessageTransactionID; |
|
127 TBool iDynamicRegistration; |
|
128 MCDSYServiceLogic* iCDSYServiceLogic; |
|
129 }; |
|
130 |
|
131 |
|
132 |
|
133 #endif // CDSYMESSAGESSERVICELOGIC_H |
|
134 |
|
135 |
|
136 |
|
137 // End of File |