|
1 /* |
|
2 * Copyright (c) 2006 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: MNcdPreminetProtocolPurchaseOption declaration |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef NCD_PREMINET_PROTOCOL_SUBSCRIPTION_H |
|
20 #define NCD_PREMINET_PROTOCOL_SUBSCRIPTION_H |
|
21 |
|
22 #include <e32base.h> |
|
23 #include "ncdprotocoltypes.h" |
|
24 |
|
25 |
|
26 class MNcdPreminetProtocolSubscriptionDetails; |
|
27 class MNcdPreminetProtocolPayment; |
|
28 class MNcdConfigurationProtocolQuery; |
|
29 |
|
30 class MNcdPreminetProtocolSubscription |
|
31 { |
|
32 public: |
|
33 |
|
34 /** |
|
35 * Destructor |
|
36 */ |
|
37 virtual ~MNcdPreminetProtocolSubscription() {} |
|
38 |
|
39 /** |
|
40 * Namespace. |
|
41 * @return The namespace. |
|
42 */ |
|
43 virtual const TDesC& Namespace() const = 0; |
|
44 |
|
45 /** |
|
46 * Entity id. |
|
47 * @return Entity id or KNullDesC |
|
48 */ |
|
49 virtual const TDesC& EntityId() const = 0; |
|
50 |
|
51 /** |
|
52 * Purchase option id. |
|
53 * @return Purchase option id or KNullDesC |
|
54 */ |
|
55 virtual const TDesC& PurchaseOptionId() const = 0; |
|
56 |
|
57 /** |
|
58 * Subscription timestamp. |
|
59 * @return Timestamp or KNullDesC |
|
60 */ |
|
61 virtual const TDesC& Timestamp() const = 0; |
|
62 |
|
63 /** |
|
64 * Subsctiption type. |
|
65 * @return Type |
|
66 */ |
|
67 virtual TNcdSubscriptionType Type() const = 0; |
|
68 |
|
69 /** |
|
70 * Retuns true if this subscription is cancelled. |
|
71 * @return true or false |
|
72 */ |
|
73 virtual TBool Cancelled() const = 0; |
|
74 |
|
75 /** |
|
76 * Total usage rights of this subscription. |
|
77 * @return Subscription details pointer or NULL |
|
78 */ |
|
79 virtual const MNcdPreminetProtocolSubscriptionDetails* |
|
80 TotalUsageRights() const = 0; |
|
81 |
|
82 /** |
|
83 * Remaining usage rights of this subscription. |
|
84 * @return Subscription details pointer or NULL |
|
85 */ |
|
86 virtual const MNcdPreminetProtocolSubscriptionDetails* |
|
87 RemainingUsageRights() const = 0; |
|
88 |
|
89 /** |
|
90 * Timestamp of expiration |
|
91 * @return Timestamp or KNullDesC |
|
92 */ |
|
93 virtual const TDesC& ExpiredOn() const = 0; |
|
94 |
|
95 /** |
|
96 * Usage rights of this subscription. |
|
97 * Wrapping method for old subscriptions, uses TotalUsageRights(). |
|
98 * @return Subscription details pointer or NULL |
|
99 */ |
|
100 virtual const MNcdPreminetProtocolSubscriptionDetails* |
|
101 UsageRights() const = 0; |
|
102 }; |
|
103 |
|
104 |
|
105 #endif //NCD_PREMINET_PROTOCOL_SUBSCRIPTION_H |