Resolves #60725: Reduce used memory of the Domain Models (Thanks to Tim Lochm├╝ller)
[TYPO3CMS/Extensions/static_info_tables.git] / Classes / Domain / Model / Language.php
index c620f87..b33b01f 100644 (file)
@@ -4,7 +4,7 @@ namespace SJBR\StaticInfoTables\Domain\Model;
 *  Copyright notice
 *
 *  (c) 2011-2012 Armin R├╝diger Vieweg <info@professorweb.de>
-*  (c) 2013 Stanislas Rolland <typo3(arobas)sjbr.ca>
+*  (c) 2013-2014 Stanislas Rolland <typo3(arobas)sjbr.ca>
 *
 *  All rights reserved
 *
@@ -31,6 +31,9 @@ namespace SJBR\StaticInfoTables\Domain\Model;
  * @copyright Copyright belongs to the respective authors
  * @license http://www.gnu.org/licenses/gpl.html GNU General Public License, version 3 or later
  */
+
+use SJBR\StaticInfoTables\Utility\ModelUtility;
+
 class Language extends AbstractEntity {
        /**
         * @var string
@@ -90,8 +93,8 @@ class Language extends AbstractEntity {
         */
        public function initializeObject() {
                parent::initializeObject();
-               $this->tableName = $this->extbaseConfiguration['persistence']['classes']['SJBR\\StaticInfoTables\\Domain\\Model\\Language']['mapping']['tableName'];
-               $this->columnsMapping = $this->extbaseConfiguration['persistence']['classes']['SJBR\\StaticInfoTables\\Domain\\Model\\Language']['mapping']['columns'];
+               $this->tableName = ModelUtility::getModelMapping('SJBR\\StaticInfoTables\\Domain\\Model\\Language', ModelUtility::MAPPING_TABLENAME);
+               $this->columnsMapping = ModelUtility::getModelMapping('SJBR\\StaticInfoTables\\Domain\\Model\\Language', ModelUtility::MAPPING_COLUMNS);
        }
 
        /**
@@ -294,5 +297,4 @@ class Language extends AbstractEntity {
        public function getTypo3Code() {
                return $this->typo3Code;
        }
-}
-?>
\ No newline at end of file
+}
\ No newline at end of file