#[repr(C)]pub struct svn_patch_t {Show 13 fields
pub old_filename: *const c_char,
pub new_filename: *const c_char,
pub hunks: *mut apr_array_header_t,
pub prop_patches: *mut apr_hash_t,
pub operation: svn_diff_operation_kind_t,
pub reverse: svn_boolean_t,
pub mergeinfo: svn_mergeinfo_t,
pub reverse_mergeinfo: svn_mergeinfo_t,
pub binary_patch: *mut svn_diff_binary_patch_t,
pub old_executable_bit: svn_tristate_t,
pub new_executable_bit: svn_tristate_t,
pub old_symlink_bit: svn_tristate_t,
pub new_symlink_bit: svn_tristate_t,
}
Expand description
Data type to manage parsing of patches.
Represents a patch to one target file.
API users should not allocate structures of this type directly.
@since New in 1.7.
Fields§
§old_filename: *const c_char
The old and new file names as retrieved from the patch file. These paths are UTF-8 encoded and canonicalized, but otherwise left unchanged from how they appeared in the patch file.
new_filename: *const c_char
§hunks: *mut apr_array_header_t
An array containing an svn_diff_hunk_t * for each hunk parsed from the patch.
prop_patches: *mut apr_hash_t
A hash table keyed by property names containing svn_prop_patch_t object for each property parsed from the patch.
operation: svn_diff_operation_kind_t
Represents the operation performed on the file.
reverse: svn_boolean_t
Indicates whether the patch is being interpreted in reverse.
§If so, how does this affect the interpretation of other fields?
mergeinfo: svn_mergeinfo_t
Mergeinfo parsed from svn:mergeinfo diff data, with one entry for forward merges and one for reverse merges. Either entry can be @c NULL if no such merges are part of the diff. @since New in 1.9.
reverse_mergeinfo: svn_mergeinfo_t
§binary_patch: *mut svn_diff_binary_patch_t
Declares that there is a binary conflict and contains the information to apply it as parsed from the file. @since New in 1.10.
old_executable_bit: svn_tristate_t
The old and new executability bits, as retrieved from the patch file, from the git-like mode headers.
A patch may specify an executability change via @a old_executable_bit and @a new_executable_bit, via a #SVN_PROP_EXECUTABLE propchange hunk, or both ways. It is upto caller how to decide how conflicting information is handled.
#svn_tristate_unknown indicates the patch does not specify the corresponding bit.
@since New in 1.10.
new_executable_bit: svn_tristate_t
§old_symlink_bit: svn_tristate_t
The old and new symlink bits, as retrieved from the patch file, from the git-like mode headers.
A patch may specify a symlink change via @a old_symlink_bit and @a new_symlink_bit, via a #SVN_PROP_SPECIAL propchange hunk, or both ways. It is upto caller how to decide how conflicting information is handled. Most implementations will currently just describe a replacement of the file though.
#svn_tristate_unknown indicates the patch does not specify the corresponding bit.
@since New in 1.10.
new_symlink_bit: svn_tristate_t
Trait Implementations§
Source§impl Clone for svn_patch_t
impl Clone for svn_patch_t
Source§fn clone(&self) -> svn_patch_t
fn clone(&self) -> svn_patch_t
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more