pub struct ContentUploadIntent { /* private fields */ }Expand description
Immutable upload intent persisted before acquiring or resuming a backend upload session.
Implementations§
Source§impl ContentUploadIntent
impl ContentUploadIntent
Sourcepub fn new(
operation_id: OperationId,
idempotency_key: IdempotencyKey,
base_cache_key: ContentCacheKey,
snapshot: LocalContentSnapshot,
upload_lease_id: ContentLeaseId,
session_generation: SessionGeneration,
) -> Result<Self>
pub fn new( operation_id: OperationId, idempotency_key: IdempotencyKey, base_cache_key: ContentCacheKey, snapshot: LocalContentSnapshot, upload_lease_id: ContentLeaseId, session_generation: SessionGeneration, ) -> Result<Self>
Creates an upload bound to one base remote revision and immutable local generation.
§Errors
Returns an error when validation fails or an underlying backend, store, or platform operation fails.
Sourcepub const fn operation_id(&self) -> &OperationId
pub const fn operation_id(&self) -> &OperationId
Returns the durable operation identity shared with mutation reconciliation.
Sourcepub const fn idempotency_key(&self) -> &IdempotencyKey
pub const fn idempotency_key(&self) -> &IdempotencyKey
Returns the backend idempotency/status reconciliation key.
Sourcepub const fn base_cache_key(&self) -> &ContentCacheKey
pub const fn base_cache_key(&self) -> &ContentCacheKey
Returns the exact remote content revision used as the conditional upload base.
Sourcepub const fn snapshot(&self) -> &LocalContentSnapshot
pub const fn snapshot(&self) -> &LocalContentSnapshot
Returns the immutable local source snapshot.
Sourcepub const fn upload_lease_id(&self) -> &ContentLeaseId
pub const fn upload_lease_id(&self) -> &ContentLeaseId
Returns the operation-owned upload lease identity.
Sourcepub const fn session_generation(&self) -> SessionGeneration
pub const fn session_generation(&self) -> SessionGeneration
Returns the platform session generation that accepted the upload.
Trait Implementations§
Source§impl Clone for ContentUploadIntent
impl Clone for ContentUploadIntent
Source§fn clone(&self) -> ContentUploadIntent
fn clone(&self) -> ContentUploadIntent
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 Debug for ContentUploadIntent
impl Debug for ContentUploadIntent
Source§impl PartialEq for ContentUploadIntent
impl PartialEq for ContentUploadIntent
impl Eq for ContentUploadIntent
impl StructuralPartialEq for ContentUploadIntent
Auto Trait Implementations§
impl Freeze for ContentUploadIntent
impl RefUnwindSafe for ContentUploadIntent
impl Send for ContentUploadIntent
impl Sync for ContentUploadIntent
impl Unpin for ContentUploadIntent
impl UnwindSafe for ContentUploadIntent
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