You are here

class UpdateFeedCommand in Heartbeat 8

Hierarchy

Expanded class hierarchy of UpdateFeedCommand

2 files declare their use of UpdateFeedCommand
heartbeat.module in ./heartbeat.module
Contains heartbeat.module.
HeartbeatUpdateFeedForm.php in src/Form/HeartbeatUpdateFeedForm.php

File

src/Ajax/UpdateFeedCommand.php, line 14

Namespace

Drupal\heartbeat\Ajax
View source
class UpdateFeedCommand implements CommandInterface {
  protected $message;
  public function __construct($message) {
    $this->message = $message;
  }
  public function render() {
    return array(
      'command' => 'updateFeed',
      'feed' => $this->message->feed,
      'update' => $this->message->update,
      'timestamp' => $this->message->timestamp,
    );
  }

}

Members

Namesort descending Modifiers Type Description Overrides
UpdateFeedCommand::$message protected property
UpdateFeedCommand::render public function Return an array to be run through json_encode and sent to the client. Overrides CommandInterface::render
UpdateFeedCommand::__construct public function