You are here

class ClientCommand in Heartbeat 8

Hierarchy

Expanded class hierarchy of ClientCommand

1 file declares its use of ClientCommand
StatusForm.php in modules/statusmessage/src/Form/StatusForm.php

File

modules/statusmessage/src/Ajax/ClientCommand.php, line 6

Namespace

Drupal\statusmessage\Ajax
View source
class ClientCommand implements CommandInterface {
  protected $message;
  public function __construct($message) {
    $this->message = $message;
  }
  public function render() {
    return array(
      'command' => 'generatePreview',
      'url' => $this->message,
    );
  }

}

Members

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