Campaign message sender backend interface

package org.openpsa.directmarketing

 Methods

__construct (array $config, \org_openpsa_directmarketing_campaign_message_dba $message)

Constructor

Parameters

$config

arrayBackend configuration

$message

\org_openpsa_directmarketing_campaign_message_dbaThe message we're working on

add_member_constraints (\midcom_core_querybuilder $qb)

Adds necessary constraints to member QB to find valid entries

Parameters

$qb

\midcom_core_querybuilder&$qb The QB instance to work on

check_results (array $results)

Validate results before send

Parameters

$results

arrayArray of member objects

get_type ()

Backend type, for example 'email' or 'sms'

Returns

string

send (\org_openpsa_contacts_person_dba $person, \org_openpsa_directmarketing_campaign_member_dba $member, string $token, string $subject, string $content, string $from)

This does the actual sending

Parameters

$person

\org_openpsa_contacts_person_dbaThe recipient

$member

\org_openpsa_directmarketing_campaign_member_dbaThe member object

$token

stringMessage token

$subject

stringMessage subject

$content

stringMessage content

$from

stringMessage sender