r69663 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r69662‎ | r69663 | r69664 >
Date:10:00, 21 July 2010
Author:jeroendedauw
Status:ok
Tags:
Comment:
Style improvements
Modified paths:
  • /trunk/extensions/SemanticMediaWiki/includes/storage/SMW_PrintRequest.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SemanticMediaWiki/includes/storage/SMW_PrintRequest.php
@@ -2,14 +2,17 @@
33 /**
44 * This file contains the class for defining "print requests", i.e. requests for output
55 * informatoin to be included in query results.
 6+ *
67 * @file
78 * @ingroup SMWQuery
 9+ *
810 * @author Markus Krötzsch
911 */
1012
1113 /**
1214 * Container class for request for printout, as used in queries to
1315 * obtain additional information for the retrieved results.
 16+ *
1417 * @ingroup SMWQuery
1518 */
1619 class SMWPrintRequest {
@@ -44,13 +47,16 @@
4548 $this->m_label = $label;
4649 $this->m_data = $data;
4750 $this->m_outputformat = $outputformat;
 51+
4852 if ( ( $mode == SMWPrintRequest::PRINT_CCAT ) && ( $outputformat == false ) ) {
4953 $this->m_outputformat = 'x'; // changed default for Boolean case
5054 }
 55+
5156 if ( $this->m_data instanceof SMWDataValue ) {
5257 // $this->m_data = clone $data; // we assume that the caller denotes the object ot us; else he needs provide us with a clone
5358 $this->m_data->setCaption( $label );
5459 }
 60+
5561 if ( null != $params ) $m_params = $params;
5662 }
5763
@@ -71,6 +77,7 @@
7278 if ( ( $linker === null ) || ( $this->m_label == '' ) ) {
7379 return htmlspecialchars( $this->m_label );
7480 }
 81+
7582 switch ( $this->m_mode ) {
7683 case SMWPrintRequest::PRINT_CATS:
7784 return htmlspecialchars( $this->m_label ); // TODO: link to Special:Categories

Status & tagging log