#[non_exhaustive]pub struct PreparedUpload {
pub data_map: DataMap,
pub payment_info: ExternalPaymentInfo,
pub data_map_address: Option<[u8; 32]>,
}Expand description
Prepared upload ready for external payment.
Contains everything needed to construct the on-chain payment transaction externally (e.g. via WalletConnect in a desktop app) and then finalize the upload without a Rust-side wallet.
Note: This struct stays in Rust memory — only the public fields of
payment_info are sent to the frontend. PreparedChunk contains
non-serializable network types, so the full struct cannot derive Serialize.
Marked #[non_exhaustive] so adding a new field in future is not a
breaking change for downstream consumers.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.data_map: DataMapThe data map for later retrieval.
payment_info: ExternalPaymentInfoPayment information — either wave-batch or merkle depending on chunk count.
data_map_address: Option<[u8; 32]>Chunk address of the serialized DataMap when this upload was
prepared with Visibility::Public. Some means the address is
retrievable on the network after finalization — either because this
upload paid to store the chunk in payment_info, or because the
chunk was already on the network (deterministic self-encryption).
Carried through to FileUploadResult::data_map_address.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PreparedUpload
impl RefUnwindSafe for PreparedUpload
impl Send for PreparedUpload
impl Sync for PreparedUpload
impl Unpin for PreparedUpload
impl UnsafeUnpin for PreparedUpload
impl UnwindSafe for PreparedUpload
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more