Add comment blocks
[civicrm-core.git] / CRM / Event / Tokens.php
index d208b6778770d4f7c1ff6447e9e62c245fc3e93d..2a502554405813ced5cf36641c7bf85184760b48 100644 (file)
@@ -4,7 +4,7 @@
  +--------------------------------------------------------------------+
  | CiviCRM version 4.7                                                |
  +--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2015                                |
+ | Copyright CiviCRM LLC (c) 2004-2017                                |
  +--------------------------------------------------------------------+
  | This file is a part of CiviCRM.                                    |
  |                                                                    |
@@ -40,6 +40,9 @@
  */
 class CRM_Event_Tokens extends \Civi\Token\AbstractTokenSubscriber {
 
+  /**
+   * Class constructor.
+   */
   public function __construct() {
     parent::__construct('event', array(
       'event_type' => ts('Event Type'),
@@ -59,6 +62,9 @@ class CRM_Event_Tokens extends \Civi\Token\AbstractTokenSubscriber {
     ));
   }
 
+  /**
+   * @inheritDoc
+   */
   public function checkActive(\Civi\Token\TokenProcessor $processor) {
     // Extracted from scheduled-reminders code. See the class description.
     return
@@ -66,6 +72,11 @@ class CRM_Event_Tokens extends \Civi\Token\AbstractTokenSubscriber {
       && $processor->context['actionMapping']->getEntity() === 'civicrm_participant';
   }
 
+  /**
+   * Alter action schedule query.
+   *
+   * @param \Civi\ActionSchedule\Event\MailingQueryEvent $e
+   */
   public function alterActionScheduleQuery(\Civi\ActionSchedule\Event\MailingQueryEvent $e) {
     if ($e->mapping->getEntity() !== 'civicrm_participant') {
       return;
@@ -85,15 +96,7 @@ LEFT JOIN civicrm_phone phone ON phone.id = lb.phone_id
   }
 
   /**
-   * Evaluate the content of a single token.
-   *
-   * @param \Civi\Token\TokenRow $row
-   *   The record for which we want token values.
-   * @param string $field
-   *   The name of the token field.
-   * @param mixed $prefetch
-   *   Any data that was returned by the prefetch().
-   * @return mixed
+   * @inheritDoc
    */
   public function evaluateToken(\Civi\Token\TokenRow $row, $entity, $field, $prefetch = NULL) {
     $actionSearchResult = $row->context['actionSearchResult'];