Interface Inx_Api_TriggerMail_TriggerMailingRenderer

Description

The

  1. TriggerMailingRenderer
is used to generate mail content using the API. will be to generate personalized previews of trigger mailings. trigger mails using a different mail sender. enormously.

The

  1. TriggerMailingRenderer
is used to generate mail content using the API. The main use of the class will be to generate personalized previews of trigger mailings. The class can also be used to generate and send single trigger mails using a different mail sender. Be aware that in this case the mail sending rate would decrease enormously. To preview a trigger mailing, take a
  1. TriggerMailingRenderer
from the com.inxmail.xpro.api.triggermailing.TriggerMailingManager. Each mailing needs to be parsed before building it. The following snippet shows how to build a trigger mail for a given recipient:
 $oRenderer = $oSession->getTriggerMailingManager()->createRenderer();

 $oRenderer->parse( $iMailingId, Inx_Api_TriggerMail_BuildMode::ALTERNATIVEVIEW_ACTIVE() );

 $oContent = $oRenderer->build( $iRecipientId );

  1. TriggerMailingRenderer
can handle the following different build modes:
  1. PREVIEW - Trackable links will not trigger any events, unsubscription links will redirect but not unsubscribe anybody. Embedded images are replaced with http references to image resources on the Inxmail server.
  2. ALTERNATIVEVIEW_ACTIVE - All links are fully functional. Embedded images are replaced with http references to image resources on the Inxmail server.
  3. ALTERNATIVEVIEW_INACTIVE - All links are not functional. Embedded images are replaced with http references to image resources on the Inxmail server.
  4. NORMAL - The mail is rendered, ready to be sent.
  5. ARCHIVE - Trackable links will not trigger any events, unsubscription links will redirect but not unsubscribe anybody. Embedded images are replaced with http references to image resources on the Inxmail server.
  6. ALTERNATIVEVIEW_ACTIVE_SIMPLE_LINKS - All links are fully functional but converted to simple links. Embedded images are replaced with http references to image resources on the Inxmail server.
  7. NEWSLETTER_SIMPLE_LINKS - The same as above, but the function InInboxView returns true.

<strong>Note:</strong> A

  1. TriggerMailingRenderer
object <strong>must</strong> be closed once it is not needed anymore to prevent memory leaks and other potentially harmful side effects.

  • author: chge, 09.07.2012
  • see: com.inxmail.xpro.api.triggermail.TriggerMailContent
  • deprecated: As of 1.11.10, Inx_Api_TriggerMail_TriggerMailingRenderer has been replaced with Inx_Api_Rendering_GeneralMailingRenderer
  • since: API 1.10.0

Located in /Api/TriggerMail/TriggerMailingRenderer.php (line 50)


	
			
Method Summary
the build (recipientId $iRecipientId, [Inx_Api_TriggerMail_TriggerMailingContentType $preferredMailType = null])
void close ()
void parse (mailingId $iMailingId, Inx_Api_TriggerMail_BuildMode $buildMode, [buildMode $iSendingId = null])
Methods
build (line 78)

Generates the personalized trigger mail content (recipient address, subject, HTML and/or plain text, . specified recipient with a specified mail type restriction.

Generates the personalized trigger mail content (recipient address, subject, HTML and/or plain text, ...) for the specified recipient with a specified mail type restriction.

  • return: personalized content of the trigger mail.
  • throws: IllegalArgumentException if the preferred mail type is
    1. UNKNOWN
    .
  • throws: BuildException if the recipient could not be found, or the building failed.
  • access: public
the build (recipientId $iRecipientId, [Inx_Api_TriggerMail_TriggerMailingContentType $preferredMailType = null])
  • recipientId $iRecipientId: the id of the recipient for which the trigger mail shall be personalized.
  • preferredMailType $preferredMailType: the mail type.
    1. UNKNOWN
    is not allowed.
close (line 85)

Closes this

  1. TriggerMailingRenderer
and releases any server resources associated with this object.
  1. TriggerMailingRenderer
object <strong>must</strong> be closed once it is not needed anymore to prevent memory leaks and other potentially harmful side effects.

Closes this

  1. TriggerMailingRenderer
and releases any server resources associated with this object. A
  1. TriggerMailingRenderer
object <strong>must</strong> be closed once it is not needed anymore to prevent memory leaks and other potentially harmful side effects.

  • access: public
void close ()
parse (line 66)

Prepares the trigger mailing for a preview.

Prepares the trigger mailing for a preview. It checks the mail integrity (syntax errors, references to orphaned elements, ... ).
Errors will be listed in the

  1. ParseException

The mailingId is supposed to be valid (existing trigger mailing).

  • throws: ParseException if any syntax error is present in the trigger mail.
  • throws: APIException if the trigger mailing id is no longer valid.
  • throws: IllegalArgumentException if the build mode is
    1. UNKNOWN
    .
  • access: public
void parse (mailingId $iMailingId, Inx_Api_TriggerMail_BuildMode $buildMode, [buildMode $iSendingId = null])
  • mailingId $iMailingId: the id of the trigger mailing to be parsed.
  • sendingId $buildMode: the id of the sending of the trigger mailing.
  • buildMode $iSendingId: the mode of the build. The mode
    1. UNKNOWN
    is illegal.

Documentation generated on Thu, 17 Sep 2015 14:27:34 +0200 by phpDocumentor 1.3.2