Merge "setSquidMaxage() globally if we can purge it, instead of in actions."
[lhc/web/wiklou.git] / includes / SiteConfiguration.php
index 469dda8..ff5548e 100644 (file)
@@ -1,17 +1,25 @@
 <?php
-
 /**
- * The include paths change after this file is included from commandLine.inc,
- * meaning that require_once() fails to detect that it is including the same
- * file again. We use DIY C-style protection as a workaround.
+ * Configuration holder, particularly for multi-wiki sites.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
  */
 
-// Hide this pattern from Doxygen, which spazzes out at it
-/// @cond
-if( !defined( 'SITE_CONFIGURATION' ) ){
-define( 'SITE_CONFIGURATION', 1 );
-/// @endcond
-
 /**
  * This is a class used to hold configuration settings, particularly for multi-wiki sites.
  */
@@ -36,12 +44,12 @@ class SiteConfiguration {
         * Array of domains that are local and can be handled by the same server
         */
        public $localVHosts = array();
-       
+
        /**
         * Optional callback to load full configuration data.
         */
        public $fullLoadCallback = null;
-       
+
        /** Whether or not all data has been loaded */
        public $fullLoadDone = false;
 
@@ -218,16 +226,12 @@ class SiteConfiguration {
                return $this->wikis;
        }
 
-       /** A no-op */
-       function initialise() {
-       }
-
        /**
         * Retrieves the value of a given setting, and places it in a variable passed by reference.
         * @param $setting String ID of the setting name to retrieve
         * @param $wiki String Wiki ID of the wiki in question.
         * @param $suffix String The suffix of the wiki in question.
-        * @param $var Reference The variable to insert the value into.
+        * @param $var array Reference The variable to insert the value into.
         * @param $params Array List of parameters. $.'key' is replaced by $value in all returned data.
         * @param $wikiTags Array The tags assigned to the wiki.
         */
@@ -321,7 +325,7 @@ class SiteConfiguration {
        }
 
        /**
-        * Merge params beetween the ones passed to the function and the ones given
+        * Merge params between the ones passed to the function and the ones given
         * by self::$siteParamsCallback for backward compatibility
         * Values returned by self::getWikiParams() have the priority.
         *
@@ -424,4 +428,3 @@ class SiteConfiguration {
                }
        }
 }
-} // End of multiple inclusion guard