Subversion 1.6.16
|
00001 /** 00002 * @copyright 00003 * ==================================================================== 00004 * Copyright (c) 2000-2007 CollabNet. All rights reserved. 00005 * 00006 * This software is licensed as described in the file COPYING, which 00007 * you should have received as part of this distribution. The terms 00008 * are also available at http://subversion.tigris.org/license-1.html. 00009 * If newer versions of this license are posted there, you may use a 00010 * newer version instead, at your option. 00011 * 00012 * This software consists of voluntary contributions made by many 00013 * individuals. For exact contribution history, see the revision 00014 * history and logs, available at http://subversion.tigris.org/. 00015 * ==================================================================== 00016 * @endcopyright 00017 * 00018 * @file svn_dav.h 00019 * @brief Code related to WebDAV/DeltaV usage in Subversion. 00020 */ 00021 00022 00023 00024 00025 #ifndef SVN_DAV_H 00026 #define SVN_DAV_H 00027 00028 00029 #ifdef __cplusplus 00030 extern "C" { 00031 #endif /* __cplusplus */ 00032 00033 00034 /** This is the MIME type that Subversion uses for its "svndiff" format. 00035 * 00036 * This is an application type, for the "svn" vendor. The specific subtype 00037 * is "svndiff". 00038 */ 00039 #define SVN_SVNDIFF_MIME_TYPE "application/vnd.svn-svndiff" 00040 00041 00042 /** This header is *TEMPORARILY* used to transmit the delta base to the 00043 * server. It contains a version resource URL for what is on the client. 00044 */ 00045 #define SVN_DAV_DELTA_BASE_HEADER "X-SVN-VR-Base" 00046 00047 /** This header is used when an svn client wants to trigger specific 00048 * svn server behaviors. Normal WebDAV or DeltaV clients won't use it. 00049 */ 00050 #define SVN_DAV_OPTIONS_HEADER "X-SVN-Options" 00051 00052 /** 00053 * @name options-header defines 00054 * Specific options that can appear in the options-header: 00055 * @{ 00056 */ 00057 #define SVN_DAV_OPTION_NO_MERGE_RESPONSE "no-merge-response" 00058 #define SVN_DAV_OPTION_LOCK_BREAK "lock-break" 00059 #define SVN_DAV_OPTION_LOCK_STEAL "lock-steal" 00060 #define SVN_DAV_OPTION_RELEASE_LOCKS "release-locks" 00061 #define SVN_DAV_OPTION_KEEP_LOCKS "keep-locks" 00062 /** @} */ 00063 00064 /** This header is used when an svn client wants to tell mod_dav_svn 00065 * exactly what revision of a resource it thinks it's operating on. 00066 * (For example, an svn server can use it to validate a DELETE request.) 00067 * Normal WebDAV or DeltaV clients won't use it. 00068 */ 00069 #define SVN_DAV_VERSION_NAME_HEADER "X-SVN-Version-Name" 00070 00071 /** A header generated by mod_dav_svn whenever it responds 00072 successfully to a LOCK request. Only svn clients will notice it, 00073 and use it to fill in svn_lock_t->creation_date. */ 00074 #define SVN_DAV_CREATIONDATE_HEADER "X-SVN-Creation-Date" 00075 00076 /** A header generated by mod_dav_svn whenever it responds 00077 successfully to a PROPFIND for the 'DAV:lockdiscovery' property. 00078 Only svn clients will notice it, and use it to fill in 00079 svn_lock_t->owner. (Remember that the DAV:owner field maps to 00080 svn_lock_t->comment, and that there is no analogue in the DAV 00081 universe of svn_lock_t->owner.) */ 00082 #define SVN_DAV_LOCK_OWNER_HEADER "X-SVN-Lock-Owner" 00083 00084 00085 /** 00086 * @name Fulltext MD5 headers 00087 * 00088 * These headers are for client and server to verify that the base 00089 * and the result of a change transmission are the same on both 00090 * sides, regardless of what transformations (svndiff deltification, 00091 * gzipping, etc) the data may have gone through in between. 00092 * 00093 * The result md5 is always used whenever file contents are 00094 * transferred, because every transmission has a resulting text. 00095 * 00096 * The base md5 is used to verify the base text against which svndiff 00097 * data is being applied. Note that even for svndiff transmissions, 00098 * base verification is not strictly necessary (and may therefore be 00099 * unimplemented), as any error will be caught by the verification of 00100 * the final result. However, if the problem is that the base text is 00101 * corrupt, the error will be caught earlier if the base md5 is used. 00102 * 00103 * Normal WebDAV or DeltaV clients don't use these. 00104 * @{ 00105 */ 00106 #define SVN_DAV_BASE_FULLTEXT_MD5_HEADER "X-SVN-Base-Fulltext-MD5" 00107 #define SVN_DAV_RESULT_FULLTEXT_MD5_HEADER "X-SVN-Result-Fulltext-MD5" 00108 /** @} */ 00109 00110 /* ### should add strings for the various XML elements in the reports 00111 ### and things. also the custom prop names. etc. 00112 */ 00113 00114 /** The svn-specific object that is placed within a <D:error> response. 00115 * 00116 * @defgroup svn_dav_error Errors in svn_dav 00117 * @{ */ 00118 00119 /** The error object's namespace */ 00120 #define SVN_DAV_ERROR_NAMESPACE "svn:" 00121 00122 /** The error object's tag */ 00123 #define SVN_DAV_ERROR_TAG "error" 00124 00125 /** @} */ 00126 00127 00128 /** General property (xml) namespaces that will be used by both ra_dav 00129 * and mod_dav_svn for marshalling properties. 00130 * 00131 * @defgroup svn_dav_property_xml_namespaces DAV property namespaces 00132 * @{ 00133 */ 00134 00135 /** A property stored in the fs and wc, begins with 'svn:', and is 00136 * interpreted either by client or server. 00137 */ 00138 #define SVN_DAV_PROP_NS_SVN "http://subversion.tigris.org/xmlns/svn/" 00139 00140 /** A property stored in the fs and wc, but totally ignored by svn 00141 * client and server. 00142 * 00143 * A property simply invented by the users. 00144 */ 00145 #define SVN_DAV_PROP_NS_CUSTOM "http://subversion.tigris.org/xmlns/custom/" 00146 00147 /** A property purely generated and consumed by the network layer, not 00148 * seen by either fs or wc. 00149 */ 00150 #define SVN_DAV_PROP_NS_DAV "http://subversion.tigris.org/xmlns/dav/" 00151 00152 00153 /** 00154 * @name Custom (extension) values for the DAV header. 00155 * Note that although these share the SVN_DAV_PROP_NS_DAV namespace 00156 * prefix, they are not properties; they are header values. 00157 * 00158 * @{ **/ 00159 00160 /** Presence of this in a DAV header in an OPTIONS request or response 00161 * indicates that the transmitter supports @c svn_depth_t. */ 00162 #define SVN_DAV_NS_DAV_SVN_DEPTH SVN_DAV_PROP_NS_DAV "svn/depth" 00163 00164 /** Presence of this in a DAV header in an OPTIONS request or response 00165 * indicates that the server knows how to handle merge-tracking 00166 * information. 00167 * 00168 * Note that this says nothing about whether the repository can handle 00169 * mergeinfo, only whether the server does. For more information, see 00170 * mod_dav_svn/version.c:get_vsn_options(). 00171 */ 00172 #define SVN_DAV_NS_DAV_SVN_MERGEINFO SVN_DAV_PROP_NS_DAV "svn/mergeinfo" 00173 00174 /** Presence of this in a DAV header in an OPTIONS response indicates 00175 * that the transmitter (in this case, the server) knows how to send 00176 * custom revprops in log responses. */ 00177 #define SVN_DAV_NS_DAV_SVN_LOG_REVPROPS SVN_DAV_PROP_NS_DAV "svn/log-revprops" 00178 00179 /** Presence of this in a DAV header in an OPTIONS response indicates 00180 * that the transmitter (in this case, the server) knows how to handle 00181 * a replay of a directory in the repository (not root). */ 00182 #define SVN_DAV_NS_DAV_SVN_PARTIAL_REPLAY\ 00183 SVN_DAV_PROP_NS_DAV "svn/partial-replay" 00184 00185 /** @} */ 00186 00187 /** @} */ 00188 00189 #ifdef __cplusplus 00190 } 00191 #endif /* __cplusplus */ 00192 00193 #endif /* SVN_DAV_H */