]> git.mxchange.org Git - core.git/blobdiff - inc/classes/main/criteria/update/class_UpdateCriteria.php
Opps, forgot this.
[core.git] / inc / classes / main / criteria / update / class_UpdateCriteria.php
index 35a2288bc141adc4ed71c5c089850beecf7d36b8..df4470a7211914120079ee322d2eaa65b6cf44d0 100644 (file)
@@ -4,11 +4,11 @@
  * you are looking for a ship or company, or what ever. Instead use this class
  * for looking in storages like the database.
  *
- * @author             Roland Haeder <webmaster@ship-simu.org>
+ * @author             Roland Haeder <webmaster@shipsimu.org>
  * @version            0.0.0
- * @copyright  Copyright (c) 2007 - 2009 Roland Haeder, this is free software
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2015 Core Developer Team
  * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.ship-simu.org
+ * @link               http://www.shipsimu.org
  *
  * 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
  * along with this program. If not, see <http://www.gnu.org/licenses/>.
  */
 class UpdateCriteria extends BaseCriteria implements LocalUpdateCriteria {
-       /**
-        * Criteria to handle
-        */
-       private $updateCriteria = array();
-
-       /**
-        * Limitation for the update
-        */
-       private $limit = 0;
-
-       /**
-        * Skip these entries before using them
-        */
-       private $skip = 0;
-
        /**
         * Protected constructor
         *
@@ -54,7 +39,7 @@ class UpdateCriteria extends BaseCriteria implements LocalUpdateCriteria {
         *
         * @return      $criteriaInstance       An instance of this criteria
         */
-       public final static function createUpdateCriteria () {
+       public static final function createUpdateCriteria () {
                // Get a new instance
                $criteriaInstance = new UpdateCriteria();
 
@@ -62,37 +47,13 @@ class UpdateCriteria extends BaseCriteria implements LocalUpdateCriteria {
                return $criteriaInstance;
        }
 
-       /**
-        * Add criteria
-        *
-        * @param       $criteriaKey    Criteria key
-        * @param       $criteriaValue  Criteria value
-        * @return      void
-        */
-       public function addCriteria ($criteriaKey, $criteriaValue) {
-               $this->updateCriteria[$criteriaKey] = $criteriaValue;
-       }
-
-       /**
-        * Add configured criteria
-        *
-        * @param       $criteriaKey    Criteria key
-        * @param       $configEntry    Configuration entry
-        * @return      void
-        */
-       public function addConfiguredCriteria ($criteriaKey, $configEntry) {
-               // Add the configuration entry as a criteria
-               $value = $this->getConfigInstance()->readConfig($configEntry);
-               $this->addCriteria($criteriaKey, $value);
-       }
-
        /**
         * Getter for update criteria array
         *
         * @return      $updateCriteria         Array holding the update criteria
         */
        public final function getUpdateCriteria () {
-               return $this->updateCriteria;
+               return $this->getCriteriaArray();
        }
 }