#[resource]
Defines a resource handler with URI pattern matching.
#[resource( uri_template = "file:///{path}", mime_type = "text/plain" )] async fn read_file(&self, path: String) -> Result<String, Error> { std::fs::read_to_string(path).map_err(|e| e.into()) }