The TypeResolver class

Current version: 9.0

The Email Experience Manager (EXM) enables you to create different types of messages. To map a message type to the appropriate class in code, EXM uses the TypeResolver class.

EXM provides the following message type classes that are derived from the MessageItem base abstract class:

  • TextMail

  • HtmlMail

  • WebPageMail

  • ABTestMessage

For customization purposes, you can create a custom message type class to be used in EXM or delete any of the existing classes.

Depending on the item type, the GetCorrectMessageObject method of the TypeResolver class returns:

  • For not a message item, the method returns null.

  • For a message item, the method returns one of the following types – text mail, HTML mail, webpage mail, or A/B test message.

The following table shows how EXM message templates correspond to the message type classes:

Message template

Message type class

HTML file

The ABTestMessage class

Sample newsletter

The ABTestMessage class

Two-Column message

The ABTestMessage class

One-Column Message

The ABTestMessage class

Simple HTML Message

The HtmlMail class

Plain Text Message

The TextMail class

Existing Page

The WebPageMail class

Note

The ABTestMessage class is a descendant of the WebPageMail class. It is generally used for messages that contain two or more testable variations, except for the HTML file template, which doesn't support A/B testing. A/B tests also cannot be performed on the message types that are mapped to the other classes: Simple HTML Message, Plain Text Message, and Existing Page.

Do you have some feedback for us?

If you have suggestions for improving this article,