You are here

function tmgmt_message_create in Translation Management Tool 7

Same name and namespace in other branches
  1. 8 tmgmt.module \tmgmt_message_create()

Creates a translation job message.

Parameters

$message: (Optional) The message to be saved.

$variables: (Optional) An array of variables to replace in the message on display.

$values: (Optional) An array of additional entity values to be set.

Return value

TMGMTJobItem The created, not yet saved, job item entity.

Related topics

2 calls to tmgmt_message_create()
TMGMTJob::addMessage in entity/tmgmt.entity.job.inc
Add a log message for this job.
TMGMTJobItem::addMessage in entity/tmgmt.entity.job_item.inc
Add a log message for this job item.

File

./tmgmt.module, line 816
Main module file for the Translation Management module.

Code

function tmgmt_message_create($message = '', $variables = array(), $values = array()) {
  return entity_create('tmgmt_message', array_merge($values, array(
    'message' => $message,
    'variables' => $variables,
  )));
}