r85187 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r85186‎ | r85187 | r85188 >
Date:12:30, 2 April 2011
Author:jeroendedauw
Status:deferred
Tags:
Comment:
adding Validator style param definitions
Modified paths:
  • /trunk/extensions/SemanticMediaWiki/includes/SMW_QueryPrinter.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SemanticMediaWiki/includes/SMW_QueryPrinter.php
@@ -420,6 +420,18 @@
421421 * @return array
422422 */
423423 protected function textDisplayParameters() {
 424+ /*$params = array();
 425+
 426+ $params['intro'] = new Parameter( 'intro' );
 427+ $params['intro']->setDescription( wfMsg( 'smw_paramdesc_intro' ) );
 428+
 429+ $params['outro'] = new Parameter( 'outro' );
 430+ $params['outro']->setDescription( wfMsg( 'smw_paramdesc_outro' ) );
 431+
 432+ $params['default'] = new Parameter( 'default' );
 433+ $params['default']->setDescription( wfMsg( 'smw_paramdesc_default' ) );
 434+
 435+ return $params;*/
424436 return array(
425437 array( 'name' => 'intro', 'type' => 'string', 'description' => wfMsg( 'smw_paramdesc_intro' ) ),
426438 array( 'name' => 'outro', 'type' => 'string', 'description' => wfMsg( 'smw_paramdesc_outro' ) ),
@@ -436,6 +448,14 @@
437449 * @return array
438450 */
439451 protected function exportFormatParameters() {
 452+ /*$params = $this->getParameters();
 453+
 454+ unset( $params['link'] );
 455+
 456+ $params['searchlabel'] = new Parameter( 'searchlabel' );
 457+ $params['searchlabel']->setDescription( wfMsg( 'smw_paramdesc_searchlabel' ) );
 458+
 459+ return $params; */
440460 return array(
441461 array( 'name' => 'limit', 'type' => 'int', 'description' => wfMsg( 'smw_paramdesc_limit' ) ),
442462 array( 'name' => 'headers', 'type' => 'enumeration', 'description' => wfMsg( 'smw_paramdesc_headers' ), 'values' => array( 'show', 'hide', 'plain' ) ),
@@ -454,6 +474,23 @@
455475 * @return array
456476 */
457477 public function getParameters() {
 478+ /*$params = array();
 479+
 480+ $params['limit'] = new Parameter( 'limit', Parameter::TYPE_INTEGER );
 481+ $params['limit']->setDescription( wfMsg( 'smw_paramdesc_limit' ) );
 482+
 483+ $params['headers'] = new Parameter( 'headers' );
 484+ $params['headers']->setDescription( wfMsg( 'smw_paramdesc_headers' ) );
 485+ $params['headers']->addCriteria( new CriterionInArray( 'show', 'hide', 'plain' ) );
 486+
 487+ $params['mainlabel'] = new Parameter( 'mainlabel' );
 488+ $params['mainlabel']->setDescription( wfMsg( 'smw_paramdesc_mainlabel' ) );
 489+
 490+ $params['link'] = new Parameter( 'link' );
 491+ $params['link']->setDescription( wfMsg( 'smw_paramdesc_link' ) );
 492+ $params['link']->addCriteria( new CriterionInArray( 'all', 'subject', 'none' ) );
 493+
 494+ return $params;*/
458495 return array(
459496 array( 'name' => 'limit', 'type' => 'int', 'description' => wfMsg( 'smw_paramdesc_limit' ) ),
460497 array( 'name' => 'headers', 'type' => 'enumeration', 'description' => wfMsg( 'smw_paramdesc_headers' ), 'values' => array( 'show', 'hide', 'plain' ) ),

Follow-up revisions

RevisionCommit summaryAuthorDate
r85214follow up to r85213 and r85187jeroendedauw21:56, 2 April 2011

Status & tagging log