#[non_exhaustive]pub struct CommitRepositoryChangesRequest {
pub name: String,
pub commit_metadata: Option<CommitMetadata>,
pub required_head_commit_sha: String,
pub file_operations: HashMap<String, FileOperation>,
/* private fields */
}Expand description
CommitRepositoryChanges request message.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.name: StringRequired. The repository’s name.
commit_metadata: Option<CommitMetadata>Required. The changes to commit to the repository.
required_head_commit_sha: StringOptional. The commit SHA which must be the repository’s current HEAD before applying this commit; otherwise this request will fail. If unset, no validation on the current HEAD commit SHA is performed.
file_operations: HashMap<String, FileOperation>Optional. A map to the path of the file to the operation. The path is the full file path including filename, from repository root.
Implementations§
Source§impl CommitRepositoryChangesRequest
impl CommitRepositoryChangesRequest
pub fn new() -> Self
Sourcepub fn set_commit_metadata<T>(self, v: T) -> Selfwhere
T: Into<CommitMetadata>,
pub fn set_commit_metadata<T>(self, v: T) -> Selfwhere
T: Into<CommitMetadata>,
Sets the value of commit_metadata.
Sourcepub fn set_or_clear_commit_metadata<T>(self, v: Option<T>) -> Selfwhere
T: Into<CommitMetadata>,
pub fn set_or_clear_commit_metadata<T>(self, v: Option<T>) -> Selfwhere
T: Into<CommitMetadata>,
Sets or clears the value of commit_metadata.
Sourcepub fn set_required_head_commit_sha<T: Into<String>>(self, v: T) -> Self
pub fn set_required_head_commit_sha<T: Into<String>>(self, v: T) -> Self
Sets the value of required_head_commit_sha.
Sourcepub fn set_file_operations<T, K, V>(self, v: T) -> Self
pub fn set_file_operations<T, K, V>(self, v: T) -> Self
Sets the value of file_operations.
Trait Implementations§
Source§impl Clone for CommitRepositoryChangesRequest
impl Clone for CommitRepositoryChangesRequest
Source§fn clone(&self) -> CommitRepositoryChangesRequest
fn clone(&self) -> CommitRepositoryChangesRequest
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Default for CommitRepositoryChangesRequest
impl Default for CommitRepositoryChangesRequest
Source§fn default() -> CommitRepositoryChangesRequest
fn default() -> CommitRepositoryChangesRequest
Returns the “default value” for a type. Read more
Source§impl PartialEq for CommitRepositoryChangesRequest
impl PartialEq for CommitRepositoryChangesRequest
Source§fn eq(&self, other: &CommitRepositoryChangesRequest) -> bool
fn eq(&self, other: &CommitRepositoryChangesRequest) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for CommitRepositoryChangesRequest
Auto Trait Implementations§
impl Freeze for CommitRepositoryChangesRequest
impl RefUnwindSafe for CommitRepositoryChangesRequest
impl Send for CommitRepositoryChangesRequest
impl Sync for CommitRepositoryChangesRequest
impl Unpin for CommitRepositoryChangesRequest
impl UnwindSafe for CommitRepositoryChangesRequest
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more