DatabaseRowsUpdateWizard implements UpgradeWizardInterface, RepeatableInterface

This is a generic updater to migrate content of TCA rows.

Multiple classes implementing interface "RowUpdateInterface" can be registered here, each for a specific update purpose.

The updater fetches each row of all TCA registered tables and visits the client classes who may modify the row content.

The updater remembers for each class if it run through, so the updater will be shown again if a new updater class is registered that has not been run yet.

A start position pointer is stored in the registry that is updated during the run process, so if for instance the PHP process runs into a timeout, the job can restart at the position it stopped.

Internal

This class is only meant to be used within EXT:install and is not part of the TYPO3 Core API.

Attributes
#[UpgradeWizard]
'databaseRowsUpdateWizard'

Table of Contents

Interfaces

UpgradeWizardInterface
Interface UpgradeWizardInterface
RepeatableInterface
Use if wizard may be run multiple times (and should not be disabled after one run)

Properties

$rowUpdater  : array<string|int, mixed>

Methods

executeUpdate()  : bool
Performs the configuration update.
getAvailableRowUpdater()  : array<string|int, string>
getDescription()  : string
Return the description for this wizard
getPrerequisites()  : array<string|int, string>
Returns an array of class names of Prerequisite classes
getTitle()  : string
Return the speaking name of this wizard
updateNecessary()  : bool
Is an update necessary?
getRowUpdatersToExecute()  : array<string|int, mixed>
Return an array of class names that are not yet marked as done.
getStartPosition()  : array<string|int, mixed>
Return an array with table / uid combination that specifies the start position the update row process should start with.
setRowUpdaterExecuted()  : mixed
Mark a single updater as done
updateOrDeleteRow()  : void

Properties

$rowUpdater

protected array<string|int, mixed> $rowUpdater = [\TYPO3\CMS\Install\Updates\RowUpdater\SysRedirectRootPageMoveMigration::class]

Single classes that may update rows

Methods

executeUpdate()

Performs the configuration update.

public executeUpdate() : bool
Tags
throws
ConnectionException
throws
Exception
Return values
bool

getAvailableRowUpdater()

public getAvailableRowUpdater() : array<string|int, string>
Internal
Return values
array<string|int, string>

getDescription()

Return the description for this wizard

public getDescription() : string
Tags
throws
RuntimeException
Return values
string

Longer description of this updater

getPrerequisites()

Returns an array of class names of Prerequisite classes

public getPrerequisites() : array<string|int, string>
Return values
array<string|int, string>

All new fields and tables must exist

getTitle()

Return the speaking name of this wizard

public getTitle() : string
Return values
string

Title of this updater

updateNecessary()

Is an update necessary?

public updateNecessary() : bool
Return values
bool

True if at least one row updater is not marked done

getRowUpdatersToExecute()

Return an array of class names that are not yet marked as done.

protected getRowUpdatersToExecute() : array<string|int, mixed>
Return values
array<string|int, mixed>

Class names

getStartPosition()

Return an array with table / uid combination that specifies the start position the update row process should start with.

protected getStartPosition(string $firstTable) : array<string|int, mixed>
Parameters
$firstTable : string

Table name of the first TCA in case the start position needs to be initialized

Return values
array<string|int, mixed>

New start position

updateOrDeleteRow()

protected updateOrDeleteRow(Connection $connectionForTable, Connection $connectionForSysRegistry, string $table, int $uid, array<string|int, mixed> $updatedFields, array<string|int, mixed> $startPosition) : void
Parameters
$connectionForTable : Connection
$connectionForSysRegistry : Connection
$table : string
$uid : int
$updatedFields : array<string|int, mixed>
$startPosition : array<string|int, mixed>

        
On this page

Search results