Reformatted some array parameter docs.
[lhc/web/wiklou.git] / includes / Pager.php
index 077430d..29ff894 100644 (file)
@@ -143,7 +143,7 @@ abstract class IndexPager extends ContextSource implements Pager {
                $this->mOffset = $this->mRequest->getText( 'offset' );
 
                # Use consistent behavior for the limit options
-               $this->mDefaultLimit = intval( $this->getUser()->getOption( 'rclimit' ) );
+               $this->mDefaultLimit = $this->getUser()->getIntOption( 'rclimit' );
                if ( !$this->mLimit ) {
                        // Don't override if a subclass calls $this->setLimit() in its constructor.
                        list( $this->mLimit, /* $offset */ ) = $this->mRequest->getLimitOffset();
@@ -269,7 +269,7 @@ abstract class IndexPager extends ContextSource implements Pager {
         * Extract some useful data from the result object for use by
         * the navigation bar, put it into $this
         *
-        * @param $offset String: index offset, inclusive
+        * @param string $offset index offset, inclusive
         * @param $limit Integer: exact query limit
         * @param $res ResultWrapper
         */
@@ -335,7 +335,7 @@ abstract class IndexPager extends ContextSource implements Pager {
         * Do a query with specified parameters, rather than using the object
         * context
         *
-        * @param $offset String: index offset, inclusive
+        * @param string $offset index offset, inclusive
         * @param $limit Integer: exact query limit
         * @param $descending Boolean: query direction, false for ascending, true for descending
         * @return ResultWrapper
@@ -348,7 +348,7 @@ abstract class IndexPager extends ContextSource implements Pager {
        /**
         * Build variables to use by the database wrapper.
         *
-        * @param $offset String: index offset, inclusive
+        * @param string $offset index offset, inclusive
         * @param $limit Integer: exact query limit
         * @param $descending Boolean: query direction, false for ascending, true for descending
         * @return array
@@ -431,9 +431,9 @@ abstract class IndexPager extends ContextSource implements Pager {
        /**
         * Make a self-link
         *
-        * @param $text String: text displayed on the link
-        * @param $query Array: associative array of paramter to be in the query string
-        * @param $type String: value of the "rel" attribute
+        * @param string $text text displayed on the link
+        * @param array $query associative array of paramter to be in the query string
+        * @param string $type value of the "rel" attribute
         *
         * @return String: HTML fragment
         */
@@ -709,7 +709,6 @@ abstract class IndexPager extends ContextSource implements Pager {
        protected function getDefaultDirections() { return false; }
 }
 
-
 /**
  * IndexPager with an alphabetic list and a formatted navigation bar
  * @ingroup Pager
@@ -866,7 +865,7 @@ abstract class ReverseChronologicalPager extends IndexPager {
                if ( $this->mMonth ) {
                        $month = $this->mMonth + 1;
                        // For December, we want January 1 of the next year
-                       if ($month > 12) {
+                       if ( $month > 12 ) {
                                $month = 1;
                                $year++;
                        }
@@ -1048,8 +1047,8 @@ abstract class TablePager extends IndexPager {
         *
         * @protected
         *
-        * @param $field String The column
-        * @param $value String The cell contents
+        * @param string $field The column
+        * @param string $value The cell contents
         * @return Array of attr => value
         */
        function getCellAttrs( $field, $value ) {
@@ -1160,7 +1159,7 @@ abstract class TablePager extends IndexPager {
                        # The pair is either $index => $limit, in which case the $value
                        # will be numeric, or $limit => $text, in which case the $value
                        # will be a string.
-                       if( is_int( $value ) ){
+                       if( is_int( $value ) ) {
                                $limit = $value;
                                $text = $this->getLanguage()->formatNum( $limit );
                        } else {
@@ -1178,7 +1177,7 @@ abstract class TablePager extends IndexPager {
         * Resubmits all defined elements of the query string, except for a
         * blacklist, passed in the $blacklist parameter.
         *
-        * @param $blacklist Array parameters from the request query which should not be resubmitted
+        * @param array $blacklist parameters from the request query which should not be resubmitted
         * @return String: HTML fragment
         */
        function getHiddenFields( $blacklist = array() ) {
@@ -1244,8 +1243,8 @@ abstract class TablePager extends IndexPager {
         *
         * @protected
         *
-        * @param $name String: the database field name
-        * @param $value String: the value retrieved from the database
+        * @param string $name the database field name
+        * @param string $value the value retrieved from the database
         */
        abstract function formatValue( $name, $value );