|
1 /* |
|
2 * Copyright (c) 2005-2007 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: |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef VPBKVCARDENGERROR_H |
|
20 #define VPBKVCARDENGERROR_H |
|
21 |
|
22 #ifdef _DEBUG |
|
23 |
|
24 // INCLUDES |
|
25 #include <e32std.h> |
|
26 |
|
27 /** |
|
28 * VPbkVCardEngError internal error codes and functions for |
|
29 * debug code |
|
30 */ |
|
31 namespace VPbkVCardEngError |
|
32 { |
|
33 /// Panic category for VCard engine |
|
34 _LIT( KPanicCategory, "VPbkVCardEng" ); |
|
35 |
|
36 /** |
|
37 * Panic codes for the VPbkVCardEng |
|
38 */ |
|
39 enum TPanicCode |
|
40 { |
|
41 ENullParserProperty = 1, |
|
42 EInvalidLengthOfPropertyArray = 2, |
|
43 EInvalidStateOfExporter = 3, |
|
44 EStrayOperation = 4, |
|
45 ENullFieldType = 5, |
|
46 EInvalidDescriptor = 6, |
|
47 EAddToFieldOperationAlreadyExists = 7, |
|
48 EPostCond_CVPbkVCardCompactBCardImporter_ConstructL = 8, |
|
49 EPreCond_CVPbkImportToStoreOperation_StartL = 9, |
|
50 EPreCond_CommitNextContactL = 10, |
|
51 EPreCond_MergeContactsL = 11 |
|
52 }; |
|
53 |
|
54 /** |
|
55 * Called if an unrecoverable error is detected. |
|
56 * Stops the thread with User::Panic. |
|
57 */ |
|
58 inline void Panic( TPanicCode aPanicCode ); |
|
59 } |
|
60 |
|
61 inline void VPbkVCardEngError::Panic( TPanicCode aPanicCode ) |
|
62 { |
|
63 User::Panic( KPanicCategory, aPanicCode ); |
|
64 } |
|
65 |
|
66 #endif // _DEBUG |
|
67 |
|
68 #endif // VPBKVCARDENGERROR_H |
|
69 |
|
70 // End of File |