You are here

public function HeartbeatMessageTemplate::__construct in Heartbeat 6.4

Same name and namespace in other branches
  1. 7 includes/heartbeatmessagetemplate.inc \HeartbeatMessageTemplate::__construct()

Constructor

File

includes/heartbeatmessagetemplate.inc, line 34
HeartbeatMessageTemplate Template object that holds configuration for a message template. A HeartbeatActivity object will be able to have the template as composite.

Class

HeartbeatMessageTemplate
Class HeartbeatMessageTemplate

Code

public function __construct($hid, $message_id, $message, $message_concat, $concat_args) {
  $this->hid = $hid;
  $this->message_id = $message_id;
  $this->message = $message;
  $this->message_concat = $message_concat;
  $this
    ->set_arguments($concat_args);
  if (variable_get('heartbeat_activity_display_tags', 0) == 1) {
    $this->tags = heartbeat_get_available_tags($this->hid);
  }

  // Set a default on the remaining items.
  if (!isset($this->concat_args['show_remaining_items'])) {
    $this->concat_args['show_remaining_items'] = 1;
  }
}