Updated client library with version 0.1.5 (rev. 1665), for changes see change log
[profile/ivi/persistence-client-library.git] / include / persistence_client_library_error_def.h
1 #ifndef PERSISTENCE_CLIENT_LIBRARY_ERROR_DEF_H
2 #define PERSISTENCE_CLIENT_LIBRARY_ERROR_DEF_H
3
4 /******************************************************************************
5  * Project         Persistency
6  * (c) copyright   2012
7  * Company         XS Embedded GmbH
8  *****************************************************************************/
9 /******************************************************************************
10    Permission is hereby granted, free of charge, to any person obtaining
11    a copy of this software and associated documentation files (the "Software"),
12    to deal in the Software without restriction, including without limitation
13    the rights to use, copy, modify, merge, publish, distribute, sublicense,
14    and/or sell copies of the Software, and to permit persons to whom the
15    Software is furnished to do so, subject to the following conditions:
16
17    The above copyright notice and this permission notice shall be included
18    in all copies or substantial portions of the Software.
19
20    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
21    EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
22    MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
23    IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
24    DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
25    TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE
26    OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
27 ******************************************************************************/
28  /**
29  * @file           persistence_client_library_error_def.h
30  * @ingroup        Persistence client library
31  * @author         Ingo Huerner
32  * @brief          Error definition header
33  * @see
34  */
35
36 // common error, for this error errno will be set
37 #define EPERS_COMMON             -1
38 /// file system is locked
39 #define EPERS_LOCKFS             -2
40 /// filesystem is currently locked
41 #define EPERS_MAP_LOCKFS         ((void *) -2)
42 /// bad storage policy
43 #define EPERS_BADPOL             -3
44 /// open handle limit reached
45 #define EPERS_MAXHANDLE          -4
46 /// max buffer limit for persistence data
47 #define EPERS_BUFLIMIT           -5
48 /// persistence resource configuration table not found
49 #define EPERS_NOPRCTABLE         -6
50 /// key not found
51 #define EPERS_NOKEY              -7
52 /// no data for key
53 #define EPERS_NOKEYDATA          -8
54 /// write of data failed
55 #define EPERS_SETDTAFAILED       -9
56 /// failed to open file
57 #define EPERS_OPENFILE           -10
58 /// invalid buffer or key
59 #define EPERS_DESER_BUFORKEY     -11
60 /// can't allocat memory for deserialization of keyvalue
61 #define EPERS_DESER_ALLOCMEM     -12
62 /// no ploicy avaliable in data to serialize
63 #define EPERS_DESER_POLICY       -13
64 /// no store type avaliable in data to serialize
65 #define EPERS_DESER_STORE        -14
66 /// no permission avaliable in data to serialize
67 #define EPERS_DESER_PERM         -15
68 /// no max size avaliable in data to serialize
69 #define EPERS_DESER_MAXSIZE      -16
70 /// no responsibility avaliable in data to serialize
71 #define EPERS_DESER_RESP         -17
72 /// out of array bounds
73 #define EPERS_OUTOFBOUNDS        -18
74 /// failed to map config file
75 #define EPERS_CONFIGMAPFAILED    -19
76 /// config file if not available
77 #define EPERS_CONFIGNOTAVAILABLE -20
78 /// can't stat config file
79 #define EPERS_CONFIGNOSTAT       -21
80 /// plugin functin not found
81 #define EPERS_NOPLUGINFCNT       -22
82 /// dlopen error
83 #define EPERS_DLOPENERROR        -23
84 /// plugin function not loaded
85 #define EPERS_NOPLUGINFUNCT      -24
86
87
88
89 #endif /* PERSISTENCE_CLIENT_LIBRARY_ERROR_DEF_H */