]> CyberLeo.Net >> Repos - FreeBSD/releng/10.2.git/blob - contrib/subversion/subversion/libsvn_wc/token-map.h
- Copy stable/10@285827 to releng/10.2 in preparation for 10.2-RC1
[FreeBSD/releng/10.2.git] / contrib / subversion / subversion / libsvn_wc / token-map.h
1 /**
2  * ====================================================================
3  *    Licensed to the Apache Software Foundation (ASF) under one
4  *    or more contributor license agreements.  See the NOTICE file
5  *    distributed with this work for additional information
6  *    regarding copyright ownership.  The ASF licenses this file
7  *    to you under the Apache License, Version 2.0 (the
8  *    "License"); you may not use this file except in compliance
9  *    with the License.  You may obtain a copy of the License at
10  *
11  *      http://www.apache.org/licenses/LICENSE-2.0
12  *
13  *    Unless required by applicable law or agreed to in writing,
14  *    software distributed under the License is distributed on an
15  *    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  *    KIND, either express or implied.  See the License for the
17  *    specific language governing permissions and limitations
18  *    under the License.
19  * ====================================================================
20  *
21  * This header is parsed by transform-sql.py to allow SQLite
22  * statements to refer to string values by symbolic names.
23  */
24
25 #ifndef SVN_WC_TOKEN_MAP_H
26 #define SVN_WC_TOKEN_MAP_H
27
28 #include "svn_types.h"
29 #include "wc_db.h"
30 #include "private/svn_token.h"
31
32 #ifdef __cplusplus
33 extern "C" {
34 #endif
35
36 static const svn_token_map_t kind_map[] = {
37   { "file", svn_node_file }, /* MAP_FILE */
38   { "dir", svn_node_dir }, /* MAP_DIR */
39   { "symlink", svn_node_symlink }, /* MAP_SYMLINK */
40   { "unknown", svn_node_unknown }, /* MAP_UNKNOWN */
41   { NULL }
42 };
43
44 /* Note: we only decode presence values from the database. These are a
45    subset of all the status values. */
46 static const svn_token_map_t presence_map[] = {
47   { "normal", svn_wc__db_status_normal }, /* MAP_NORMAL */
48   { "server-excluded", svn_wc__db_status_server_excluded }, /* MAP_SERVER_EXCLUDED */
49   { "excluded", svn_wc__db_status_excluded }, /* MAP_EXCLUDED */
50   { "not-present", svn_wc__db_status_not_present }, /* MAP_NOT_PRESENT */
51   { "incomplete", svn_wc__db_status_incomplete }, /* MAP_INCOMPLETE */
52   { "base-deleted", svn_wc__db_status_base_deleted }, /* MAP_BASE_DELETED */
53   { NULL }
54 };
55
56 /* The subset of svn_depth_t used in the database. */
57 static const svn_token_map_t depth_map[] = {
58   { "unknown", svn_depth_unknown }, /* MAP_DEPTH_UNKNOWN */
59   { "empty", svn_depth_empty },
60   { "files", svn_depth_files },
61   { "immediates", svn_depth_immediates },
62   { "infinity", svn_depth_infinity }, /* MAP_DEPTH_INFINITY */
63   { NULL }
64 };
65
66 #ifdef __cplusplus
67 }
68 #endif
69
70 #endif