Subversion
svn_types.h
Go to the documentation of this file.
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_types.h
24  * @brief Subversion's data types
25  */
26 
27 #ifndef SVN_TYPES_H
28 #define SVN_TYPES_H
29 
30 #include "svn_types_impl.h"
31 
32 /* ### this should go away, but it causes too much breakage right now */
33 #include <stdlib.h>
34 #include <limits.h> /* for ULONG_MAX */
35 
36 #include <apr.h> /* for apr_size_t, apr_int64_t, ... */
37 #include <apr_version.h>
38 #include <apr_errno.h> /* for apr_status_t */
39 #include <apr_pools.h> /* for apr_pool_t */
40 #include <apr_hash.h> /* for apr_hash_t */
41 #include <apr_tables.h> /* for apr_array_push() */
42 #include <apr_time.h> /* for apr_time_t */
43 #include <apr_strings.h> /* for apr_atoi64() */
44 
45 #ifdef __cplusplus
46 extern "C" {
47 #endif /* __cplusplus */
48 
49 
50 ␌
51 /** Macro used to mark deprecated functions.
52  *
53  * @since New in 1.6.
54  */
55 #ifndef SVN_DEPRECATED
56 # if !defined(SWIGPERL) && !defined(SWIGPYTHON) && !defined(SWIGRUBY)
57 # if defined(__GNUC__) && (__GNUC__ >= 4 || (__GNUC__==3 && __GNUC_MINOR__>=1))
58 # define SVN_DEPRECATED __attribute__((deprecated))
59 # elif defined(_MSC_VER) && _MSC_VER >= 1300
60 # define SVN_DEPRECATED __declspec(deprecated)
61 # else
62 # define SVN_DEPRECATED
63 # endif
64 # else
65 # define SVN_DEPRECATED
66 # endif
67 #endif
68 
69 ␌
70 /** Macro used to mark experimental functions.
71  *
72  * @since New in 1.9.
73  */
74 #ifndef SVN_EXPERIMENTAL
75 # if !defined(SWIGPERL) && !defined(SWIGPYTHON) && !defined(SWIGRUBY)
76 # if defined(__has_attribute)
77 # if __has_attribute(__warning__)
78 # define SVN_EXPERIMENTAL __attribute__((warning("experimental function used")))
79 # else
80 # define SVN_EXPERIMENTAL
81 # endif
82 # elif !defined(__llvm__) && defined(__GNUC__) \
83  && (__GNUC__ >= 4 || (__GNUC__==3 && __GNUC_MINOR__>=1))
84 # define SVN_EXPERIMENTAL __attribute__((warning("experimental function used")))
85 # elif defined(_MSC_VER) && _MSC_VER >= 1300
86 # define SVN_EXPERIMENTAL __declspec(deprecated("experimental function used"))
87 # else
88 # define SVN_EXPERIMENTAL
89 # endif
90 # else
91 # define SVN_EXPERIMENTAL
92 # endif
93 #endif
94 
95 /** Macro used to mark functions that require a final null sentinel argument.
96  *
97  * @since New in 1.9.
98  */
99 #ifndef SVN_NEEDS_SENTINEL_NULL
100 # if defined(__has_attribute)
101 # if __has_attribute(__sentinel__)
102 # define SVN_NEEDS_SENTINEL_NULL __attribute__((sentinel))
103 # else
104 # define SVN_NEEDS_SENTINEL_NULL
105 # endif
106 # elif defined(__GNUC__) && (__GNUC__ >= 4)
107 # define SVN_NEEDS_SENTINEL_NULL __attribute__((sentinel))
108 # else
109 # define SVN_NEEDS_SENTINEL_NULL
110 # endif
111 #endif
112 
113 ␌
114 /** Indicate whether the current platform supports unaligned data access.
115  *
116  * On the majority of machines running SVN (x86 / x64), unaligned access
117  * is much cheaper than repeated aligned access. Define this macro to 1
118  * on those machines.
119  * Unaligned access on other machines (e.g. IA64) will trigger memory
120  * access faults or simply misbehave.
121  *
122  * Note: Some platforms may only support unaligned access for integers
123  * (PowerPC). As a result this macro should only be used to determine
124  * if unaligned access is supported for integers.
125  *
126  * @since New in 1.7.
127  * @deprecated Provided for backward compatibility with the 1.14 API.
128  */
129 #ifdef SVN_UNALIGNED_ACCESS_IS_OK
130 # undef SVN_UNALIGNED_ACCESS_IS_OK
131 #endif
132 #define SVN_UNALIGNED_ACCESS_IS_OK 0
133 
134 
135 ␌
136 /** YABT: Yet Another Boolean Type */
137 typedef int svn_boolean_t;
138 
139 #ifndef TRUE
140 /** uhh... true */
141 #define TRUE 1
142 #endif /* TRUE */
143 
144 #ifndef FALSE
145 /** uhh... false */
146 #define FALSE 0
147 #endif /* FALSE */
148 
149 
150 ␌
151 /* Declaration of a unique type, never defined, for the SVN_VA_NULL macro.
152  *
153  * NOTE: Private. Not for direct use by third-party code.
154  */
155 struct svn__null_pointer_constant_stdarg_sentinel_t;
156 
157 /** Null pointer constant used as a sentinel in variable argument lists.
158  *
159  * Use of this macro ensures that the argument is of the correct size when a
160  * pointer is expected. (The macro @c NULL is not defined as a pointer on
161  * all systems, and the arguments to variadic functions are not converted
162  * automatically to the expected type.)
163  *
164  * @since New in 1.9.
165  */
166 #define SVN_VA_NULL ((struct svn__null_pointer_constant_stdarg_sentinel_t*)0)
167 /* See? (char*)NULL -- They have the same length, but the cast looks ugly. */
168 
169 
170 ␌
171 /** Subversion error object.
172  *
173  * Defined here, rather than in svn_error.h, to avoid a recursive @#include
174  * situation.
175  */
176 typedef struct svn_error_t
177 {
178  /** APR error value; possibly an SVN_ custom error code (see
179  * `svn_error_codes.h' for a full listing).
180  */
181  apr_status_t apr_err;
182 
183  /** Details from the producer of error.
184  *
185  * Note that if this error was generated by Subversion's API, you'll
186  * probably want to use svn_err_best_message() to get a single
187  * descriptive string for this error chain (see the @a child member)
188  * or svn_handle_error2() to print the error chain in full. This is
189  * because Subversion's API functions sometimes add many links to
190  * the error chain that lack details (used only to produce virtual
191  * stack traces). (Use svn_error_purge_tracing() to remove those
192  * trace-only links from the error chain.)
193  */
194  const char *message;
195 
196  /** Pointer to the error we "wrap" (may be @c NULL). Via this
197  * member, individual error object can be strung together into an
198  * "error chain".
199  */
201 
202  /** The pool in which this error object is allocated. (If
203  * Subversion's APIs are used to manage error chains, then this pool
204  * will contain the whole error chain of which this object is a
205  * member.) */
206  apr_pool_t *pool;
207 
208  /** Source file where the error originated (iff @c SVN_DEBUG;
209  * undefined otherwise).
210  */
211  const char *file;
212 
213  /** Source line where the error originated (iff @c SVN_DEBUG;
214  * undefined otherwise).
215  */
216  long line;
217 
219 
220 
221 ␌
222 /* See svn_version.h.
223  Defined here to avoid including svn_version.h from all public headers. */
224 typedef struct svn_version_t svn_version_t;
225 
226 
227 ␌
228 /** @defgroup APR_ARRAY_compat_macros APR Array Compatibility Helper Macros
229  * These macros are provided by APR itself from version 1.3.
230  * Definitions are provided here for when using older versions of APR.
231  * @{
232  */
233 
234 /** index into an apr_array_header_t */
235 #ifndef APR_ARRAY_IDX
236 #define APR_ARRAY_IDX(ary,i,type) (((type *)(ary)->elts)[i])
237 #endif
238 
239 /** easier array-pushing syntax */
240 #ifndef APR_ARRAY_PUSH
241 #define APR_ARRAY_PUSH(ary,type) (*((type *)apr_array_push(ary)))
242 #endif
243 
244 /** @} */
245 
246 
247 ␌
248 /** @defgroup apr_hash_utilities APR Hash Table Helpers
249  * These functions enable the caller to dereference an APR hash table index
250  * without type casts or temporary variables.
251  *
252  * These functions are provided by APR itself from version 1.5.
253  * Definitions are provided here for when using older versions of APR.
254  * @{
255  */
256 
257 #if !APR_VERSION_AT_LEAST(1, 5, 0)
258 
259 /** Return the key of the hash table entry indexed by @a hi. */
260 const void *
261 apr_hash_this_key(apr_hash_index_t *hi);
262 
263 /** Return the key length of the hash table entry indexed by @a hi. */
264 apr_ssize_t
265 apr_hash_this_key_len(apr_hash_index_t *hi);
266 
267 /** Return the value of the hash table entry indexed by @a hi. */
268 void *
269 apr_hash_this_val(apr_hash_index_t *hi);
270 
271 #endif
272 
273 /** @} */
274 
275 
276 ␌
277 /** On Windows, APR_STATUS_IS_ENOTDIR includes several kinds of
278  * invalid-pathname error but not ERROR_INVALID_NAME, so we include it.
279  * We also include ERROR_DIRECTORY as that was not included in apr versions
280  * before 1.4.0 and this fix is not backported */
281 /* ### These fixes should go into APR. */
282 #ifndef WIN32
283 #define SVN__APR_STATUS_IS_ENOTDIR(s) APR_STATUS_IS_ENOTDIR(s)
284 #else
285 #define SVN__APR_STATUS_IS_ENOTDIR(s) (APR_STATUS_IS_ENOTDIR(s) \
286  || ((s) == APR_OS_START_SYSERR + ERROR_DIRECTORY) \
287  || ((s) == APR_OS_START_SYSERR + ERROR_INVALID_NAME))
288 #endif
289 
290 /** On Windows, APR_STATUS_IS_EPIPE does not include ERROR_NO_DATA error.
291  * So we include it.*/
292 /* ### These fixes should go into APR. */
293 #ifndef WIN32
294 #define SVN__APR_STATUS_IS_EPIPE(s) APR_STATUS_IS_EPIPE(s)
295 #else
296 #define SVN__APR_STATUS_IS_EPIPE(s) (APR_STATUS_IS_EPIPE(s) \
297  || ((s) == APR_OS_START_SYSERR + ERROR_NO_DATA))
298 #endif
299 
300 /** @} */
301 
302 
303 ␌
304 /* NOTE: svn_node_kind_t is defined in svn_types_impl.h */
305 
306 /** Return a constant string expressing @a kind as an English word, e.g.,
307  * "file", "dir", etc. The string is not localized, as it may be used for
308  * client<->server communications. If the kind is not recognized, return
309  * "unknown".
310  *
311  * @since New in 1.6.
312  */
313 const char *
315 
316 /** Return the appropriate node_kind for @a word. @a word is as
317  * returned from svn_node_kind_to_word(). If @a word does not
318  * represent a recognized kind or is @c NULL, return #svn_node_unknown.
319  *
320  * @since New in 1.6.
321  */
323 svn_node_kind_from_word(const char *word);
324 
325 ␌
326 /* NOTE: svn_tristate_t is defined in svn_types_impl.h */
327 
328 /** Return a constant string "true", "false" or NULL representing the value of
329  * @a tristate.
330  *
331  * @since New in 1.7.
332  */
333 const char *
335 
336 /** Return the appropriate tristate for @a word. If @a word is "true", returns
337  * #svn_tristate_true; if @a word is "false", returns #svn_tristate_false,
338  * for all other values (including NULL) returns #svn_tristate_unknown.
339  *
340  * @since New in 1.7.
341  */
343 svn_tristate__from_word(const char * word);
344 
345 
346 ␌
347 /** About Special Files in Subversion
348  *
349  * Subversion denotes files that cannot be portably created or
350  * modified as "special" files (svn_node_special). It stores these
351  * files in the repository as a plain text file with the svn:special
352  * property set. The file contents contain: a platform-specific type
353  * string, a space character, then any information necessary to create
354  * the file on a supported platform. For example, if a symbolic link
355  * were being represented, the repository file would have the
356  * following contents:
357  *
358  * "link /path/to/link/target"
359  *
360  * Where 'link' is the identifier string showing that this special
361  * file should be a symbolic link and '/path/to/link/target' is the
362  * destination of the symbolic link.
363  *
364  * Special files are stored in the text-base exactly as they are
365  * stored in the repository. The platform specific files are created
366  * in the working copy at EOL/keyword translation time using
367  * svn_subst_copy_and_translate2(). If the current platform does not
368  * support a specific special file type, the file is copied into the
369  * working copy as it is seen in the repository. Because of this,
370  * users of other platforms can still view and modify the special
371  * files, even if they do not have their unique properties.
372  *
373  * New types of special files can be added by:
374  * 1. Implementing a platform-dependent routine to create a uniquely
375  * named special file and one to read the special file in
376  * libsvn_subr/io.c.
377  * 2. Creating a new textual name similar to
378  * SVN_SUBST__SPECIAL_LINK_STR in libsvn_subr/subst.c.
379  * 3. Handling the translation/detranslation case for the new type in
380  * create_special_file_from_stream and detranslate_special_file, using the
381  * routines from 1.
382  */
383 
384 
385 ␌
386 /* NOTE: svn_revnum_t and SVN_INVALID_REVNUM are defined in svn_types_impl.h */
387 
388 /** Valid revision numbers begin at 0 */
389 #define SVN_IS_VALID_REVNUM(n) ((n) >= 0)
390 
391 /** Not really invalid...just unimportant -- one day, this can be its
392  * own unique value, for now, just make it the same as
393  * #SVN_INVALID_REVNUM.
394  */
395 #define SVN_IGNORED_REVNUM ((svn_revnum_t) -1)
396 
397 /** Convert NULL-terminated C string @a str to a revision number. */
398 #define SVN_STR_TO_REV(str) ((svn_revnum_t) atol(str))
399 
400 /**
401  * Parse NULL-terminated C string @a str as a revision number and
402  * store its value in @a rev. If @a endptr is non-NULL, then the
403  * address of the first non-numeric character in @a str is stored in
404  * it. If there are no digits in @a str, then @a endptr is set (if
405  * non-NULL), and the error #SVN_ERR_REVNUM_PARSE_FAILURE error is
406  * returned. Negative numbers parsed from @a str are considered
407  * invalid, and result in the same error.
408  *
409  * @since New in 1.5.
410  */
411 svn_error_t *
413  const char *str,
414  const char **endptr);
415 
416 /** Originally intended to be used in printf()-style functions to format
417  * revision numbers. Deprecated due to incompatibilities with language
418  * translation tools (e.g. gettext).
419  *
420  * New code should use a bare "%ld" format specifier for formatting revision
421  * numbers.
422  *
423  * @deprecated Provided for backward compatibility with the 1.0 API.
424  */
425 #define SVN_REVNUM_T_FMT "ld"
426 
427 
428 ␌
429 /** The size of a file in the Subversion FS. */
430 typedef apr_int64_t svn_filesize_t;
431 
432 /** The 'official' invalid file size constant. */
433 #define SVN_INVALID_FILESIZE ((svn_filesize_t) -1)
434 
435 /** In printf()-style functions, format file sizes using this. */
436 #define SVN_FILESIZE_T_FMT APR_INT64_T_FMT
437 
438 #ifndef DOXYGEN_SHOULD_SKIP_THIS
439 /* Parse a base-10 numeric string into a 64-bit unsigned numeric value. */
440 /* NOTE: Private. For use by Subversion's own code only. See issue #1644. */
441 /* FIXME: APR should supply a function to do this, such as "apr_atoui64". */
442 #define svn__atoui64(X) ((apr_uint64_t) apr_atoi64(X))
443 #endif
444 
445 
446 ␌
447 /** An enum to indicate whether recursion is needed. */
449 {
450  svn_nonrecursive = 1,
451  svn_recursive
452 };
453 
454 /* NOTE: svn_depth_t is defined in svn_types_impl.h */
455 
456 /** Return a constant string expressing @a depth as an English word,
457  * e.g., "infinity", "immediates", etc. The string is not localized,
458  * as it may be used for client<->server communications.
459  *
460  * @since New in 1.5.
461  */
462 const char *
464 
465 /** Return the appropriate depth for @a depth_str. @a word is as
466  * returned from svn_depth_to_word(). If @a depth_str does not
467  * represent a recognized depth, return #svn_depth_unknown.
468  *
469  * @since New in 1.5.
470  */
472 svn_depth_from_word(const char *word);
473 
474 /** Return #svn_depth_infinity if boolean @a recurse is TRUE, else
475  * return #svn_depth_files.
476  *
477  * @note New code should never need to use this, it is called only
478  * from pre-depth APIs, for compatibility.
479  *
480  * @since New in 1.5.
481  */
482 #define SVN_DEPTH_INFINITY_OR_FILES(recurse) \
483  ((recurse) ? svn_depth_infinity : svn_depth_files)
484 
485 /** Return #svn_depth_infinity if boolean @a recurse is TRUE, else
486  * return #svn_depth_immediates.
487  *
488  * @note New code should never need to use this, it is called only
489  * from pre-depth APIs, for compatibility.
490  *
491  * @since New in 1.5.
492  */
493 #define SVN_DEPTH_INFINITY_OR_IMMEDIATES(recurse) \
494  ((recurse) ? svn_depth_infinity : svn_depth_immediates)
495 
496 /** Return #svn_depth_infinity if boolean @a recurse is TRUE, else
497  * return #svn_depth_empty.
498  *
499  * @note New code should never need to use this, it is called only
500  * from pre-depth APIs, for compatibility.
501  *
502  * @since New in 1.5.
503  */
504 #define SVN_DEPTH_INFINITY_OR_EMPTY(recurse) \
505  ((recurse) ? svn_depth_infinity : svn_depth_empty)
506 
507 /** Return a recursion boolean based on @a depth.
508  *
509  * Although much code has been converted to use depth, some code still
510  * takes a recurse boolean. In most cases, it makes sense to treat
511  * unknown or infinite depth as recursive, and any other depth as
512  * non-recursive (which in turn usually translates to #svn_depth_files).
513  */
514 #define SVN_DEPTH_IS_RECURSIVE(depth) \
515  ((depth) == svn_depth_infinity || (depth) == svn_depth_unknown)
516 
517 
518 ␌
519 /**
520  * It is sometimes convenient to indicate which parts of an #svn_dirent_t
521  * object you are actually interested in, so that calculating and sending
522  * the data corresponding to the other fields can be avoided. These values
523  * can be used for that purpose.
524  *
525  * @defgroup svn_dirent_fields Dirent fields
526  * @{
527  */
528 
529 /** An indication that you are interested in the @c kind field */
530 #define SVN_DIRENT_KIND 0x00001
531 
532 /** An indication that you are interested in the @c size field */
533 #define SVN_DIRENT_SIZE 0x00002
534 
535 /** An indication that you are interested in the @c has_props field */
536 #define SVN_DIRENT_HAS_PROPS 0x00004
537 
538 /** An indication that you are interested in the @c created_rev field */
539 #define SVN_DIRENT_CREATED_REV 0x00008
540 
541 /** An indication that you are interested in the @c time field */
542 #define SVN_DIRENT_TIME 0x00010
543 
544 /** An indication that you are interested in the @c last_author field */
545 #define SVN_DIRENT_LAST_AUTHOR 0x00020
546 
547 /** A combination of all the dirent fields */
548 #define SVN_DIRENT_ALL ~((apr_uint32_t ) 0)
549 
550 /** @} */
551 
552 /** A general subversion directory entry.
553  *
554  * @note To allow for extending the #svn_dirent_t structure in future
555  * releases, always use svn_dirent_create() to allocate the structure.
556  *
557  * @since New in 1.6.
558  */
559 typedef struct svn_dirent_t
560 {
561  /** node kind */
563 
564  /** length of file text, otherwise SVN_INVALID_FILESIZE */
566 
567  /** does the node have props? */
569 
570  /** last rev in which this node changed */
572 
573  /** time of created_rev (mod-time) */
574  apr_time_t time;
575 
576  /** author of created_rev */
577  const char *last_author;
578 
579  /* IMPORTANT: If you extend this struct, check svn_dirent_dup(). */
581 
582 /** Return a deep copy of @a dirent, allocated in @a pool.
583  *
584  * @since New in 1.4.
585  */
586 svn_dirent_t *
588  apr_pool_t *pool);
589 
590 /**
591  * Create a new svn_dirent_t instance with all values initialized to their
592  * not-available values.
593  *
594  * @since New in 1.8.
595  */
596 svn_dirent_t *
597 svn_dirent_create(apr_pool_t *result_pool);
598 
599 ␌
600 /** Keyword substitution.
601  *
602  * All the keywords Subversion recognizes.
603  *
604  * Note that there is a better, more general proposal out there, which
605  * would take care of both internationalization issues and custom
606  * keywords (e.g., $NetBSD$). See
607  *
608  * @verbatim
609  https://svn.haxx.se/dev/archive-2001-12/0479.shtml
610  =====
611  From: "Jonathan M. Manning" <jmanning@alisa-jon.net>
612  To: dev@subversion.tigris.org
613  Date: Fri, 14 Dec 2001 11:56:54 -0500
614  Message-ID: <87970000.1008349014@bdldevel.bl.bdx.com>
615  Subject: Re: keywords @endverbatim
616  *
617  * and Eric Gillespie's support of same:
618  *
619  * @verbatim
620  https://svn.haxx.se/dev/archive-2001-12/0315.shtml
621  =====
622  From: "Eric Gillespie, Jr." <epg@pretzelnet.org>
623  To: dev@subversion.tigris.org
624  Date: Wed, 12 Dec 2001 09:48:42 -0500
625  Message-ID: <87k7vsebp1.fsf@vger.pretzelnet.org>
626  Subject: Re: Customizable Keywords @endverbatim
627  *
628  * However, it is considerably more complex than the scheme below.
629  * For now we're going with simplicity, hopefully the more general
630  * solution can be done post-1.0.
631  *
632  * @defgroup svn_types_keywords Keyword definitions
633  * @{
634  */
635 
636 /** The maximum size of an expanded or un-expanded keyword. */
637 #define SVN_KEYWORD_MAX_LEN 255
638 
639 /** The most recent revision in which this file was changed. */
640 #define SVN_KEYWORD_REVISION_LONG "LastChangedRevision"
641 
642 /** Short version of LastChangedRevision */
643 #define SVN_KEYWORD_REVISION_SHORT "Rev"
644 
645 /** Medium version of LastChangedRevision, matching the one CVS uses.
646  * @since New in 1.1. */
647 #define SVN_KEYWORD_REVISION_MEDIUM "Revision"
648 
649 /** The most recent date (repository time) when this file was changed. */
650 #define SVN_KEYWORD_DATE_LONG "LastChangedDate"
651 
652 /** Short version of LastChangedDate */
653 #define SVN_KEYWORD_DATE_SHORT "Date"
654 
655 /** Who most recently committed to this file. */
656 #define SVN_KEYWORD_AUTHOR_LONG "LastChangedBy"
657 
658 /** Short version of LastChangedBy */
659 #define SVN_KEYWORD_AUTHOR_SHORT "Author"
660 
661 /** The URL for the head revision of this file. */
662 #define SVN_KEYWORD_URL_LONG "HeadURL"
663 
664 /** Short version of HeadURL */
665 #define SVN_KEYWORD_URL_SHORT "URL"
666 
667 /** A compressed combination of the other four keywords. */
668 #define SVN_KEYWORD_ID "Id"
669 
670 /** A full combination of the first four keywords.
671  * @since New in 1.6. */
672 #define SVN_KEYWORD_HEADER "Header"
673 
674 /** @} */
675 
676 
677 ␌
678 /** All information about a commit.
679  *
680  * @note Objects of this type should always be created using the
681  * svn_create_commit_info() function.
682  *
683  * @since New in 1.3.
684  */
685 typedef struct svn_commit_info_t
686 {
687  /** just-committed revision. */
689 
690  /** server-side date of the commit. */
691  const char *date;
692 
693  /** author of the commit. */
694  const char *author;
695 
696  /** error message from post-commit hook, or NULL. */
697  const char *post_commit_err;
698 
699  /** repository root, may be @c NULL if unknown.
700  @since New in 1.7. */
701  const char *repos_root;
702 
704 
705 /**
706  * Allocate an object of type #svn_commit_info_t in @a pool and
707  * return it.
708  *
709  * The @c revision field of the new struct is set to #SVN_INVALID_REVNUM.
710  * All other fields are initialized to @c NULL.
711  *
712  * @note Any object of the type #svn_commit_info_t should
713  * be created using this function.
714  * This is to provide for extending the svn_commit_info_t in
715  * the future.
716  *
717  * @since New in 1.3.
718  */
720 svn_create_commit_info(apr_pool_t *pool);
721 
722 /**
723  * Return a deep copy @a src_commit_info allocated in @a pool.
724  *
725  * @since New in 1.4.
726  */
728 svn_commit_info_dup(const svn_commit_info_t *src_commit_info,
729  apr_pool_t *pool);
730 
731 
732 ␌
733 /**
734  * A structure to represent a path that changed for a log entry.
735  *
736  * @note To allow for extending the #svn_log_changed_path2_t structure in
737  * future releases, always use svn_log_changed_path2_create() to allocate
738  * the structure.
739  *
740  * @since New in 1.6.
741  */
743 {
744  /** 'A'dd, 'D'elete, 'R'eplace, 'M'odify */
745  char action;
746 
747  /** Source path of copy (if any). */
748  const char *copyfrom_path;
749 
750  /** Source revision of copy (if any). */
752 
753  /** The type of the node, may be svn_node_unknown. */
755 
756  /** Is the text modified, may be svn_tristate_unknown.
757  * @since New in 1.7. */
759 
760  /** Are properties modified, may be svn_tristate_unknown.
761  * @since New in 1.7. */
763 
764  /* NOTE: Add new fields at the end to preserve binary compatibility.
765  Also, if you add fields here, you have to update
766  svn_log_changed_path2_dup(). */
768 
769 /**
770  * Returns an #svn_log_changed_path2_t, allocated in @a pool with all fields
771  * initialized to NULL, None or empty values.
772  *
773  * @note To allow for extending the #svn_log_changed_path2_t structure in
774  * future releases, this function should always be used to allocate the
775  * structure.
776  *
777  * @since New in 1.6.
778  */
781 
782 /**
783  * Return a deep copy of @a changed_path, allocated in @a pool.
784  *
785  * @since New in 1.6.
786  */
789  apr_pool_t *pool);
790 
791 /**
792  * A structure to represent a path that changed for a log entry. Same as
793  * the first three fields of #svn_log_changed_path2_t.
794  *
795  * @deprecated Provided for backward compatibility with the 1.5 API.
796  */
798 {
799  /** 'A'dd, 'D'elete, 'R'eplace, 'M'odify */
800  char action;
801 
802  /** Source path of copy (if any). */
803  const char *copyfrom_path;
804 
805  /** Source revision of copy (if any). */
807 
809 
810 /**
811  * Return a deep copy of @a changed_path, allocated in @a pool.
812  *
813  * @since New in 1.3.
814  * @deprecated Provided for backward compatibility with the 1.5 API.
815  */
819  apr_pool_t *pool);
820 
821 /**
822  * A structure to represent all the information about a particular log entry.
823  *
824  * @note To allow for extending the #svn_log_entry_t structure in future
825  * releases, always use svn_log_entry_create() to allocate the structure.
826  *
827  * @since New in 1.5.
828  */
829 typedef struct svn_log_entry_t
830 {
831  /** A hash containing as keys every path committed in @a revision; the
832  * values are (#svn_log_changed_path_t *) structures.
833  *
834  * The subversion core libraries will always set this field to the same
835  * value as changed_paths2 for compatibility reasons.
836  *
837  * @deprecated Provided for backward compatibility with the 1.5 API.
838  */
839  apr_hash_t *changed_paths;
840 
841  /** The revision of the commit. */
843 
844  /** The hash of requested revision properties, which may be NULL if it
845  * would contain no revprops. Maps (const char *) property name to
846  * (svn_string_t *) property value. */
847  apr_hash_t *revprops;
848 
849  /**
850  * Whether or not this message has children.
851  *
852  * When a log operation requests additional merge information, extra log
853  * entries may be returned as a result of this entry. The new entries, are
854  * considered children of the original entry, and will follow it. When
855  * the HAS_CHILDREN flag is set, the receiver should increment its stack
856  * depth, and wait until an entry is provided with SVN_INVALID_REVNUM which
857  * indicates the end of the children.
858  *
859  * For log operations which do not request additional merge information, the
860  * HAS_CHILDREN flag is always FALSE.
861  *
862  * For more information see:
863  * https://svn.apache.org/repos/asf/subversion/trunk/notes/merge-tracking/design.html#commutative-reporting
864  */
866 
867  /** A hash containing as keys every path committed in @a revision; the
868  * values are (#svn_log_changed_path2_t *) structures.
869  *
870  * If this value is not @c NULL, it MUST have the same value as
871  * changed_paths or svn_log_entry_dup() will not create an identical copy.
872  *
873  * The subversion core libraries will always set this field to the same
874  * value as changed_paths for compatibility with users assuming an older
875  * version.
876  *
877  * @note See https://svn.haxx.se/dev/archive-2010-08/0362.shtml for
878  * further explanation.
879  *
880  * @since New in 1.6.
881  */
882  apr_hash_t *changed_paths2;
883 
884  /**
885  * Whether @a revision should be interpreted as non-inheritable in the
886  * same sense of #svn_merge_range_t.
887  *
888  * Only set when this #svn_log_entry_t instance is returned by the
889  * libsvn_client mergeinfo apis. Currently always FALSE when the
890  * #svn_log_entry_t instance is reported by the ra layer.
891  *
892  * @since New in 1.7.
893  */
895 
896  /**
897  * Whether @a revision is a merged revision resulting from a reverse merge.
898  *
899  * @since New in 1.7.
900  */
902 
903  /* NOTE: Add new fields at the end to preserve binary compatibility.
904  Also, if you add fields here, you have to update
905  svn_log_entry_dup(). */
907 
908 /**
909  * Returns an #svn_log_entry_t, allocated in @a pool with all fields
910  * initialized to NULL values.
911  *
912  * @note To allow for extending the #svn_log_entry_t structure in future
913  * releases, this function should always be used to allocate the structure.
914  *
915  * @since New in 1.5.
916  */
918 svn_log_entry_create(apr_pool_t *pool);
919 
920 /** Return a deep copy of @a log_entry, allocated in @a pool.
921  *
922  * The resulting svn_log_entry_t has @c changed_paths set to the same
923  * value as @c changed_path2. @c changed_paths will be @c NULL if
924  * @c changed_paths2 was @c NULL.
925  *
926  * @since New in 1.6.
927  */
929 svn_log_entry_dup(const svn_log_entry_t *log_entry, apr_pool_t *pool);
930 
931 /** The callback invoked by log message loopers, such as
932  * #svn_ra_plugin_t.get_log() and svn_repos_get_logs().
933  *
934  * This function is invoked once on each log message, in the order
935  * determined by the caller (see above-mentioned functions).
936  *
937  * @a baton is what you think it is, and @a log_entry contains relevant
938  * information for the log message. Any of @a log_entry->author,
939  * @a log_entry->date, or @a log_entry->message may be @c NULL.
940  *
941  * If @a log_entry->date is neither NULL nor the empty string, it was
942  * generated by svn_time_to_cstring() and can be converted to
943  * @c apr_time_t with svn_time_from_cstring().
944  *
945  * If @a log_entry->changed_paths is non-@c NULL, then it contains as keys
946  * every path committed in @a log_entry->revision; the values are
947  * (#svn_log_changed_path_t *) structures.
948  *
949  * If @a log_entry->has_children is @c TRUE, the message will be followed
950  * immediately by any number of merged revisions (child messages), which are
951  * terminated by an invocation with SVN_INVALID_REVNUM. This usage may
952  * be recursive.
953  *
954  * Use @a pool for temporary allocation. If the caller is iterating
955  * over log messages, invoking this receiver on each, we recommend the
956  * standard pool loop recipe: create a subpool, pass it as @a pool to
957  * each call, clear it after each iteration, destroy it after the loop
958  * is done. (For allocation that must last beyond the lifetime of a
959  * given receiver call, use a pool in @a baton.)
960  *
961  * @since New in 1.5.
962  */
963 typedef svn_error_t *(*svn_log_entry_receiver_t)(
964  void *baton,
965  svn_log_entry_t *log_entry,
966  apr_pool_t *pool);
967 
968 /**
969  * Similar to #svn_log_entry_receiver_t, except this uses separate
970  * parameters for each part of the log entry.
971  *
972  * @deprecated Provided for backward compatibility with the 1.4 API.
973  */
974 typedef svn_error_t *(*svn_log_message_receiver_t)(
975  void *baton,
976  apr_hash_t *changed_paths,
977  svn_revnum_t revision,
978  const char *author,
979  const char *date, /* use svn_time_from_cstring() if need apr_time_t */
980  const char *message,
981  apr_pool_t *pool);
982 
983 ␌
984 /** Callback function type for commits.
985  *
986  * When a commit succeeds, an instance of this is invoked with the
987  * @a commit_info, along with the @a baton closure.
988  * @a pool can be used for temporary allocations.
989  *
990  * @note Implementers of this callback that pass this callback to
991  * svn_ra_get_commit_editor3() should be careful with returning errors
992  * as these might be returned as commit errors. See the documentation
993  * of svn_ra_get_commit_editor3() for more details.
994  *
995  * @since New in 1.4.
996  */
997 typedef svn_error_t *(*svn_commit_callback2_t)(
998  const svn_commit_info_t *commit_info,
999  void *baton,
1000  apr_pool_t *pool);
1001 
1002 /** Same as #svn_commit_callback2_t, but uses individual
1003  * data elements instead of the #svn_commit_info_t structure
1004  *
1005  * @deprecated Provided for backward compatibility with the 1.3 API.
1006  */
1007 typedef svn_error_t *(*svn_commit_callback_t)(
1008  svn_revnum_t new_revision,
1009  const char *date,
1010  const char *author,
1011  void *baton);
1012 
1013 
1014 ␌
1015 /** A buffer size that may be used when processing a stream of data.
1016  *
1017  * @note We don't use this constant any longer, since it is considered to be
1018  * unnecessarily large.
1019  *
1020  * @deprecated Provided for backwards compatibility with the 1.3 API.
1021  */
1022 #define SVN_STREAM_CHUNK_SIZE 102400
1023 
1024 #ifndef DOXYGEN_SHOULD_SKIP_THIS
1025 /*
1026  * The maximum amount we (ideally) hold in memory at a time when
1027  * processing a stream of data.
1028  *
1029  * For example, when copying data from one stream to another, do it in
1030  * blocks of this size.
1031  *
1032  * NOTE: This is an internal macro, put here for convenience.
1033  * No public API may depend on the particular value of this macro.
1034  */
1035 #define SVN__STREAM_CHUNK_SIZE 16384
1036 #endif
1037 
1038 /** The maximum amount we can ever hold in memory. */
1039 /* FIXME: Should this be the same as SVN_STREAM_CHUNK_SIZE? */
1040 #define SVN_MAX_OBJECT_SIZE (((apr_size_t) -1) / 2)
1041 
1042 
1043 ␌
1044 /* ### Note: despite being about mime-TYPES, these probably don't
1045  * ### belong in svn_types.h. However, no other header is more
1046  * ### appropriate, and didn't feel like creating svn_validate.h for
1047  * ### so little.
1048  */
1049 
1050 /** Validate @a mime_type.
1051  *
1052  * If @a mime_type does not contain a "/", or ends with non-alphanumeric
1053  * data, return #SVN_ERR_BAD_MIME_TYPE, else return success.
1054  *
1055  * Use @a pool only to find error allocation.
1056  *
1057  * Goal: to match both "foo/bar" and "foo/bar; charset=blah", without
1058  * being too strict about it, but to disallow mime types that have
1059  * quotes, newlines, or other garbage on the end, such as might be
1060  * unsafe in an HTTP header.
1061  */
1062 svn_error_t *
1063 svn_mime_type_validate(const char *mime_type,
1064  apr_pool_t *pool);
1065 
1066 /** Return FALSE iff @a mime_type is a textual type.
1067  *
1068  * All mime types that start with "text/" are textual, plus some special
1069  * cases (for example, "image/x-xbitmap").
1070  */
1072 svn_mime_type_is_binary(const char *mime_type);
1073 
1074 
1075 ␌
1076 /** A user defined callback that subversion will call with a user defined
1077  * baton to see if the current operation should be continued. If the operation
1078  * should continue, the function should return #SVN_NO_ERROR, if not, it
1079  * should return #SVN_ERR_CANCELLED.
1080  */
1081 typedef svn_error_t *(*svn_cancel_func_t)(void *cancel_baton);
1082 
1083 
1084 ␌
1085 /**
1086  * A lock object, for client & server to share.
1087  *
1088  * A lock represents the exclusive right to add, delete, or modify a
1089  * path. A lock is created in a repository, wholly controlled by the
1090  * repository. A "lock-token" is the lock's UUID, and can be used to
1091  * learn more about a lock's fields, and or/make use of the lock.
1092  * Because a lock is immutable, a client is free to not only cache the
1093  * lock-token, but the lock's fields too, for convenience.
1094  *
1095  * Note that the 'is_dav_comment' field is wholly ignored by every
1096  * library except for mod_dav_svn. The field isn't even marshalled
1097  * over the network to the client. Assuming lock structures are
1098  * created with apr_pcalloc(), a default value of 0 is universally safe.
1099  *
1100  * @note in the current implementation, only files are lockable.
1101  *
1102  * @since New in 1.2.
1103  */
1104 typedef struct svn_lock_t
1105 {
1106  const char *path; /**< the path this lock applies to */
1107  const char *token; /**< unique URI representing lock */
1108  const char *owner; /**< the username which owns the lock */
1109  const char *comment; /**< (optional) description of lock */
1110  svn_boolean_t is_dav_comment; /**< was comment made by generic DAV client? */
1111  apr_time_t creation_date; /**< when lock was made */
1112  apr_time_t expiration_date; /**< (optional) when lock will expire;
1113  If value is 0, lock will never expire. */
1115 
1116 /**
1117  * Returns an #svn_lock_t, allocated in @a pool with all fields initialized
1118  * to NULL values.
1119  *
1120  * @note To allow for extending the #svn_lock_t structure in the future
1121  * releases, this function should always be used to allocate the structure.
1122  *
1123  * @since New in 1.2.
1124  */
1125 svn_lock_t *
1126 svn_lock_create(apr_pool_t *pool);
1127 
1128 /**
1129  * Return a deep copy of @a lock, allocated in @a pool.
1130  *
1131  * @since New in 1.2.
1132  */
1133 svn_lock_t *
1134 svn_lock_dup(const svn_lock_t *lock, apr_pool_t *pool);
1135 
1136 
1137 ␌
1138 /**
1139  * Return a formatted Universal Unique IDentifier (UUID) string.
1140  *
1141  * @since New in 1.4.
1142  */
1143 const char *
1144 svn_uuid_generate(apr_pool_t *pool);
1145 
1146 
1147 ␌
1148 /**
1149  * Mergeinfo representing a merge of a range of revisions.
1150  *
1151  * @since New in 1.5
1152  */
1153 typedef struct svn_merge_range_t
1154 {
1155  /**
1156  * If the 'start' field is less than the 'end' field then 'start' is
1157  * exclusive and 'end' inclusive of the range described. This is termed
1158  * a forward merge range. If 'start' is greater than 'end' then the
1159  * opposite is true. This is termed a reverse merge range. If 'start'
1160  * equals 'end' the meaning of the range is not defined.
1161  */
1163  svn_revnum_t end;
1164 
1165  /**
1166  * Whether this merge range should be inherited by treewise
1167  * descendants of the path to which the range applies. */
1170 
1171 /**
1172  * Return a copy of @a range, allocated in @a pool.
1173  *
1174  * @since New in 1.5.
1175  */
1177 svn_merge_range_dup(const svn_merge_range_t *range, apr_pool_t *pool);
1178 
1179 /**
1180  * Returns true if the changeset committed in revision @a rev is one
1181  * of the changesets in the range @a range.
1182  *
1183  * @since New in 1.5.
1184  */
1187 
1188 
1189 ␌
1190 /** @defgroup node_location_seg_reporting Node location segment reporting.
1191  * @{ */
1192 
1193 /**
1194  * A representation of a segment of an object's version history with an
1195  * emphasis on the object's location in the repository as of various
1196  * revisions.
1197  *
1198  * @since New in 1.5.
1199  */
1201 {
1202  /** The beginning (oldest) and ending (youngest) revisions for this
1203  segment, both inclusive. */
1205  svn_revnum_t range_end;
1206 
1207  /** The absolute (sans leading slash) path for this segment. May be
1208  NULL to indicate gaps in an object's history. */
1209  const char *path;
1210 
1212 
1213 /**
1214  * A callback invoked by generators of #svn_location_segment_t
1215  * objects, used to report information about a versioned object's
1216  * history in terms of its location in the repository filesystem over
1217  * time.
1218  */
1219 typedef svn_error_t *(*svn_location_segment_receiver_t)(
1220  svn_location_segment_t *segment,
1221  void *baton,
1222  apr_pool_t *pool);
1223 
1224 /**
1225  * Return a deep copy of @a segment, allocated in @a pool.
1226  *
1227  * @since New in 1.5.
1228  */
1231  apr_pool_t *pool);
1232 
1233 /** @} */
1234 
1235 
1236 ␌
1237 /** A line number, such as in a file or a stream.
1238  *
1239  * @since New in 1.7.
1240  */
1241 typedef unsigned long svn_linenum_t;
1242 
1243 /** The maximum value of an svn_linenum_t.
1244  *
1245  * @since New in 1.7.
1246  */
1247 #define SVN_LINENUM_MAX_VALUE ULONG_MAX
1248 
1249 
1250 ␌
1251 #ifdef __cplusplus
1252 }
1253 #endif /* __cplusplus */
1254 
1255 
1256 /*
1257  * Everybody and their brother needs to deal with svn_error_t, the error
1258  * codes, and whatever else. While they *should* go and include svn_error.h
1259  * in order to do that... bah. Let's just help everybody out and include
1260  * that header whenever somebody grabs svn_types.h.
1261  *
1262  * Note that we do this at the END of this header so that its contents
1263  * are available to svn_error.h (our guards will prevent the circular
1264  * include). We also need to do the include *outside* of the cplusplus
1265  * guard.
1266  */
1267 #include "svn_error.h"
1268 
1269 
1270 /*
1271  * Subversion developers may want to use some additional debugging facilities
1272  * while working on the code. We'll pull that in here, so individual source
1273  * files don't have to include this header manually.
1274  */
1275 #ifdef SVN_DEBUG
1276 #include "private/svn_debug.h"
1277 #endif
1278 
1279 
1280 #endif /* SVN_TYPES_H */
const void * apr_hash_this_key(apr_hash_index_t *hi)
Return the key of the hash table entry indexed by hi.
apr_ssize_t apr_hash_this_key_len(apr_hash_index_t *hi)
Return the key length of the hash table entry indexed by hi.
void * apr_hash_this_val(apr_hash_index_t *hi)
Return the value of the hash table entry indexed by hi.
struct svn_location_segment_t svn_location_segment_t
A representation of a segment of an object's version history with an emphasis on the object's locatio...
svn_location_segment_t * svn_location_segment_dup(const svn_location_segment_t *segment, apr_pool_t *pool)
Return a deep copy of segment, allocated in pool.
All information about a commit.
Definition: svn_types.h:686
svn_revnum_t revision
just-committed revision.
Definition: svn_types.h:688
const char * repos_root
repository root, may be NULL if unknown.
Definition: svn_types.h:701
const char * post_commit_err
error message from post-commit hook, or NULL.
Definition: svn_types.h:697
const char * date
server-side date of the commit.
Definition: svn_types.h:691
const char * author
author of the commit.
Definition: svn_types.h:694
A general subversion directory entry.
Definition: svn_types.h:560
svn_filesize_t size
length of file text, otherwise SVN_INVALID_FILESIZE
Definition: svn_types.h:565
svn_boolean_t has_props
does the node have props?
Definition: svn_types.h:568
apr_time_t time
time of created_rev (mod-time)
Definition: svn_types.h:574
const char * last_author
author of created_rev
Definition: svn_types.h:577
svn_revnum_t created_rev
last rev in which this node changed
Definition: svn_types.h:571
svn_node_kind_t kind
node kind
Definition: svn_types.h:562
Subversion error object.
Definition: svn_types.h:177
const char * message
Details from the producer of error.
Definition: svn_types.h:194
apr_pool_t * pool
The pool in which this error object is allocated.
Definition: svn_types.h:206
const char * file
Source file where the error originated (iff SVN_DEBUG; undefined otherwise).
Definition: svn_types.h:211
long line
Source line where the error originated (iff SVN_DEBUG; undefined otherwise).
Definition: svn_types.h:216
apr_status_t apr_err
APR error value; possibly an SVN_ custom error code (see ‘svn_error_codes.h’ for a full listing).
Definition: svn_types.h:181
struct svn_error_t * child
Pointer to the error we "wrap" (may be NULL).
Definition: svn_types.h:200
A representation of a segment of an object's version history with an emphasis on the object's locatio...
Definition: svn_types.h:1201
const char * path
The absolute (sans leading slash) path for this segment.
Definition: svn_types.h:1209
svn_revnum_t range_start
The beginning (oldest) and ending (youngest) revisions for this segment, both inclusive.
Definition: svn_types.h:1204
A lock object, for client & server to share.
Definition: svn_types.h:1105
apr_time_t creation_date
when lock was made
Definition: svn_types.h:1111
const char * token
unique URI representing lock
Definition: svn_types.h:1107
svn_boolean_t is_dav_comment
was comment made by generic DAV client?
Definition: svn_types.h:1110
const char * owner
the username which owns the lock
Definition: svn_types.h:1108
const char * comment
(optional) description of lock
Definition: svn_types.h:1109
apr_time_t expiration_date
(optional) when lock will expire; If value is 0, lock will never expire.
Definition: svn_types.h:1112
const char * path
the path this lock applies to
Definition: svn_types.h:1106
A structure to represent a path that changed for a log entry.
Definition: svn_types.h:743
svn_tristate_t props_modified
Are properties modified, may be svn_tristate_unknown.
Definition: svn_types.h:762
char action
'A'dd, 'D'elete, 'R'eplace, 'M'odify
Definition: svn_types.h:745
const char * copyfrom_path
Source path of copy (if any).
Definition: svn_types.h:748
svn_node_kind_t node_kind
The type of the node, may be svn_node_unknown.
Definition: svn_types.h:754
svn_revnum_t copyfrom_rev
Source revision of copy (if any).
Definition: svn_types.h:751
svn_tristate_t text_modified
Is the text modified, may be svn_tristate_unknown.
Definition: svn_types.h:758
A structure to represent a path that changed for a log entry.
Definition: svn_types.h:798
char action
'A'dd, 'D'elete, 'R'eplace, 'M'odify
Definition: svn_types.h:800
svn_revnum_t copyfrom_rev
Source revision of copy (if any).
Definition: svn_types.h:806
const char * copyfrom_path
Source path of copy (if any).
Definition: svn_types.h:803
A structure to represent all the information about a particular log entry.
Definition: svn_types.h:830
apr_hash_t * revprops
The hash of requested revision properties, which may be NULL if it would contain no revprops.
Definition: svn_types.h:847
apr_hash_t * changed_paths2
A hash containing as keys every path committed in revision; the values are (svn_log_changed_path2_t *...
Definition: svn_types.h:882
svn_boolean_t has_children
Whether or not this message has children.
Definition: svn_types.h:865
apr_hash_t * changed_paths
A hash containing as keys every path committed in revision; the values are (svn_log_changed_path_t *)...
Definition: svn_types.h:839
svn_boolean_t subtractive_merge
Whether revision is a merged revision resulting from a reverse merge.
Definition: svn_types.h:901
svn_boolean_t non_inheritable
Whether revision should be interpreted as non-inheritable in the same sense of svn_merge_range_t.
Definition: svn_types.h:894
svn_revnum_t revision
The revision of the commit.
Definition: svn_types.h:842
Mergeinfo representing a merge of a range of revisions.
Definition: svn_types.h:1154
svn_boolean_t inheritable
Whether this merge range should be inherited by treewise descendants of the path to which the range a...
Definition: svn_types.h:1168
svn_revnum_t start
If the 'start' field is less than the 'end' field then 'start' is exclusive and 'end' inclusive of th...
Definition: svn_types.h:1162
Version information.
Definition: svn_version.h:148
Common exception handling for Subversion.
struct svn_log_entry_t svn_log_entry_t
A structure to represent all the information about a particular log entry.
svn_node_kind_t svn_node_kind_from_word(const char *word)
Return the appropriate node_kind for word.
struct svn_error_t svn_error_t
Subversion error object.
svn_merge_range_t * svn_merge_range_dup(const svn_merge_range_t *range, apr_pool_t *pool)
Return a copy of range, allocated in pool.
svn_log_changed_path_t * svn_log_changed_path_dup(const svn_log_changed_path_t *changed_path, apr_pool_t *pool)
Return a deep copy of changed_path, allocated in pool.
int svn_boolean_t
YABT: Yet Another Boolean Type.
Definition: svn_types.h:137
svn_lock_t * svn_lock_create(apr_pool_t *pool)
Returns an svn_lock_t, allocated in pool with all fields initialized to NULL values.
svn_log_entry_t * svn_log_entry_dup(const svn_log_entry_t *log_entry, apr_pool_t *pool)
Return a deep copy of log_entry, allocated in pool.
svn_log_changed_path2_t * svn_log_changed_path2_dup(const svn_log_changed_path2_t *changed_path, apr_pool_t *pool)
Return a deep copy of changed_path, allocated in pool.
const char * svn_uuid_generate(apr_pool_t *pool)
Return a formatted Universal Unique IDentifier (UUID) string.
svn_log_changed_path2_t * svn_log_changed_path2_create(apr_pool_t *pool)
Returns an svn_log_changed_path2_t, allocated in pool with all fields initialized to NULL,...
svn_tristate_t svn_tristate__from_word(const char *word)
Return the appropriate tristate for word.
const char * svn_tristate__to_word(svn_tristate_t tristate)
Return a constant string "true", "false" or NULL representing the value of tristate.
struct svn_log_changed_path2_t svn_log_changed_path2_t
A structure to represent a path that changed for a log entry.
apr_int64_t svn_filesize_t
The size of a file in the Subversion FS.
Definition: svn_types.h:430
svn_commit_info_t * svn_create_commit_info(apr_pool_t *pool)
Allocate an object of type svn_commit_info_t in pool and return it.
svn_boolean_t svn_merge_range_contains_rev(const svn_merge_range_t *range, svn_revnum_t rev)
Returns true if the changeset committed in revision rev is one of the changesets in the range range.
svn_lock_t * svn_lock_dup(const svn_lock_t *lock, apr_pool_t *pool)
Return a deep copy of lock, allocated in pool.
svn_dirent_t * svn_dirent_dup(const svn_dirent_t *dirent, apr_pool_t *pool)
Return a deep copy of dirent, allocated in pool.
const char * svn_node_kind_to_word(svn_node_kind_t kind)
Return a constant string expressing kind as an English word, e.g., "file", "dir", etc.
svn_error_t * svn_mime_type_validate(const char *mime_type, apr_pool_t *pool)
Validate mime_type.
struct svn_lock_t svn_lock_t
A lock object, for client & server to share.
struct svn_dirent_t svn_dirent_t
A general subversion directory entry.
svn_boolean_t svn_mime_type_is_binary(const char *mime_type)
Return FALSE iff mime_type is a textual type.
svn_dirent_t * svn_dirent_create(apr_pool_t *result_pool)
Create a new svn_dirent_t instance with all values initialized to their not-available values.
struct svn_merge_range_t svn_merge_range_t
Mergeinfo representing a merge of a range of revisions.
unsigned long svn_linenum_t
A line number, such as in a file or a stream.
Definition: svn_types.h:1241
struct svn_log_changed_path_t svn_log_changed_path_t
A structure to represent a path that changed for a log entry.
svn_log_entry_t * svn_log_entry_create(apr_pool_t *pool)
Returns an svn_log_entry_t, allocated in pool with all fields initialized to NULL values.
svn_commit_info_t * svn_commit_info_dup(const svn_commit_info_t *src_commit_info, apr_pool_t *pool)
Return a deep copy src_commit_info allocated in pool.
svn_error_t * svn_revnum_parse(svn_revnum_t *rev, const char *str, const char **endptr)
Parse NULL-terminated C string str as a revision number and store its value in rev.
const char * svn_depth_to_word(svn_depth_t depth)
Return a constant string expressing depth as an English word, e.g., "infinity", "immediates",...
#define SVN_DEPRECATED
Macro used to mark deprecated functions.
Definition: svn_types.h:62
struct svn_commit_info_t svn_commit_info_t
All information about a commit.
svn_recurse_kind
An enum to indicate whether recursion is needed.
Definition: svn_types.h:449
svn_depth_t svn_depth_from_word(const char *word)
Return the appropriate depth for depth_str.
Subversion's data types (common implementation)
svn_depth_t
The concept of depth for directories.
svn_tristate_t
Generic three-state property to represent an unknown value for values that are just like booleans.
svn_node_kind_t
The various types of nodes in the Subversion filesystem.
long int svn_revnum_t
A revision number.