pub struct FrontmatterParser;
Expand description
Helper methods for parsing frontmatter
Implementations§
Source§impl FrontmatterParser
impl FrontmatterParser
pub fn extract_string( map: &HashMap<String, Pod>, key: &str, ) -> Result<String, DocumentValidationError>
pub fn extract_bool( map: &HashMap<String, Pod>, key: &str, ) -> Result<bool, DocumentValidationError>
pub fn extract_integer( map: &HashMap<String, Pod>, key: &str, ) -> Result<i64, DocumentValidationError>
pub fn extract_datetime( map: &HashMap<String, Pod>, key: &str, ) -> Result<DateTime<Utc>, DocumentValidationError>
pub fn extract_string_array( map: &HashMap<String, Pod>, key: &str, ) -> Result<Vec<String>, DocumentValidationError>
Auto Trait Implementations§
impl Freeze for FrontmatterParser
impl RefUnwindSafe for FrontmatterParser
impl Send for FrontmatterParser
impl Sync for FrontmatterParser
impl Unpin for FrontmatterParser
impl UnwindSafe for FrontmatterParser
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
Source§impl<T> IntoSql for T
impl<T> IntoSql for T
Source§fn into_sql<T>(self) -> Self::Expression
fn into_sql<T>(self) -> Self::Expression
Convert
self
to an expression for Diesel’s query builder. Read moreSource§fn as_sql<'a, T>(&'a self) -> <&'a Self as AsExpression<T>>::Expression
fn as_sql<'a, T>(&'a self) -> <&'a Self as AsExpression<T>>::Expression
Convert
&self
to an expression for Diesel’s query builder. Read more