svn_user.h revision 362181
1/**
2 * @copyright
3 * ====================================================================
4 *    Licensed to the Apache Software Foundation (ASF) under one
5 *    or more contributor license agreements.  See the NOTICE file
6 *    distributed with this work for additional information
7 *    regarding copyright ownership.  The ASF licenses this file
8 *    to you under the Apache License, Version 2.0 (the
9 *    "License"); you may not use this file except in compliance
10 *    with the License.  You may obtain a copy of the License at
11 *
12 *      http://www.apache.org/licenses/LICENSE-2.0
13 *
14 *    Unless required by applicable law or agreed to in writing,
15 *    software distributed under the License is distributed on an
16 *    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
17 *    KIND, either express or implied.  See the License for the
18 *    specific language governing permissions and limitations
19 *    under the License.
20 * ====================================================================
21 * @endcopyright
22 *
23 * @file svn_user.h
24 * @brief Subversion's wrapper around APR's user information interface.
25 */
26
27#ifndef SVN_USER_H
28#define SVN_USER_H
29
30#include <apr_pools.h>
31
32#ifdef __cplusplus
33extern "C" {
34#endif /* __cplusplus */
35
36/** Get the name of the current user, using @a pool for any necessary
37 * allocation, returning NULL on error.
38 *
39 * @since New in 1.4.
40 */
41const char *
42svn_user_get_name(apr_pool_t *pool);
43
44/** Get the path of the current user's home directory, using @a pool for
45 * any necessary allocation, returning NULL on error.
46 *
47 * @since New in 1.4.
48 * @since 1.10 returns a canonical path. Earlier versions returned a
49 * non-canonical path if the operating system reported a non-canonical
50 * path such as "/home/user/" or "//home/user".
51 */
52const char *
53svn_user_get_homedir(apr_pool_t *pool);
54
55#ifdef __cplusplus
56}
57#endif /* __cplusplus */
58
59#endif /* SVN_USER_H */
60