[ Index ]

PHP Cross Reference of MantisBT

title

Body

[close]

/core/classes/ -> MantisFormattingPlugin.class.php (source)

   1  <?php
   2  # MantisBT - A PHP based bugtracking system
   3  
   4  # Copyright (C) 2002 - 2011  MantisBT Team - mantisbt-dev@lists.sourceforge.
   5  
   6  # MantisBT is free software: you can redistribute it and/or modify
   7  # it under the terms of the GNU General Public License as published by
   8  # the Free Software Foundation, either version 2 of the License, or
   9  # (at your option) any later version.
  10  #
  11  # MantisBT is distributed in the hope that it will be useful,
  12  # but WITHOUT ANY WARRANTY; without even the implied warranty of
  13  # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  14  # GNU General Public License for more details.
  15  #
  16  # You should have received a copy of the GNU General Public License
  17  # along with MantisBT.  If not, see <http://www.gnu.org/licenses/>.
  18  
  19  /**
  20   * @copyright Copyright (C) 2000 - 2002  Kenzaburo Ito - kenito@300baud.org
  21   * @copyright Copyright (C) 2002 - 2011  MantisBT Team - mantisbt-dev@lists.sourceforge.net
  22   * @link http://www.mantisbt.org
  23   * @package MantisBT
  24   */
  25  
  26  /**
  27   * Abstract class for any plugin that's modifying textual output.
  28   * @package MantisBT
  29   * @subpackage classes
  30   */
  31  abstract class MantisFormattingPlugin extends MantisPlugin {
  32  
  33      /**
  34       * Event hook declaration.
  35       */
  36  	function hooks() {
  37          return array(
  38              'EVENT_DISPLAY_TEXT'        => 'text',            # Text String Display
  39              'EVENT_DISPLAY_FORMATTED'    => 'formatted',        # Formatted String Display
  40              'EVENT_DISPLAY_RSS'            => 'rss',            # RSS String Display
  41              'EVENT_DISPLAY_EMAIL'        => 'email',            # Email String Display
  42          );
  43      }
  44  
  45      /**
  46       * Plain text processing.
  47       * @param string Event name
  48       * @param string Unformatted text
  49       * @param boolean Multiline text
  50       * @return multi Array with formatted text and multiline paramater
  51       */
  52  	function text( $p_event, $p_string, $p_multiline = true ) {
  53          return $p_string;
  54      }
  55  
  56      /**
  57       * Formatted text processing.
  58       * @param string Event name
  59       * @param string Unformatted text
  60       * @param boolean Multiline text
  61       * @return multi Array with formatted text and multiline paramater
  62       */
  63  	function formatted( $p_event, $p_string, $p_multiline = true ) {
  64          return $p_string;
  65      }
  66  
  67      /**
  68       * RSS text processing.
  69       * @param string Event name
  70       * @param string Unformatted text
  71       * @return string Formatted text
  72       */
  73  	function rss( $p_event, $p_string ) {
  74          return $p_string;
  75      }
  76  
  77      /**
  78       * Email text processing.
  79       * @param string Event name
  80       * @param string Unformatted text
  81       * @return string Formatted text
  82       */
  83  	function email( $p_event, $p_string ) {
  84          return $p_string;
  85      }
  86  }


Generated: Thu Jul 28 15:48:31 2011 Cross-referenced by PHPXref 0.7