Skip to main content

MessageTransformer

Trait MessageTransformer 

Source
pub trait MessageTransformer {
    // Required methods
    fn transform(&self, message: &ExternalMessage) -> Result<ExternalMessage>;
    fn name(&self) -> &str;
    fn supported_formats(&self) -> (MessageFormat, MessageFormat);
}
Expand description

Message transformer trait

Required Methods§

Source

fn transform(&self, message: &ExternalMessage) -> Result<ExternalMessage>

Transform message from source format to target format

Source

fn name(&self) -> &str

Get transformer name

Source

fn supported_formats(&self) -> (MessageFormat, MessageFormat)

Get supported formats

Implementors§