Skip to main content

from_source

Function from_source 

Source
pub fn from_source<T: DeserializeOwned + Debug + Ord>(
    file: &str,
    source: &str,
    rules: &TipRules<'_>,
) -> Result<TipTable<T>, Vec<ContentError>>
Expand description

Parses and validates tips source, attributing errors to file: ids are lowercase and used once, a trigger has one tip, the title and text fit rules’ box, every placeholder is one of the game’s and every face is fine by the game. Reports every problem found.