(
project: &ProjectId,
uid: &str,
kind: ChildKind,
child: &str,
)
| 180 | } |
| 181 | } |
| 182 | pub fn mint_child( |
| 183 | project: &ProjectId, |
| 184 | uid: &str, |
| 185 | kind: ChildKind, |
| 186 | child: &str, |
| 187 | ) -> Result<String, IriError> { |
| 188 | Ok(format!( |
| 189 | "{}:{}:{}", |
| 190 | mint_intent(project, uid)?, |
| 191 | kind.segment(), |
| 192 | encode(&child.to_uppercase(), false) |
| 193 | )) |
| 194 | } |
| 195 | pub fn parse_child(iri: &str) -> Result<(ProjectId, String, ChildKind, String), IriError> { |
| 196 | let (project, rest) = parse_qualified(iri, "intent")?; |
| 197 | let mut parts = rest.split(':'); |
no outgoing calls