]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/blob - contrib/subversion/subversion/libsvn_subr/win32_xlate.h
MFC r275385 (by bapt):
[FreeBSD/stable/10.git] / contrib / subversion / subversion / libsvn_subr / win32_xlate.h
1 /*
2  * win32_xlate.h : Windows xlate stuff.
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 #ifndef SVN_LIBSVN_SUBR_WIN32_XLATE_H
25 #define SVN_LIBSVN_SUBR_WIN32_XLATE_H
26
27 #ifdef WIN32
28
29 /* Opaque translation buffer. */
30 typedef struct svn_subr__win32_xlate_t svn_subr__win32_xlate_t;
31
32 /* Set *XLATE_P to a handle node for converting from FROMPAGE to TOPAGE.
33    Returns APR_EINVAL or APR_ENOTIMPL, if a conversion isn't supported.
34    If fail for any other reason, return the error.
35
36    Allocate *RET in POOL. */
37 apr_status_t
38 svn_subr__win32_xlate_open(svn_subr__win32_xlate_t **xlate_p,
39                            const char *topage,
40                            const char *frompage,
41                            apr_pool_t *pool);
42
43 /* Convert SRC_LENGTH bytes of SRC_DATA in NODE->handle, store the result
44    in *DEST, which is allocated in POOL. */
45 apr_status_t
46 svn_subr__win32_xlate_to_stringbuf(svn_subr__win32_xlate_t *handle,
47                                    const char *src_data,
48                                    apr_size_t src_length,
49                                    svn_stringbuf_t **dest,
50                                    apr_pool_t *pool);
51
52 #endif /* WIN32 */
53
54 #endif /* SVN_LIBSVN_SUBR_WIN32_XLATE_H */