PHP Class DmitryDulepov\Realurl\ext_update

Author: Dmitry Dulepov ([email protected])
Show file Open project: dmitryd/typo3-realurl

Protected Properties

Property Type Description
$databaseConnection TYPO3\CMS\Core\Database\DatabaseConnection

Public Methods

Method Description
__construct ( ) Creates the instance of the class.
access ( ) : boolean Checks if the script should execute. We check for everything except table structure.
main ( ) Runs the update.

Protected Methods

Method Description
checkAndRenameTables ( ) Checks and renames *cache tables to *data tables.
checkAndUpdatePathCachePrimaryKey ( ) : void Checks if the primary key needs updates (this is something that TYPO3 sql parser fails to do for years) and does necessary changes.
getLocker ( ) : TYPO3\CMS\Core\Locking\Locker | TYPO3\CMS\Core\Locking\LockingStrategyInterface Obtains the locker depending on the TYPO3 version.
hasOldCacheTables ( )
pathCacheNeedsUpdates ( ) : boolean Checks if path cache table is ok.
removeUrlDataEntriesWithIgnoredParameters ( ) Removes entries with parameters that should be ignored.
updateRealurlTableStructure ( ) : void Updates realurl table structure. The code is copied almost 1:1 from ExtensionManagerTables class.

Method Details

__construct() public method

Creates the instance of the class.
public __construct ( )

access() public method

Checks if the script should execute. We check for everything except table structure.
public access ( ) : boolean
return boolean

checkAndRenameTables() protected method

Checks and renames *cache tables to *data tables.
protected checkAndRenameTables ( )

checkAndUpdatePathCachePrimaryKey() protected method

Checks if the primary key needs updates (this is something that TYPO3 sql parser fails to do for years) and does necessary changes.

getLocker() protected method

Obtains the locker depending on the TYPO3 version.
protected getLocker ( ) : TYPO3\CMS\Core\Locking\Locker | TYPO3\CMS\Core\Locking\LockingStrategyInterface
return TYPO3\CMS\Core\Locking\Locker | TYPO3\CMS\Core\Locking\LockingStrategyInterface

hasOldCacheTables() protected method

protected hasOldCacheTables ( )

main() public method

Runs the update.
public main ( )

pathCacheNeedsUpdates() protected method

Checks if path cache table is ok.
protected pathCacheNeedsUpdates ( ) : boolean
return boolean

removeUrlDataEntriesWithIgnoredParameters() protected method

Removes entries with parameters that should be ignored.

updateRealurlTableStructure() protected method

We ignore any errors because nothing can be done about those really. The client will have to do database update anyway, so he will see all failed queries.
protected updateRealurlTableStructure ( ) : void
return void

Property Details

$databaseConnection protected property

protected DatabaseConnection,TYPO3\CMS\Core\Database $databaseConnection
return TYPO3\CMS\Core\Database\DatabaseConnection