4
* ====================================================================
5
* Copyright (c) 2000-2004 CollabNet. All rights reserved.
7
* This software is licensed as described in the file COPYING, which
8
* you should have received as part of this distribution. The terms
9
* are also available at http://subversion.tigris.org/license-1.html.
10
* If newer versions of this license are posted there, you may use a
11
* newer version instead, at your option.
13
* This software consists of voluntary contributions made by many
14
* individuals. For exact contribution history, see the revision
15
* history and logs, available at http://subversion.tigris.org/.
16
* ====================================================================
20
#ifndef SVN_LIBSVN_WC_PROPS_H
21
#define SVN_LIBSVN_WC_PROPS_H
23
#include <apr_pools.h>
24
#include "svn_types.h"
25
#include "svn_string.h"
26
#include "svn_props.h"
31
#endif /* __cplusplus */
34
/* If the working item at PATH has properties attached, set HAS_PROPS.
35
ADM_ACCESS is an access baton set that contains PATH. */
36
svn_error_t *svn_wc__has_props (svn_boolean_t *has_props,
38
svn_wc_adm_access_t *adm_access,
43
/* Given two propchange objects, return TRUE iff they conflict. If
44
there's a conflict, DESCRIPTION will contain an english description
47
/* For note, here's the table being implemented:
49
| update set | update delete |
50
------------|-----------------|--------------------|
51
user set | conflict iff | conflict |
53
------------|-----------------|--------------------|
54
user delete | conflict | merge |
56
----------------------------------------------------
60
svn_wc__conflicting_propchanges_p (const svn_string_t **description,
61
const svn_prop_t *local,
62
const svn_prop_t *update,
65
/* Look up the entry NAME within ADM_ACCESS and see if it has a `current'
66
reject file describing a state of conflict. If such a file exists,
67
return the name of the file in REJECT_FILE. If no such file exists,
68
return (REJECT_FILE = NULL). */
70
svn_wc__get_existing_prop_reject_file (const char **reject_file,
71
svn_wc_adm_access_t *adm_access,
75
/* If PROPFILE_PATH exists (and is a file), assume it's full of
76
properties and load this file into HASH. Otherwise, leave HASH
78
svn_error_t *svn_wc__load_prop_file (const char *propfile_path,
84
/* Given a HASH full of property name/values, write them to a file
85
located at PROPFILE_PATH */
86
svn_error_t *svn_wc__save_prop_file (const char *propfile_path,
91
/* Given ADM_ACCESS/NAME and an array of PROPCHANGES, merge the changes into
92
the working copy. Necessary log entries will be appended to
95
If we are attempting to merge changes to a directory, simply pass
96
ADM_ACCESS and NULL for NAME.
98
If BASE_MERGE is FALSE only the working properties will be changed,
99
if it is TRUE both the base and working properties will be changed.
101
If conflicts are found when merging, they are placed into a
102
temporary .prej file within SVN. Log entries are then written to
103
move this file into PATH, or to append the conflicts to the file's
104
already-existing .prej file in ADM_ACCESS. Base properties are modifed
105
unconditionally, if BASE_MERGE is TRUE, they do not generate conficts.
107
If STATE is non-null, set *STATE to the state of the local properties
109
svn_error_t *svn_wc__merge_prop_diffs (svn_wc_notify_state_t *state,
110
svn_wc_adm_access_t *adm_access,
112
const apr_array_header_t *propchanges,
113
svn_boolean_t base_merge,
114
svn_boolean_t dry_run,
116
svn_stringbuf_t **entry_accum);
119
/* Get a single 'wcprop' NAME for versioned object PATH, return in
120
*VALUE. ADM_ACCESS is an access baton set that contains PATH. */
121
svn_error_t *svn_wc__wcprop_get (const svn_string_t **value,
124
svn_wc_adm_access_t *adm_access,
127
/* Set a single 'wcprop' NAME to VALUE for versioned object PATH.
128
If VALUE is null, remove property NAME. ADM_ACCESS is an access
129
baton set that contains PATH. */
130
svn_error_t *svn_wc__wcprop_set (const char *name,
131
const svn_string_t *value,
133
svn_wc_adm_access_t *adm_access,
136
/* Remove all wc properties under ADM_ACCESS, recursively. Do any
137
temporary allocation in POOL. */
138
svn_error_t *svn_wc__remove_wcprops (svn_wc_adm_access_t *adm_access,
139
svn_boolean_t recurse,
145
#endif /* __cplusplus */
147
#endif /* SVN_LIBSVN_WC_PROPS_H */