You are here

function Messaging_Message::add_destination in Messaging 7

Same name and namespace in other branches
  1. 6.4 includes/messaging_message.class.inc \Messaging_Message::add_destination()

Add destination object

Parameters

$destination: Destination object

$method: Optional send method, otherwise it will be current method

3 calls to Messaging_Message::add_destination()
Messaging_Message::add_address in ./messaging.message.inc
Add address or array of addresses as destination
Messaging_Message::add_destination_list in ./messaging.message.inc
Add destination list, taking care of duplicated destinations
Messaging_Message::add_user in ./messaging.message.inc
Add user as a destination

File

./messaging.message.inc, line 114
Drupal Messaging Framework - Message class file

Class

Messaging_Message
Message class

Code

function add_destination($destination, $method = NULL) {
  $method = $method ? $method : $this->method;
  $this->destination[$method][$destination
    ->index()] = $destination;
  return $this;
}