2 * blncache.h: DAV baseline information cache.
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
13 * http://www.apache.org/licenses/LICENSE-2.0
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
21 * ====================================================================
24 #ifndef SVN_LIBSVN_RA_SERF_BLNCACHE_H
25 #define SVN_LIBSVN_RA_SERF_BLNCACHE_H
27 #include <apr_pools.h>
29 #include "svn_types.h"
33 #endif /* __cplusplus */
35 /* Baseline information cache. Baseline information cache holds information
36 * about DAV baseline (bln):
37 * 1. URL of the baseline (bln)
38 * 2. Revision number associated with baseline
39 * 3. URL of baseline collection (bc).
41 typedef struct svn_ra_serf__blncache_t svn_ra_serf__blncache_t;
43 /* Creates new instance of baseline cache. Sets BLNCACHE_P with
44 * a pointer to new instance, allocated in POOL.
47 svn_ra_serf__blncache_create(svn_ra_serf__blncache_t **blncache_p,
50 /* Add information about baseline. BLNCACHE is a pointer to
51 * baseline cache previously created using svn_ra_serf__blncache_create
52 * function. BASELINE_URL is URL of baseline (can be NULL if unknown).
53 * REVNUM is revision number associated with baseline. Use SVN_INVALID_REVNUM
54 * to indicate that revision is unknown.
55 * BC_URL is URL of baseline collection (can be NULL if unknwon).
58 svn_ra_serf__blncache_set(svn_ra_serf__blncache_t *blncache,
59 const char *baseline_url,
64 /* Sets *BC_URL_P with a pointer to baseline collection URL for the given
65 * REVNUM. *BC_URL_P will be NULL if cache doesn't have information about
69 svn_ra_serf__blncache_get_bc_url(const char **bc_url_p,
70 svn_ra_serf__blncache_t *blncache,
74 /* Sets *BC_URL_P with pointer to baseline collection URL and *REVISION_P
75 * with revision number of baseline BASELINE_URL. *BC_URL_P will be NULL,
76 * *REVNUM_P will SVN_INVALID_REVNUM if cache doesn't have such
80 svn_ra_serf__blncache_get_baseline_info(const char **bc_url_p,
81 svn_revnum_t *revnum_p,
82 svn_ra_serf__blncache_t *blncache,
83 const char *baseline_url,
88 #endif /* __cplusplus */
90 #endif /* SVN_LIBSVN_RA_SERF_BLNCACHE_H*/