WPR2A6Y7OMJ7JIO7LNFVUR5YSB34HFWWZNGQLAQOJBFGUCNLNA4QC
QMBJ2BAZHDVFT2GHOOXRGNOEXUOQ7JAX5M7LCEEULDHKIHXX6YZQC
6ZJX2OQV5MYICMONYVYP55DUKORJ3KPLIN7LHAYLXY7ZB7SZE7TAC
N467KW7J7K5T6THQV2EACLUC4AEDR74TNNKRQCYTZTBMBUJUVRTAC
TMYMF5L66ABESNWY4KP54E4FDPHXSZPAU4M2VN4K26Q4Y7BVUUYAC
446EWE33BRKR2QD6KZTMX7PNH5P46B76EKVZFRNCZ57HJ2CXGBRQC
JUK3ONMUIR5CVOMELN6JGTUH7N2F3CRWTPI2BH747IXR3BJIYJDQC
where
KeyTreeRef<'a>: TryInto<T>,
KeyTreeRef<'a>: TryInto<T, Error = Error>,
{
let path = KeyPath::from_str(key_path);
let kts = self.resolve_path(&path)?;
let mut v = Vec::new();
for kt in kts {
v.push(kt.key_into()?)
}
if v.is_empty() {
return Err(expected_non_empty_collection(
file!(),
line!(),
key_path
))
};
Ok(v)
}
pub fn opt_vec_at<T>(&self, key_path: &str) -> Result<Vec<T>>
pub fn colon_before_key() -> Error {
Error(String::from("[03] Colon before key."))
pub fn colon_before_key(file: &str, code_line: u32, token: &str, line: usize) -> Error {
Error(format!(
"[keytree:04:{}:{}] Line {}, token [{}]. Colon before key.",
file,
code_line,
line,
token,
))
pub fn expected_unique_token_found_multi() -> Error {
Error(
String::from("[11] Expected a unique token but found multiple.")
)
pub fn expected_unique_token_found_multi(file: &str, code_line: u32, key_path: &str) -> Error {
Error(format!(
"[keytree:12:{}:{}] Keypath [{}]. Expected a unique token but found multiple.",
file,
code_line,
key_path,
))
pub fn no_space_after_key() -> Error {
Error(String::from("[22] No space after key."))
pub fn no_space_after_key(file: &str, code_line: u32, token: &str, line: usize) -> Error {
Error(format!(
"[keytree:23:{}:{}] line {} token [{}]. No space after key.",
file,
code_line,
line,
token,
))