Enum manganis_common::FileSource
source · pub enum FileSource {
Local(PathBuf),
Remote(Url),
}
Expand description
The source of a file asset
Variants§
Implementations§
source§impl FileSource
impl FileSource
sourcepub fn last_segment(&self) -> &str
pub fn last_segment(&self) -> &str
Returns the last segment of the file source used to generate a unique name
sourcepub fn last_updated(&self) -> Option<String>
pub fn last_updated(&self) -> Option<String>
Find when the asset was last updated
Trait Implementations§
source§impl Clone for FileSource
impl Clone for FileSource
source§fn clone(&self) -> FileSource
fn clone(&self) -> FileSource
Returns a copy 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 FileSource
impl Debug for FileSource
source§impl<'de> Deserialize<'de> for FileSource
impl<'de> Deserialize<'de> for FileSource
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Display for FileSource
impl Display for FileSource
source§impl FromStr for FileSource
impl FromStr for FileSource
source§impl Hash for FileSource
impl Hash for FileSource
source§impl PartialEq for FileSource
impl PartialEq for FileSource
source§fn eq(&self, other: &FileSource) -> bool
fn eq(&self, other: &FileSource) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for FileSource
impl PartialOrd for FileSource
source§fn partial_cmp(&self, other: &FileSource) -> Option<Ordering>
fn partial_cmp(&self, other: &FileSource) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl Serialize for FileSource
impl Serialize for FileSource
impl StructuralPartialEq for FileSource
Auto Trait Implementations§
impl Freeze for FileSource
impl RefUnwindSafe for FileSource
impl Send for FileSource
impl Sync for FileSource
impl Unpin for FileSource
impl UnwindSafe for FileSource
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