]> CyberLeo.Net >> Repos - FreeBSD/releng/10.0.git/blob - contrib/subversion/subversion/libsvn_wc/lock.h
- Copy stable/10 (r259064) to releng/10.0 as part of the
[FreeBSD/releng/10.0.git] / contrib / subversion / subversion / libsvn_wc / lock.h
1 /*
2  * lock.h:  routines for locking working copy subdirectories.
3  *
4  * ====================================================================
5  *    Licensed to the Apache Software Foundation (ASF) under one
6  *    or more contributor license agreements.  See the NOTICE file
7  *    distributed with this work for additional information
8  *    regarding copyright ownership.  The ASF licenses this file
9  *    to you under the Apache License, Version 2.0 (the
10  *    "License"); you may not use this file except in compliance
11  *    with the License.  You may obtain a copy of the License at
12  *
13  *      http://www.apache.org/licenses/LICENSE-2.0
14  *
15  *    Unless required by applicable law or agreed to in writing,
16  *    software distributed under the License is distributed on an
17  *    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
18  *    KIND, either express or implied.  See the License for the
19  *    specific language governing permissions and limitations
20  *    under the License.
21  * ====================================================================
22  */
23
24 \f
25 #ifndef SVN_LIBSVN_WC_LOCK_H
26 #define SVN_LIBSVN_WC_LOCK_H
27
28 #include <apr_pools.h>
29 #include <apr_hash.h>
30
31 #include "svn_types.h"
32 #include "svn_error.h"
33 #include "svn_wc.h"
34
35 #include "wc_db.h"
36
37 #ifdef __cplusplus
38 extern "C" {
39 #endif /* __cplusplus */
40
41 \f
42 /*** General utilities that may get moved upstairs at some point. */
43
44 /* Store ENTRIES in the cache in ADM_ACCESS.  ENTRIES may be NULL. */
45 void svn_wc__adm_access_set_entries(svn_wc_adm_access_t *adm_access,
46                                     apr_hash_t *entries);
47
48 /* Return the entries hash cached in ADM_ACCESS.  The returned hash may
49    be NULL.  */
50 apr_hash_t *svn_wc__adm_access_entries(svn_wc_adm_access_t *adm_access);
51
52 /* Same as svn_wc__adm_retrieve_internal, but takes a DB and an absolute
53    directory path.  */
54 svn_wc_adm_access_t *
55 svn_wc__adm_retrieve_internal2(svn_wc__db_t *db,
56                                const char *abspath,
57                                apr_pool_t *scratch_pool);
58
59 /* ### this is probably bunk. but I dunna want to trace backwards-compat
60    ### users of svn_wc_check_wc(). probably gonna be rewritten for wc-ng
61    ### in any case.
62
63    If CHECK_PATH is TRUE, a not-existing directory is not a working copy */
64 svn_error_t *
65 svn_wc__internal_check_wc(int *wc_format,
66                           svn_wc__db_t *db,
67                           const char *local_abspath,
68                           svn_boolean_t check_path,
69                           apr_pool_t *scratch_pool);
70
71 /* Return the working copy database associated with this access baton. */
72 svn_wc__db_t *
73 svn_wc__adm_get_db(const svn_wc_adm_access_t *adm_access);
74
75
76 /* Get a reference to the baton's internal ABSPATH.  */
77 const char *
78 svn_wc__adm_access_abspath(const svn_wc_adm_access_t *adm_access);
79
80 /* Return the pool used by access baton ADM_ACCESS.
81  * Note: This is a non-deprecated variant of svn_wc_adm_access_pool for
82  * libsvn_wc internal usage only.
83  */
84 apr_pool_t *
85 svn_wc__adm_access_pool_internal(const svn_wc_adm_access_t *adm_access);
86
87 #ifdef __cplusplus
88 }
89 #endif /* __cplusplus */
90
91 #endif /* SVN_LIBSVN_WC_LOCK_H */