macro_rules! script {
($init_func:ident) => { ... };
}Expand description
A macro for writing a “script” process. Using this will create the initial
entry point for your process, including the standard init function which
is called by the system, and a set of calls that:
- Parse the
ourstring into anAddressobject. - Wait for the first message to be sent to the process.
- Convert the message body into a string.
- Call the
initfunction you provide with thecrate::Addressand the message body string.
This is best used by then using clap to create a Command and parsing the body string with it.