Modified custom table, column name as camel case
[platform/core/context/context-provider.git] / src / custom / CustomTypes.h
1 /*
2  * Copyright (c) 2016 Samsung Electronics Co., Ltd.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 #ifndef _CONTEXT_CUSTOM_TYPES_H_
18 #define _CONTEXT_CUSTOM_TYPES_H_
19
20 #include <ProviderTypes.h>
21
22 #define CUSTOM_KEY_REQ                          "req"
23 #define CUSTOM_KEY_PACKAGE_ID           "packageId"
24 #define CUSTOM_KEY_NAME                         "name"
25 #define CUSTOM_KEY_ATTRIBUTES           "attributes"
26 #define CUSTOM_KEY_FACT                         "fact"
27 #define CUSTOM_KEY_SUBJECT                      "subject"
28 #define CUSTOM_KEY_OWNER                        "owner"
29
30 #define CUSTOM_REQ_TYPE_ADD                     "add"
31 #define CUSTOM_REQ_TYPE_REMOVE          "remove"
32 #define CUSTOM_REQ_TYPE_PUBLISH         "publish"
33
34 #define CUSTOM_SEPERATOR                        "/"
35
36 #define CUSTOM_TEMPLATE_TABLE_SCHEMA \
37         "CREATE TABLE IF NOT EXISTS ContextTriggerCustomTemplate " \
38         "(subject TEXT DEFAULT '' NOT NULL PRIMARY KEY, name TEXT DEFAULT '' NOT NULL," \
39         " operation INTEGER DEFAULT 3 NOT NULL, attributes TEXT DEFAULT '' NOT NULL, " \
40         " owner TEXT DEFAULT '' NOT NULL)"
41
42
43 #endif  /* End of _CONTEXT_CUSTOM_TYPES_H_ */