[−][src]Struct bat::assets_metadata::AssetsMetadata
Implementations
impl AssetsMetadata
[src]
pub fn load_from_folder(path: &Path) -> Result<Option<Self>>
[src]
Load metadata about the stored cache file from the given folder.
There are several possibilities:
- We find a metadata.yaml file and are able to parse it => return the contained information
- We find a metadata.yaml file and but are not able to parse it => return a SerdeYamlError
- We do not find a metadata.yaml file but a syntaxes.bin or themes.bin file => assume that these were created by an old version of bat and return AssetsMetadata::default() without version information
- We do not find a metadata.yaml file and no cached assets => no user provided assets are available, return None
pub fn is_compatible_with(&self, current_version: &str) -> bool
[src]
Trait Implementations
impl Debug for AssetsMetadata
[src]
impl Default for AssetsMetadata
[src]
pub fn default() -> AssetsMetadata
[src]
impl<'de> Deserialize<'de> for AssetsMetadata
[src]
pub fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
impl PartialEq<AssetsMetadata> for AssetsMetadata
[src]
pub fn eq(&self, other: &AssetsMetadata) -> bool
[src]
pub fn ne(&self, other: &AssetsMetadata) -> bool
[src]
impl Serialize for AssetsMetadata
[src]
pub fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error> where
__S: Serializer,
[src]
__S: Serializer,
impl StructuralPartialEq for AssetsMetadata
[src]
Auto Trait Implementations
impl RefUnwindSafe for AssetsMetadata
impl Send for AssetsMetadata
impl Sync for AssetsMetadata
impl Unpin for AssetsMetadata
impl UnwindSafe for AssetsMetadata
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,