Skip to main content

aws_sdk_codecommit/client/
get_blob_differences.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2impl super::Client {
3    /// Constructs a fluent builder for the [`GetBlobDifferences`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder) operation.
4    /// This operation supports pagination; See [`into_paginator()`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::into_paginator).
5    ///
6    /// - The fluent builder is configurable:
7    ///   - [`repository_name(impl Into<String>)`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::repository_name) / [`set_repository_name(Option<String>)`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::set_repository_name):<br>required: **true**<br><p>The name of the repository that contains the blobs to compare.</p><br>
8    ///   - [`after_blob_id(impl Into<String>)`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::after_blob_id) / [`set_after_blob_id(Option<String>)`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::set_after_blob_id):<br>required: **true**<br><p>The ID of the "after" (destination) blob in the diff. Typically the value of <code>afterBlob.blobId</code> from a <code>Difference</code> object returned by <code>GetDifferences</code>.</p><br>
9    ///   - [`before_blob_id(impl Into<String>)`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::before_blob_id) / [`set_before_blob_id(Option<String>)`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::set_before_blob_id):<br>required: **false**<br><p>The ID of the "before" (source) blob in the diff. Typically the value of <code>beforeBlob.blobId</code> from a <code>Difference</code> object returned by <code>GetDifferences</code>.</p> <p>If you do not specify a value, the operation returns a diff against an empty before-state. This is equivalent to treating the file as newly added.</p><br>
10    ///   - [`context_lines(i32)`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::context_lines) / [`set_context_lines(Option<i32>)`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::set_context_lines):<br>required: **false**<br><p>The number of unchanged lines of context to include before and after each block of changes in a hunk. Valid values are 0 through 20. Defaults to <code>3</code>.</p><br>
11    ///   - [`ignore_whitespace(bool)`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::ignore_whitespace) / [`set_ignore_whitespace(Option<bool>)`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::set_ignore_whitespace):<br>required: **false**<br><p>Specifies whether to ignore whitespace-only changes when computing the diff. When <code>true</code>, the operation treats lines that differ only in whitespace as unchanged. Defaults to <code>false</code>.</p><br>
12    ///   - [`max_results(i32)`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::max_results) / [`set_max_results(Option<i32>)`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::set_max_results):<br>required: **false**<br><p>The maximum number of <code>DiffHunk</code> entries to return in a single response page. Defaults to <code>100</code>.</p><br>
13    ///   - [`next_token(impl Into<String>)`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::next_token) / [`set_next_token(Option<String>)`](crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::set_next_token):<br>required: **false**<br><p>An enumeration token that returns the next batch of results when present in a request.</p><br>
14    /// - On success, responds with [`GetBlobDifferencesOutput`](crate::operation::get_blob_differences::GetBlobDifferencesOutput) with field(s):
15    ///   - [`hunks(Vec::<DiffHunk>)`](crate::operation::get_blob_differences::GetBlobDifferencesOutput::hunks): <p>An ordered list of diff hunks. Each hunk represents a contiguous run of changed and adjacent context lines. The list is empty when the blobs are identical or when the content is binary. The list is also empty when a paginated request has already returned all hunks in earlier pages, in which case <code>NextToken</code> is also <code>null</code>.</p>
16    ///   - [`is_binary(bool)`](crate::operation::get_blob_differences::GetBlobDifferencesOutput::is_binary): <p>Specifies whether the operation treated the diff content as binary. When <code>true</code>, the operation does not compute a line-level diff and <code>hunks</code> is empty.</p>
17    ///   - [`before_blob_size(i64)`](crate::operation::get_blob_differences::GetBlobDifferencesOutput::before_blob_size): <p>The size, in bytes, of the blob identified by <code>beforeBlobId</code>. Returns <code>0</code> when you do not specify <code>beforeBlobId</code>.</p>
18    ///   - [`after_blob_size(i64)`](crate::operation::get_blob_differences::GetBlobDifferencesOutput::after_blob_size): <p>The size, in bytes, of the blob identified by <code>afterBlobId</code>.</p>
19    ///   - [`next_token(Option<String>)`](crate::operation::get_blob_differences::GetBlobDifferencesOutput::next_token): <p>An enumeration token that can be used in a request to return the next batch of <code>DiffHunk</code> entries. <code>null</code> when the response contains the final page of the diff.</p>
20    /// - On failure, responds with [`SdkError<GetBlobDifferencesError>`](crate::operation::get_blob_differences::GetBlobDifferencesError)
21    pub fn get_blob_differences(&self) -> crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder {
22        crate::operation::get_blob_differences::builders::GetBlobDifferencesFluentBuilder::new(self.handle.clone())
23    }
24}