Crate katcp_derive

Source

Derive Macrosยง

KatcpDiscrete
This derive macro decorates an enum to implement ToKatcpArgument and FromKatcpArgument for use with the KatcpMessage macro. This will create a bidirectional mapping between the variant names and a kebab-cased string of the variant (as per the spec).
KatcpMessage
This derive macro creates serde methods for a decorated enum that has any of the variants Request, Reply, and Inform. The variants must have named data associated with them and every field of that data must impl ToKatcpArgument and FromKatcpArgument. The message name that is generated is a kebab-case version of the enum name.