CRM-16373 - CRM_*_Config - Remove unused component config stuff
authorTim Otten <totten@civicrm.org>
Sat, 15 Aug 2015 11:53:59 +0000 (04:53 -0700)
committerTim Otten <totten@civicrm.org>
Thu, 17 Sep 2015 22:45:01 +0000 (15:45 -0700)
This code seems to generate default value for domain.config_backend.
However, the only one which defined any defaults was CiviMail, and that's
now moved over to `settings/`.

15 files changed:
CRM/Campaign/Config.php [deleted file]
CRM/Case/Config.php [deleted file]
CRM/Contribute/Config.php [deleted file]
CRM/Core/Component.php
CRM/Core/Component/Config.php [deleted file]
CRM/Core/Component/Info.php
CRM/Core/Config.php
CRM/Core/Config/Defaults.php
CRM/Core/Config/Variables.php
CRM/Event/Config.php [deleted file]
CRM/Grant/Config.php [deleted file]
CRM/Mailing/Config.php
CRM/Member/Config.php [deleted file]
CRM/Pledge/Config.php [deleted file]
CRM/Report/Config.php [deleted file]

diff --git a/CRM/Campaign/Config.php b/CRM/Campaign/Config.php
deleted file mode 100644 (file)
index eee0220..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-/*
- +--------------------------------------------------------------------+
- | CiviCRM version 4.7                                                |
- +--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2015                                  |
- +--------------------------------------------------------------------+
- | This file is a part of CiviCRM.                                    |
- |                                                                    |
- | CiviCRM is free software; you can copy, modify, and distribute it  |
- | under the terms of the GNU Affero General Public License           |
- | Version 3, 19 November 2007 and the CiviCRM Licensing Exception.   |
- |                                                                    |
- | CiviCRM 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 Affero General Public License for more details.        |
- |                                                                    |
- | You should have received a copy of the GNU Affero General Public   |
- | License and the CiviCRM Licensing Exception along                  |
- | with this program; if not, contact CiviCRM LLC                     |
- | at info[AT]civicrm[DOT]org. If you have questions about the        |
- | GNU Affero General Public License or the licensing of CiviCRM,     |
- | see the CiviCRM license FAQ at http://civicrm.org/licensing        |
- +--------------------------------------------------------------------+
- */
-
-/**
- * Config handles all the run time configuration changes that the system needs to deal with.
- * Typically we'll have different values for a user's sandbox, a qa sandbox and a production area.
- * The default values in general, should reflect production values (minimizes chances of screwing up)
- *
- * @package CRM
- * @copyright CiviCRM LLC (c) 2004-2015
- */
-class CRM_Campaign_Config extends CRM_Core_Component_Config {
-}
diff --git a/CRM/Case/Config.php b/CRM/Case/Config.php
deleted file mode 100644 (file)
index c01f995..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-<?php
-/*
- +--------------------------------------------------------------------+
- | CiviCRM version 4.7                                                |
- +--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2015                                |
- +--------------------------------------------------------------------+
- | This file is a part of CiviCRM.                                    |
- |                                                                    |
- | CiviCRM is free software; you can copy, modify, and distribute it  |
- | under the terms of the GNU Affero General Public License           |
- | Version 3, 19 November 2007 and the CiviCRM Licensing Exception.   |
- |                                                                    |
- | CiviCRM 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 Affero General Public License for more details.        |
- |                                                                    |
- | You should have received a copy of the GNU Affero General Public   |
- | License and the CiviCRM Licensing Exception along                  |
- | with this program; if not, contact CiviCRM LLC                     |
- | at info[AT]civicrm[DOT]org. If you have questions about the        |
- | GNU Affero General Public License or the licensing of CiviCRM,     |
- | see the CiviCRM license FAQ at http://civicrm.org/licensing        |
- +--------------------------------------------------------------------+
- */
-
-/**
- *
- * Config handles all the run time configuration changes that the system needs to deal with.
- * Typically we'll have different values for a user's sandbox, a qa sandbox and a production area.
- * The default values in general, should reflect production values (minimizes chances of screwing up)
- *
- * @package CRM
- * @copyright CiviCRM LLC (c) 2004-2015
- */
-class CRM_Case_Config extends CRM_Core_Component_Config {
-}
diff --git a/CRM/Contribute/Config.php b/CRM/Contribute/Config.php
deleted file mode 100644 (file)
index aaecca8..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-<?php
-/*
- +--------------------------------------------------------------------+
- | CiviCRM version 4.7                                                |
- +--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2015                                |
- +--------------------------------------------------------------------+
- | This file is a part of CiviCRM.                                    |
- |                                                                    |
- | CiviCRM is free software; you can copy, modify, and distribute it  |
- | under the terms of the GNU Affero General Public License           |
- | Version 3, 19 November 2007 and the CiviCRM Licensing Exception.   |
- |                                                                    |
- | CiviCRM 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 Affero General Public License for more details.        |
- |                                                                    |
- | You should have received a copy of the GNU Affero General Public   |
- | License and the CiviCRM Licensing Exception along                  |
- | with this program; if not, contact CiviCRM LLC                     |
- | at info[AT]civicrm[DOT]org. If you have questions about the        |
- | GNU Affero General Public License or the licensing of CiviCRM,     |
- | see the CiviCRM license FAQ at http://civicrm.org/licensing        |
- +--------------------------------------------------------------------+
- */
-
-/**
- *
- * Config handles all the run time configuration changes that the system needs to deal with.
- * Typically we'll have different values for a user's sandbox, a qa sandbox and a production area.
- * The default values in general, should reflect production values (minimizes chances of screwing up)
- *
- * @package CRM
- * @copyright CiviCRM LLC (c) 2004-2015
- */
-class CRM_Contribute_Config extends CRM_Core_Component_Config {
-}
index c7f08fa9a0de29c4814ec1bce1776abd34bcd4da..3254f0047a68559a6c2d6eb6b7215f5bd29437b1 100644 (file)
@@ -236,22 +236,6 @@ class CRM_Core_Component {
     return $items;
   }
 
-  /**
-   * @param $config
-   * @param bool $oldMode
-   *
-   * @return null
-   */
-  public static function addConfig(&$config, $oldMode = FALSE) {
-    $info = self::_info();
-
-    foreach ($info as $name => $comp) {
-      $cfg = $comp->getConfigObject();
-      $cfg->add($config, $oldMode);
-    }
-    return NULL;
-  }
-
   /**
    * @param string $componentName
    *
diff --git a/CRM/Core/Component/Config.php b/CRM/Core/Component/Config.php
deleted file mode 100644 (file)
index 8fd866a..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-<?php
-/*
- +--------------------------------------------------------------------+
- | CiviCRM version 4.7                                                |
- +--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2015                                |
- +--------------------------------------------------------------------+
- | This file is a part of CiviCRM.                                    |
- |                                                                    |
- | CiviCRM is free software; you can copy, modify, and distribute it  |
- | under the terms of the GNU Affero General Public License           |
- | Version 3, 19 November 2007 and the CiviCRM Licensing Exception.   |
- |                                                                    |
- | CiviCRM 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 Affero General Public License for more details.        |
- |                                                                    |
- | You should have received a copy of the GNU Affero General Public   |
- | License and the CiviCRM Licensing Exception along                  |
- | with this program; if not, contact CiviCRM LLC                     |
- | at info[AT]civicrm[DOT]org. If you have questions about the        |
- | GNU Affero General Public License or the licensing of CiviCRM,     |
- | see the CiviCRM license FAQ at http://civicrm.org/licensing        |
- +--------------------------------------------------------------------+
- */
-
-/**
- * This abstract class provides the framework for component configuration
- * and provides aggregation methods for injecting it into system config.
- *
- * @package CRM
- * @copyright CiviCRM LLC (c) 2004-2015
- * $Id$
- *
- */
-abstract class CRM_Core_Component_Config {
-
-  /**
-   * Gets the list of class variables from specific component's
-   * configuration file and injects them into system wide
-   * configuration object.
-   *
-   * @param CRM_Core_Config $config
-   * @param $oldMode
-   */
-  public function add($config, $oldMode) {
-    foreach (get_class_vars(get_class($this)) as $key => $value) {
-      $config->$key = $value;
-    }
-  }
-
-  /**
-   * @param array $defaults
-   */
-  public function setDefaults(&$defaults) {
-    foreach (get_class_vars(get_class($this)) as $key => $value) {
-      if (!isset($defaults[$key])) {
-        $defaults[$key] = $value;
-      }
-    }
-  }
-
-}
index 887af332a96d9ca676bc2a0b63d5cd1c1b560303..f2b600c7204ffe13dd50b04a920aa1ec7d513480 100644 (file)
@@ -42,12 +42,6 @@ abstract class CRM_Core_Component_Info {
    */
   const COMPONENT_INVOKE_CLASS = 'Invoke';
 
-  /**
-   * Name of the class (minus component namespace path)
-   * of the component configuration class'es name.
-   */
-  const COMPONENT_CONFIG_CLASS = 'Config';
-
   /**
    * Name of the class (minus component namespace path)
    * of the component BAO Query class'es name.
@@ -240,16 +234,6 @@ abstract class CRM_Core_Component_Info {
     return FALSE;
   }
 
-  /**
-   * Provides component's configuration object.
-   *
-   * @return mixed
-   *   component's configuration object
-   */
-  public function getConfigObject() {
-    return $this->_instantiate(self::COMPONENT_CONFIG_CLASS);
-  }
-
   /**
    * Provides component's menu definition object.
    *
index 74be9981bc123b88d814b12afddbf4490163dfcf..0d6e5f80c747359e2beeca98adaa965ddb45a53d 100644 (file)
@@ -440,9 +440,6 @@ class CRM_Core_Config extends CRM_Core_Config_Variables {
       // retrieve directory and url preferences also
       CRM_Core_BAO_Setting::retrieveDirectoryAndURLPreferences($variables);
 
-      // add component specific settings
-      $this->componentRegistry->addConfig($this);
-
       // serialise settings
       $settings = $variables;
       CRM_Core_BAO_ConfigSetting::add($settings);
index 26d652a7093a356cf225bfc5ae5096c31210b42e..b21a1f7bf09ce0bf632ddb7cd91e2a6535d196ef 100644 (file)
@@ -187,16 +187,6 @@ class CRM_Core_Config_Defaults {
     if (isset($_GET[$config->userFrameworkURLVar])) {
       $args = explode('/', $_GET[$config->userFrameworkURLVar]);
     }
-
-    if (isset($defaults['enableComponents'])) {
-      foreach ($defaults['enableComponents'] as $key => $name) {
-        $comp = $config->componentRegistry->get($name);
-        if ($comp) {
-          $co = $comp->getConfigObject();
-          $co->setDefaults($defaults);
-        }
-      }
-    }
   }
 
 }
index 07d34def92b079685ee5f779c4f3359575f04ecb..baf6c6f4db51f3411b4b4ffb194a241559894a1f 100644 (file)
@@ -411,6 +411,8 @@ class CRM_Core_Config_Variables extends CRM_Core_Config_Defaults {
    */
   public $wpBasePage = NULL;
 
+  public $verpSeparator = '.', $mailThrottleTime = 0, $mailerJobsMax = 0, $mailerJobSize = 0, $mailerBatchLimit = 0;
+
   /**
    * Provide addressSequence.
    *
diff --git a/CRM/Event/Config.php b/CRM/Event/Config.php
deleted file mode 100644 (file)
index 5febd35..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-<?php
-/*
- +--------------------------------------------------------------------+
- | CiviCRM version 4.7                                                |
- +--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2015                                  |
- +--------------------------------------------------------------------+
- | This file is a part of CiviCRM.                                    |
- |                                                                    |
- | CiviCRM is free software; you can copy, modify, and distribute it  |
- | under the terms of the GNU Affero General Public License           |
- | Version 3, 19 November 2007 and the CiviCRM Licensing Exception.   |
- |                                                                    |
- | CiviCRM 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 Affero General Public License for more details.        |
- |                                                                    |
- | You should have received a copy of the GNU Affero General Public   |
- | License and the CiviCRM Licensing Exception along                  |
- | with this program; if not, contact CiviCRM LLC                     |
- | at info[AT]civicrm[DOT]org. If you have questions about the        |
- | GNU Affero General Public License or the licensing of CiviCRM,     |
- | see the CiviCRM license FAQ at http://civicrm.org/licensing        |
- +--------------------------------------------------------------------+
- */
-
-/**
- * Config handles all the run time configuration changes that the system needs to deal with.
- * Typically we'll have different values for a user's sandbox, a qa sandbox and a production area.
- * The default values in general, should reflect production values (minimizes chances of screwing up)
- *
- * @package CRM
- * @copyright CiviCRM LLC (c) 2004-2015
- * $Id$
- *
- */
-class CRM_Event_Config extends CRM_Core_Component_Config {
-}
diff --git a/CRM/Grant/Config.php b/CRM/Grant/Config.php
deleted file mode 100644 (file)
index bc59740..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?php
-/*
- +--------------------------------------------------------------------+
- | CiviCRM version 4.7                                                |
- +--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2015                                |
- +--------------------------------------------------------------------+
- | This file is a part of CiviCRM.                                    |
- |                                                                    |
- | CiviCRM is free software; you can copy, modify, and distribute it  |
- | under the terms of the GNU Affero General Public License           |
- | Version 3, 19 November 2007 and the CiviCRM Licensing Exception.   |
- |                                                                    |
- | CiviCRM 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 Affero General Public License for more details.        |
- |                                                                    |
- | You should have received a copy of the GNU Affero General Public   |
- | License and the CiviCRM Licensing Exception along                  |
- | with this program; if not, contact CiviCRM LLC                     |
- | at info[AT]civicrm[DOT]org. If you have questions about the        |
- | GNU Affero General Public License or the licensing of CiviCRM,     |
- | see the CiviCRM license FAQ at http://civicrm.org/licensing        |
- +--------------------------------------------------------------------+
- */
-
-/**
- *
- * @package CRM
- * @copyright CiviCRM LLC (c) 2004-2015
- * $Id$
- *
- */
-class CRM_Grant_Config extends CRM_Core_Component_Config {
-}
index 30808a4bbd1cc3638ded3a219dd1ccee0cbc1962..19c9a7dbe517e675bb1f9dd79f4c8a2d24f51419 100644 (file)
@@ -32,7 +32,7 @@
  * $Id$
  *
  */
-class CRM_Mailing_Config extends CRM_Core_Component_Config {
+class CRM_Mailing_Config {
 
   const OUTBOUND_OPTION_SMTP = 0;
   const OUTBOUND_OPTION_SENDMAIL = 1;
diff --git a/CRM/Member/Config.php b/CRM/Member/Config.php
deleted file mode 100644 (file)
index 4753718..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?php
-/*
- +--------------------------------------------------------------------+
- | CiviCRM version 4.7                                                |
- +--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2015                                |
- +--------------------------------------------------------------------+
- | This file is a part of CiviCRM.                                    |
- |                                                                    |
- | CiviCRM is free software; you can copy, modify, and distribute it  |
- | under the terms of the GNU Affero General Public License           |
- | Version 3, 19 November 2007 and the CiviCRM Licensing Exception.   |
- |                                                                    |
- | CiviCRM 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 Affero General Public License for more details.        |
- |                                                                    |
- | You should have received a copy of the GNU Affero General Public   |
- | License and the CiviCRM Licensing Exception along                  |
- | with this program; if not, contact CiviCRM LLC                     |
- | at info[AT]civicrm[DOT]org. If you have questions about the        |
- | GNU Affero General Public License or the licensing of CiviCRM,     |
- | see the CiviCRM license FAQ at http://civicrm.org/licensing        |
- +--------------------------------------------------------------------+
- */
-
-/**
- *
- * @package CRM
- * @copyright CiviCRM LLC (c) 2004-2015
- * $Id$
- *
- */
-class CRM_Member_Config extends CRM_Core_Component_Config {
-}
diff --git a/CRM/Pledge/Config.php b/CRM/Pledge/Config.php
deleted file mode 100644 (file)
index 2957cea..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-<?php
-/*
- +--------------------------------------------------------------------+
- | CiviCRM version 4.7                                                |
- +--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2015                                  |
- +--------------------------------------------------------------------+
- | This file is a part of CiviCRM.                                    |
- |                                                                    |
- | CiviCRM is free software; you can copy, modify, and distribute it  |
- | under the terms of the GNU Affero General Public License           |
- | Version 3, 19 November 2007 and the CiviCRM Licensing Exception.   |
- |                                                                    |
- | CiviCRM 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 Affero General Public License for more details.        |
- |                                                                    |
- | You should have received a copy of the GNU Affero General Public   |
- | License and the CiviCRM Licensing Exception along                  |
- | with this program; if not, contact CiviCRM LLC                     |
- | at info[AT]civicrm[DOT]org. If you have questions about the        |
- | GNU Affero General Public License or the licensing of CiviCRM,     |
- | see the CiviCRM license FAQ at http://civicrm.org/licensing        |
- +--------------------------------------------------------------------+
- */
-
-/**
- * Config handles all the run time configuration changes that the system needs to deal with.
- * Typically we'll have different values for a user's sandbox, a qa sandbox and a production area.
- * The default values in general, should reflect production values (minimizes chances of screwing up)
- *
- * @package CRM
- * @copyright CiviCRM LLC (c) 2004-2015
- * $Id$
- *
- */
-class CRM_Pledge_Config extends CRM_Core_Component_Config {
-}
diff --git a/CRM/Report/Config.php b/CRM/Report/Config.php
deleted file mode 100644 (file)
index 5636307..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-<?php
-/*
- +--------------------------------------------------------------------+
- | CiviCRM version 4.7                                                |
- +--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2015                                |
- +--------------------------------------------------------------------+
- | This file is a part of CiviCRM.                                    |
- |                                                                    |
- | CiviCRM is free software; you can copy, modify, and distribute it  |
- | under the terms of the GNU Affero General Public License           |
- | Version 3, 19 November 2007 and the CiviCRM Licensing Exception.   |
- |                                                                    |
- | CiviCRM 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 Affero General Public License for more details.        |
- |                                                                    |
- | You should have received a copy of the GNU Affero General Public   |
- | License and the CiviCRM Licensing Exception along                  |
- | with this program; if not, contact CiviCRM LLC                     |
- | at info[AT]civicrm[DOT]org. If you have questions about the        |
- | GNU Affero General Public License or the licensing of CiviCRM,     |
- | see the CiviCRM license FAQ at http://civicrm.org/licensing        |
- +--------------------------------------------------------------------+
- */
-
-/**
- *
- * Config handles all the run time configuration changes that the system needs to deal with.
- * Typically we'll have different values for a user's sandbox, a qa sandbox and a production area.
- * The default values in general, should reflect production values (minimizes chances of screwing up)
- *
- * @package CRM
- * @copyright CiviCRM LLC (c) 2004-2015
- * $Id$
- *
- */
-class CRM_Report_Config extends CRM_Core_Component_Config {
-}