TMessage Class Reference

Interface for message objects used by MessageCollection. More...

Inheritance diagram for TMessage:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 __construct ($key, $definition)
 Creates new message object.
 key ()
 Get the message key.
 definition ()
 Get the message definition.
 translation ()
 Get the message translation.
 setInfile ($text)
 Set the committed translation.
 infile ()
 Returns the committed translation.
 addTag ($tag)
 Add a tag for this message.
 hasTag ($tag)
 Check if this message has a given tag.
 getTags ()
 Return all tags for this message;.
 setProperty ($key, $value)
 appendProperty ($key, $value)
 getProperty ($key)
 getPropertyNames ()
 Get all the available property names.

Protected Attributes

 $key
   String   Message display key.
 $definition
   String   Message definition.
 $infile
   String   Committed in-file translation.
 $tags = array()
   List of Strings   Message tags.
 $props = array()
   Array   Message properties.
 $reviewers = array()
   List of Strings   Message reviewers.

Detailed Description

Interface for message objects used by MessageCollection.

Definition at line 14 of file Message.php.


Constructor & Destructor Documentation

TMessage::__construct ( key,
definition 
)

Creates new message object.

Parameters:
$key string Unique key identifying this message.
$definition string The authoritave definition of this message.

Definition at line 34 of file Message.php.

Here is the call graph for this function:


Member Function Documentation

TMessage::addTag ( tag  ) 

Add a tag for this message.

Parameters:
$tag   String  

Definition at line 81 of file Message.php.

TMessage::appendProperty ( key,
value 
)

Definition at line 106 of file Message.php.

TMessage::definition (  ) 

Get the message definition.

Returns:
string

Definition at line 51 of file Message.php.

Referenced by __construct().

TMessage::getProperty ( key  ) 

Reimplemented in ThinMessage.

Definition at line 113 of file Message.php.

Referenced by MessageTable::getReviewButton(), and MessageTable::getReviewStatus().

TMessage::getPropertyNames (  ) 

Get all the available property names.

Returns:
array
Since:
2013-01-17

Reimplemented in ThinMessage.

Definition at line 122 of file Message.php.

TMessage::getTags (  ) 

Return all tags for this message;.

Returns:
array of strings

Definition at line 98 of file Message.php.

TMessage::hasTag ( tag  ) 

Check if this message has a given tag.

Parameters:
$tag   String  
Returns:
  Boolean  

Definition at line 90 of file Message.php.

Referenced by MessageTable::getReviewButton().

TMessage::infile (  ) 

Returns the committed translation.

Returns:
string|null

Definition at line 73 of file Message.php.

Referenced by setInfile(), FatMessage::translation(), and ThinMessage::translation().

TMessage::key (  ) 

Get the message key.

Returns:
string

Definition at line 43 of file Message.php.

Referenced by __construct(), and MessageChecker::checkMessage().

TMessage::setInfile ( text  ) 

Set the committed translation.

Parameters:
$text   String  

Definition at line 65 of file Message.php.

Here is the call graph for this function:

TMessage::setProperty ( key,
value 
)

Definition at line 102 of file Message.php.

TMessage::translation (  )  [abstract]

Get the message translation.

Returns:
string|null

Reimplemented in ThinMessage, and FatMessage.


Member Data Documentation

TMessage::$definition [protected]

  String   Message definition.

Definition at line 18 of file Message.php.

Referenced by __construct().

TMessage::$infile [protected]

  String   Committed in-file translation.

Definition at line 20 of file Message.php.

TMessage::$key [protected]

  String   Message display key.

Definition at line 16 of file Message.php.

Referenced by __construct(), appendProperty(), ThinMessage::getProperty(), getProperty(), and setProperty().

TMessage::$props = array() [protected]

  Array   Message properties.

Definition at line 24 of file Message.php.

TMessage::$reviewers = array() [protected]

  List of Strings   Message reviewers.

Definition at line 26 of file Message.php.

TMessage::$tags = array() [protected]

  List of Strings   Message tags.

Definition at line 22 of file Message.php.


The documentation for this class was generated from the following file:
Generated on Tue Oct 29 00:00:55 2013 for MediaWiki Translate Extension by  doxygen 1.6.3