pub fn decode_payload<T>(raw: &str) -> Result<T, Violation>where T: DeserializeOwned + Validate,
Deserializes and validates an OCPP payload, mapping failures to the OCPP-J RPC error code that best describes them.