Add ObjectPath query language
This commit is contained in:
@@ -7,10 +7,14 @@ pub use post::*;
|
||||
mod misc;
|
||||
pub use misc::*;
|
||||
|
||||
use crate::objectpath::ObjectPath;
|
||||
|
||||
pub mod objectpath;
|
||||
|
||||
pub static INIT_DB_TOML: &str = include_str!("./config.toml");
|
||||
|
||||
#[test]
|
||||
#[expect(clippy::unwrap_used)]
|
||||
#[expect(clippy::expect_used)]
|
||||
fn init_db_toml_valid() {
|
||||
toml::from_str::<ConfigToml>(INIT_DB_TOML).expect("INIT_DB_TOML should be valid TOML");
|
||||
}
|
||||
@@ -56,7 +60,7 @@ pub struct FieldSpec {
|
||||
pub r#type: FieldType,
|
||||
|
||||
/// How to find this field in a data entry
|
||||
pub path: OneOrMany<String>,
|
||||
pub path: OneOrMany<ObjectPath>,
|
||||
|
||||
/// How to post-process this field
|
||||
#[serde(default)]
|
||||
|
||||
Reference in New Issue
Block a user