pub fn parse(
event: String,
wanted_event_types: EventTypeFlags,
) -> Result<Option<GatewayEvent>, ReceiveMessageError>Expand description
Parse a JSON encoded gateway event into a GatewayEvent if
wanted_event_types contains its type.
ยงErrors
Returns a ReceiveMessageErrorType::Deserializing error if the known
event could not be deserialized.