Skip to content

Commit

Permalink
improve docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Frando committed Mar 22, 2024
1 parent 6e48f76 commit 2397231
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions iroh-bytes/src/store/traits.rs
Original file line number Diff line number Diff line change
Expand Up @@ -635,11 +635,15 @@ pub enum ExportFormat {
/// The hash refers to any blob and will be exported to a single file.
#[default]
Blob,
/// The hash refers to a [`Collection`] blob and all children of the collection will be
/// exported to one file per child.
/// The hash refers to a [`crate::format::collection::Collection`] blob
/// and all children of the collection shall be exported to one file per child.
///
/// If the blob can be parsed as a [`Collection`], all children of the collection will be
/// exported. If the blob cannot be parsed as a [`Collection`], the operation will be failed.
/// If the blob can be parsed as a [`BlobFormat::HashSeq`], and the first child contains
/// collection metadata, all other children of the collection will be exported to
/// a file each, with their collection name treated as a relative path to the export
/// destination path.
///
/// If the blob cannot be parsed as a collection, the operation will fail.
Collection,
}

Expand Down

0 comments on commit 2397231

Please sign in to comment.