pub struct StorageUri {
pub scheme: Scheme,
pub path: String,
pub bucket: Option<String>,
}Expand description
Parsed storage URI.
Recognized schemes: file, s3. Bare paths (no scheme) are normalized
to file:// URIs.
Fields§
§scheme: Scheme§path: StringFor file: an absolute or relative filesystem path.
For s3: the key prefix (no leading /).
bucket: Option<String>For s3 only: the bucket name.
Implementations§
Source§impl StorageUri
impl StorageUri
Sourcepub fn parse(input: &str) -> Result<Self, StorageError>
pub fn parse(input: &str) -> Result<Self, StorageError>
Parse a URI string. Bare paths become file:// URIs.
Trait Implementations§
Source§impl Clone for StorageUri
impl Clone for StorageUri
Source§fn clone(&self) -> StorageUri
fn clone(&self) -> StorageUri
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 StorageUri
impl Debug for StorageUri
impl Eq for StorageUri
Source§impl PartialEq for StorageUri
impl PartialEq for StorageUri
Source§fn eq(&self, other: &StorageUri) -> bool
fn eq(&self, other: &StorageUri) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for StorageUri
Auto Trait Implementations§
impl Freeze for StorageUri
impl RefUnwindSafe for StorageUri
impl Send for StorageUri
impl Sync for StorageUri
impl Unpin for StorageUri
impl UnsafeUnpin for StorageUri
impl UnwindSafe for StorageUri
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