Skip to main content

entities

Macro entities 

Source
macro_rules! entities {
    ($($key:expr => $val:expr),* $(,)?) => { ... };
}
Expand description

Convenience macro for building an Entities map inline.

ยงExample

use bids_core::entities;

let ents = entities! {
    "subject" => "01",
    "task" => "rest",
    "suffix" => "eeg",
    "extension" => ".edf",
};
assert_eq!(ents.get("subject").unwrap().as_str_lossy(), "01");
assert_eq!(ents.len(), 4);