Remove dynamic exceptions
[anna.git] / include / anna / diameter / helpers / dcca / defines.hpp
1 // ANNA - Anna is Not Nothingness Anymore                                                         //
2 //                                                                                                //
3 // (c) Copyright 2005-2015 Eduardo Ramos Testillano & Francisco Ruiz Rayo                         //
4 //                                                                                                //
5 // See project site at http://redmine.teslayout.com/projects/anna-suite                           //
6 // See accompanying file LICENSE or copy at http://www.teslayout.com/projects/public/anna.LICENSE //
7
8
9 #ifndef anna_diameter_helpers_dcca_defines_hpp
10 #define anna_diameter_helpers_dcca_defines_hpp
11
12
13 // Local
14 #include <anna/diameter/helpers/defines.hpp>
15
16 // STL
17 #include <string>
18
19
20 /** Contextualized definitions (avp id) */
21 #define anna_diameter_helpers_define_avp(avpname,code)  anna_diameter_helpers_define_avp_in_context(avpname,code,dcca)
22
23 /** Contextualized definitions (avp id and values) */
24 #define anna_diameter_helpers_define_avp_with_values(avpname,code)  anna_diameter_helpers_define_avp_with_values_in_context(avpname,code,dcca)
25
26
27 namespace anna {
28
29 namespace diameter {
30
31 namespace helpers {
32
33 namespace dcca {
34
35
36 /**
37 * Avps
38 */
39 anna_diameter_helpers_define_avp(CC_Correlation_Id, 411);
40 anna_diameter_helpers_define_avp(CC_Input_Octets, 412);
41 anna_diameter_helpers_define_avp(CC_Money, 413);
42 anna_diameter_helpers_define_avp(CC_Output_Octets, 414);
43 anna_diameter_helpers_define_avp(CC_Request_Number, 415);
44 anna_diameter_helpers_define_avp_with_values(CC_Request_Type, 416) {
45   enum v_ {
46     INITIAL_REQUEST = 1,
47     UPDATE_REQUEST = 2,
48     TERMINATION_REQUEST = 3,
49     EVENT_REQUEST = 4
50   };
51 };
52
53 anna_diameter_helpers_define_avp(CC_Service_Specific_Units, 417);
54 anna_diameter_helpers_define_avp_with_values(CC_Session_Failover, 418) {
55   enum v_ {
56     FAILOVER_NOT_SUPPORTED = 0,
57     FAILOVER_SUPPORTED = 1
58   };
59 };
60
61 anna_diameter_helpers_define_avp(CC_Sub_Session_Id, 419);
62 anna_diameter_helpers_define_avp(CC_Time, 420);
63 anna_diameter_helpers_define_avp(CC_Total_Octets, 421);
64 anna_diameter_helpers_define_avp_with_values(Check_Balance_Result, 422) {
65   enum v_ {
66     ENOUGH_CREDIT = 0,
67     NO_CREDIT = 1
68   };
69 };
70
71 anna_diameter_helpers_define_avp(Cost_Information, 423);
72 anna_diameter_helpers_define_avp(Cost_Unit, 424);
73 anna_diameter_helpers_define_avp(Currency_Code, 425);
74 anna_diameter_helpers_define_avp_with_values(Credit_Control, 426) {
75   enum v_ {
76     CREDIT_AUTHORIZATION = 0,
77     RE_AUTHORIZATION = 1
78   };
79 };
80
81 anna_diameter_helpers_define_avp_with_values(Credit_Control_Failure_Handling, 427) {
82   enum v_ {
83     TERMINATE = 0,
84     CONTINUE = 1,
85     RETRY_AND_TERMINATE = 2
86   };
87 };
88
89 anna_diameter_helpers_define_avp_with_values(Direct_Debiting_Failure_Handling, 428) {
90   enum v_ {
91     TERMINATE_OR_BUFFER = 0,
92     CONTINUE = 1
93   };
94 };
95
96 anna_diameter_helpers_define_avp(Exponent, 429);
97 anna_diameter_helpers_define_avp(Final_Unit_Indication, 430);
98 anna_diameter_helpers_define_avp(Granted_Service_Unit, 431);
99 anna_diameter_helpers_define_avp(Rating_Group, 432);
100 anna_diameter_helpers_define_avp_with_values(Redirect_Address_Type, 433) {
101   enum v_ {
102     IPv4_Address = 0,
103     IPv6_Address = 1,
104     URL = 2,
105     SIP_URL = 3
106   };
107 };
108
109 anna_diameter_helpers_define_avp(Redirect_Server, 434);
110 anna_diameter_helpers_define_avp(Redirect_Server_Address, 435);
111 anna_diameter_helpers_define_avp_with_values(Requested_Action, 436) {
112   enum v_ {
113     DIRECT_DEBITING = 0,
114     REFUND_ACCOUNT = 1,
115     CHECK_BALANCE = 2,
116     PRICE_ENQUIRY = 3
117   };
118 };
119
120 anna_diameter_helpers_define_avp(Requested_Service_Unit, 437);
121 anna_diameter_helpers_define_avp(Restriction_Filter_Rule, 438);
122 anna_diameter_helpers_define_avp(Service_Identifier, 439);
123 anna_diameter_helpers_define_avp(Service_Parameter_Info, 440);
124 anna_diameter_helpers_define_avp(Service_Parameter_Type, 441);
125 anna_diameter_helpers_define_avp(Service_Parameter_Value, 442);
126 anna_diameter_helpers_define_avp(Subscription_Id, 443);
127 anna_diameter_helpers_define_avp(Subscription_Id_Data, 444);
128 anna_diameter_helpers_define_avp(Unit_Value, 445);
129 anna_diameter_helpers_define_avp(Used_Service_Unit, 446);
130 anna_diameter_helpers_define_avp(Value_Digits, 447);
131 anna_diameter_helpers_define_avp(Validity_Time, 448);
132 anna_diameter_helpers_define_avp_with_values(Final_Unit_Action, 449) {
133   enum v_ {
134     TERMINATE = 0,
135     REDIRECT = 1,
136     RESTRICT_ACCESS = 2
137   };
138 };
139
140 anna_diameter_helpers_define_avp_with_values(Subscription_Id_Type, 450) {
141   enum v_ {
142     END_USER_E164 = 0,
143     END_USER_IMSI = 1,
144     END_USER_SIP_URL = 2,
145     END_USER_NAI = 3,
146     END_USER_PRIVATE = 4
147   };
148 };
149
150 anna_diameter_helpers_define_avp(Tariff_Time_Change, 451);
151 anna_diameter_helpers_define_avp_with_values(Tariff_Change_Usage, 452) {
152   enum v_ {
153     UNIT_BEFORE_TARIFF_CHANGE = 0,
154     UNIT_AFTER_TARIFF_CHANGE = 1,
155     UNIT_INDETERMINATE = 2
156   };
157 };
158
159 anna_diameter_helpers_define_avp(G_S_U_Pool_Identifier, 453);
160 anna_diameter_helpers_define_avp_with_values(CC_Unit_Type, 454) {
161   enum v_ {
162     TIME = 0,
163     MONEY = 1,
164     TOTAL_OCTETS = 2,
165     INPUT_OCTETS = 3,
166     OUTPUT_OCTETS = 4,
167     SERVICE_SPECIFIC_UNITS = 5
168   };
169 };
170
171 anna_diameter_helpers_define_avp_with_values(Multiple_Services_Indicator, 455) {
172   enum v_ {
173     MULTIPLE_SERVICES_NOT_SUPPORTED = 0,
174     MULTIPLE_SERVICES_SUPPORTED = 1
175   };
176 };
177
178 anna_diameter_helpers_define_avp(Multiple_Services_Credit_Control, 456);
179 anna_diameter_helpers_define_avp(G_S_U_Pool_Reference, 457);
180 anna_diameter_helpers_define_avp(User_Equipment_Info, 458);
181 anna_diameter_helpers_define_avp_with_values(User_Equipment_Info_Type, 459) {
182   enum v_ {
183     IMEISV = 0,
184     MAC = 1,
185     EUI64 = 2,
186     MODIFIED_EUI64 = 3
187   };
188 };
189
190 anna_diameter_helpers_define_avp(User_Equipment_Info_Value, 460);
191 anna_diameter_helpers_define_avp(Service_Context_Id, 461);
192
193
194 /**
195 * Commands
196 */
197 anna_diameter_helpers_define_command_request(Credit_Control_Request, 272);
198 anna_diameter_helpers_define_command_answer(Credit_Control_Answer, 272);
199
200
201 }
202 }
203 }
204 }
205
206
207 #undef anna_diameter_helpers_define_avp
208 #undef anna_diameter_helpers_define_avp_with_values
209
210 #endif
211