‪TYPO3CMS  ‪main
TYPO3\CMS\Impexp\ImportExport Class Reference
Inheritance diagram for TYPO3\CMS\Impexp\ImportExport:
TYPO3\CMS\Impexp\Export TYPO3\CMS\Impexp\Import

Public Member Functions

 __construct ()
 
array renderPreview ()
 
 addFiles (array $relations, array &$lines, int $indent, string $tokenID='')
 
 getOrCreateTemporaryFolderName ()
 
 removeTemporaryFolderName ()
 
 getOrCreateDefaultImportExportFolder ()
 
 removeDefaultImportExportFolder ()
 
 hasErrors ()
 
 getPid ()
 
 setPid (int $pid)
 
 setExcludeDisabledRecords (bool $excludeDisabledRecords)
 
 isExcludeDisabledRecords ()
 
 getExcludeMap ()
 
 setExcludeMap (array $excludeMap)
 
 getSoftrefCfg ()
 
 setSoftrefCfg (array $softrefCfg)
 
 getExtensionDependencies ()
 
 setExtensionDependencies (array $extensionDependencies)
 
 isShowStaticRelations ()
 
 setShowStaticRelations (bool $showStaticRelations)
 
 getRelStaticTables ()
 
 setRelStaticTables (array $relStaticTables)
 
 getErrorLog ()
 
 setErrorLog (array $errorLog)
 
 isUpdate ()
 
 setUpdate (bool $update)
 
 getImportMode ()
 
 setImportMode (array $importMode)
 
 isGlobalIgnorePid ()
 
 setGlobalIgnorePid (bool $globalIgnorePid)
 
 isForceAllUids ()
 
 setForceAllUids (bool $forceAllUids)
 
 isShowDiff ()
 
 setShowDiff (bool $showDiff)
 
 getSoftrefInputValues ()
 
 setSoftrefInputValues (array $softrefInputValues)
 
 getMode ()
 
 setMode (string $mode)
 
 getImportMapId ()
 
 setImportMapId (array $importMapId)
 
 getDat ()
 

Protected Member Functions

 traversePageTree (array $pageTree, array &$lines, int $indent=0)
 
bool isRecordDisabled (string $table, int $uid)
 
 excludePageAndRecords (int $pageUid, array $page)
 
 traversePageRecords (array $pageTree, array &$lines)
 
 traverseAllRecords (array $pageTree, array &$lines)
 
 addGeneralErrorsByTable (string $table)
 
 addRecord (string $table, int $uid, array &$lines, int $indent, bool $checkImportInPidRecord=false)
 
 addRelations (array $relations, array &$lines, int $indent, array $recursionCheck=[])
 
 addSoftRefs (array $softrefs, array &$lines, int $indent)
 
 renderIndent (int $indent)
 
bool checkDokType (string $table, int $dokType)
 
string renderControls (array $line)
 
string renderRecordExcludeCheckbox (string $recordRef)
 
string renderSoftRefImportTextField (array $softref)
 
string renderSoftRefExportSelector (array $softref)
 
string renderImportModeSelector (string $table, int $uid, bool $doesRecordExist)
 
string renderSelectBox (string $name, string $value, array $options)
 
 createTemporaryFolderName ()
 
 createDefaultImportExportFolder ()
 
 getDefaultUploadTemporaryFolder ()
 
string null resolveStoragePath (string $dirPrefix, bool $checkAlternatives=true)
 
 flatInversePageTree (array $pageTree, array &$list, int $pid=-1)
 
bool isTableStatic (string $table)
 
bool isRecordExcluded (string $table, int $uid)
 
bool isSoftRefIncluded (string $tokenID)
 
array null getRecordFromDatabase (string $table, int $uid, string $fields='uid, pid')
 
string getRecordPath (int $pid)
 
string compareRecords (array $databaseRecord, array $importRecord, string $table, bool $inverse=false)
 
DiffUtility getDiffUtility ()
 
ExtendedFileUtility getFileProcObj ()
 
 addError (string $message)
 
 getBackendUser ()
 
 getLanguageService ()
 
 getPidRecord ()
 

Protected Attributes

string $mode = ''
 
string $permsClause
 
int $pid = -1
 
array $pidRecord = null
 
bool $showStaticRelations = false
 
bool $update = false
 
bool $doesImport = false
 
array $importMode = []
 
bool $globalIgnorePid = false
 
bool $forceAllUids = false
 
bool $showDiff = false
 
array $softrefInputValues = []
 
array $fileIdMap = []
 
array $relStaticTables = []
 
array $excludeMap = []
 
array $softrefCfg = []
 
array $extensionDependencies = []
 
array $importMapId = []
 
array $errorLog = []
 
array $cacheGetRecordPath = []
 
array $dat = []
 
ExtendedFileUtility $fileProcObj = null
 
DiffUtility $diffUtility = null
 
array $remainHeader = []
 
LanguageService $lang
 
IconFactory $iconFactory
 
string $temporaryFolderName = null
 
Folder $defaultImportExportFolder = null
 
bool $excludeDisabledRecords = false
 

Detailed Description

T3D file Import / Export library (TYPO3 Record Document)

This class is not considered part of the public TYPO3 API.

Definition at line 45 of file ImportExport.php.

Constructor & Destructor Documentation

◆ __construct()

Member Function Documentation

◆ addError()

◆ addFiles()

TYPO3\CMS\Impexp\ImportExport::addFiles ( array  $relations,
array &  $lines,
int  $indent,
string  $tokenID = '' 
)

Add file relations of a record to the preview.

Public access for testing purpose only.

Parameters
array$relations‪Array of file IDs
array$lines‪Output lines array
int$indent‪Indentation level
string$tokenID‪Token ID if this is a soft reference (in which case it only makes sense with a single element in the $relations array!)
See also
addRecord()

Definition at line 588 of file ImportExport.php.

References TYPO3\CMS\Impexp\ImportExport\$fileProcObj, TYPO3\CMS\Impexp\ImportExport\addError(), TYPO3\CMS\Core\Utility\PathUtility\dirname(), TYPO3\CMS\Impexp\ImportExport\getFileProcObj(), TYPO3\CMS\Core\Core\Environment\getPublicPath(), TYPO3\CMS\Impexp\ImportExport\isSoftRefIncluded(), TYPO3\CMS\Impexp\ImportExport\renderIndent(), TYPO3\CMS\Impexp\ImportExport\resolveStoragePath(), and TYPO3\CMS\Core\Utility\PathUtility\stripPathSitePrefix().

Referenced by TYPO3\CMS\Impexp\Tests\Functional\ExportTest\addFilesSucceeds(), TYPO3\CMS\Impexp\ImportExport\addRecord(), and TYPO3\CMS\Impexp\ImportExport\addSoftRefs().

◆ addGeneralErrorsByTable()

TYPO3\CMS\Impexp\ImportExport::addGeneralErrorsByTable ( string  $table)
protected

Log general error message for a given table

Parameters
string$table‪database table name

Definition at line 358 of file ImportExport.php.

References TYPO3\CMS\Impexp\ImportExport\addError().

Referenced by TYPO3\CMS\Impexp\ImportExport\traverseAllRecords(), TYPO3\CMS\Impexp\Import\writeRecords(), and TYPO3\CMS\Impexp\Import\writeSysFileRecords().

◆ addRecord()

TYPO3\CMS\Impexp\ImportExport::addRecord ( string  $table,
int  $uid,
array &  $lines,
int  $indent,
bool  $checkImportInPidRecord = false 
)
protected

◆ addRelations()

TYPO3\CMS\Impexp\ImportExport::addRelations ( array  $relations,
array &  $lines,
int  $indent,
array  $recursionCheck = [] 
)
protected

◆ addSoftRefs()

TYPO3\CMS\Impexp\ImportExport::addSoftRefs ( array  $softrefs,
array &  $lines,
int  $indent 
)
protected

◆ checkDokType()

bool TYPO3\CMS\Impexp\ImportExport::checkDokType ( string  $table,
int  $dokType 
)
protected

Verifies that a table is allowed on a certain doktype of a page.

Parameters
string$table‪Table name to check
int$dokType‪Page doktype
Returns
‪bool TRUE if OK

Definition at line 783 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\addRecord().

◆ compareRecords()

string TYPO3\CMS\Impexp\ImportExport::compareRecords ( array  $databaseRecord,
array  $importRecord,
string  $table,
bool  $inverse = false 
)
protected

Compares two records, the current database record and the one from the import memory. Will return HTML code to show any differences between them!

Parameters
array$databaseRecord‪Database record, all fields (old values)
array$importRecordImport memory record for the same table/uid, all fields (new values)
string$table‪The table name of the record
bool$inverse‪Inverse the diff view (switch red/green, needed for pre-update difference view)
Returns
‪string HTML

Definition at line 1209 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\addRecord().

◆ createDefaultImportExportFolder()

TYPO3\CMS\Impexp\ImportExport::createDefaultImportExportFolder ( )
protected

Creates a \TYPO3\CMS\Core\Resource\Folder object for saving export files to the server and is also used for uploading import files.

Definition at line 1037 of file ImportExport.php.

◆ createTemporaryFolderName()

TYPO3\CMS\Impexp\ImportExport::createTemporaryFolderName ( )
protected

Definition at line 998 of file ImportExport.php.

◆ excludePageAndRecords()

TYPO3\CMS\Impexp\ImportExport::excludePageAndRecords ( int  $pageUid,
array  $page 
)
protected

Exclude a page, its sub pages (recursively) and records placed in them from this import/export

Parameters
int$pageUid‪Uid of the page to exclude
array$page‪Page array with uid/subrow (from ->dat[header][pagetree])

Definition at line 290 of file ImportExport.php.

References TYPO3\CMS\Webhooks\Message\$uid.

Referenced by TYPO3\CMS\Impexp\ImportExport\traversePageTree().

◆ flatInversePageTree()

TYPO3\CMS\Impexp\ImportExport::flatInversePageTree ( array  $pageTree,
array &  $list,
int  $pid = -1 
)
protected

Recursively flattening the $pageTree array to a one-dimensional array with uid-pid pairs.

Parameters
array$pageTree‪Page tree array
array$list‪List with uid-pid pairs
int$pid‪PID value (internal, don't set from outside)

Definition at line 1120 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\Export\process(), TYPO3\CMS\Impexp\Import\writePages(), TYPO3\CMS\Impexp\Import\writePagesOrder(), and TYPO3\CMS\Impexp\Import\writeRecordsOrder().

◆ getBackendUser()

◆ getDat()

TYPO3\CMS\Impexp\ImportExport::getDat ( )

Definition at line 1524 of file ImportExport.php.

◆ getDefaultUploadTemporaryFolder()

TYPO3\CMS\Impexp\ImportExport::getDefaultUploadTemporaryFolder ( )
protected

Returns a \TYPO3\CMS\Core\Resource\Folder object that could be used for uploading temporary files in user context. The folder temp below the default upload folder of the user is used.

Definition at line 1057 of file ImportExport.php.

◆ getDiffUtility()

DiffUtility TYPO3\CMS\Impexp\ImportExport::getDiffUtility ( )
protected

Returns string comparing object, initialized only once.

Returns
‪DiffUtility String comparing object

Definition at line 1283 of file ImportExport.php.

◆ getErrorLog()

TYPO3\CMS\Impexp\ImportExport::getErrorLog ( )

Definition at line 1434 of file ImportExport.php.

◆ getExcludeMap()

TYPO3\CMS\Impexp\ImportExport::getExcludeMap ( )

Definition at line 1384 of file ImportExport.php.

◆ getExtensionDependencies()

TYPO3\CMS\Impexp\ImportExport::getExtensionDependencies ( )

Definition at line 1404 of file ImportExport.php.

◆ getFileProcObj()

ExtendedFileUtility TYPO3\CMS\Impexp\ImportExport::getFileProcObj ( )
protected

Returns file processing object, initialized only once.

Returns
‪ExtendedFileUtility File processor object

Definition at line 1296 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\addFiles(), TYPO3\CMS\Impexp\Import\processSoftReferencesSaveFileCreateRelFile(), and TYPO3\CMS\Impexp\Import\writeFileVerify().

◆ getImportMapId()

TYPO3\CMS\Impexp\ImportExport::getImportMapId ( )

Definition at line 1514 of file ImportExport.php.

◆ getImportMode()

TYPO3\CMS\Impexp\ImportExport::getImportMode ( )

Definition at line 1454 of file ImportExport.php.

◆ getLanguageService()

TYPO3\CMS\Impexp\ImportExport::getLanguageService ( )
protected

Definition at line 1329 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\__construct().

◆ getMode()

TYPO3\CMS\Impexp\ImportExport::getMode ( )

Definition at line 1504 of file ImportExport.php.

◆ getOrCreateDefaultImportExportFolder()

TYPO3\CMS\Impexp\ImportExport::getOrCreateDefaultImportExportFolder ( )

Returns a \TYPO3\CMS\Core\Resource\Folder object for saving export files to the server and is also used for uploading import files.

Definition at line 1025 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\Controller\ImportController\getSelectableFileList(), and TYPO3\CMS\Impexp\Export\saveToFile().

◆ getOrCreateTemporaryFolderName()

TYPO3\CMS\Impexp\ImportExport::getOrCreateTemporaryFolderName ( )

◆ getPid()

TYPO3\CMS\Impexp\ImportExport::getPid ( )

Definition at line 1334 of file ImportExport.php.

◆ getPidRecord()

TYPO3\CMS\Impexp\ImportExport::getPidRecord ( )
protected

Return record of root page of import or of export page tree

  • ‪or null if access denied to that page.

If the page is the root of the page tree, add some basic but missing information.

Definition at line 1352 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\addRecord().

◆ getRecordFromDatabase()

array null TYPO3\CMS\Impexp\ImportExport::getRecordFromDatabase ( string  $table,
int  $uid,
string  $fields = 'uid,
pid'   
)
protected

Returns given fields of record if it exists.

Parameters
string$table‪Table name
int$uid‪UID of record
string$fields‪Field list to select. Default is "uid,pid"
Returns
‪array|null Result of \TYPO3\CMS\Backend\Utility\BackendUtility::getRecord() which means the record if found, otherwise NULL

Definition at line 1180 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\addRecord(), TYPO3\CMS\Impexp\ImportExport\addRelations(), and TYPO3\CMS\Impexp\Import\addSingle().

◆ getRecordPath()

string TYPO3\CMS\Impexp\ImportExport::getRecordPath ( int  $pid)
protected

Returns the page title path of a PID value. Results are cached internally

Parameters
int$pid‪Record PID to check
Returns
‪string The path for the input PID

Definition at line 1191 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\addRecord(), and TYPO3\CMS\Impexp\ImportExport\addRelations().

◆ getRelStaticTables()

TYPO3\CMS\Impexp\ImportExport::getRelStaticTables ( )

Definition at line 1424 of file ImportExport.php.

◆ getSoftrefCfg()

TYPO3\CMS\Impexp\ImportExport::getSoftrefCfg ( )

Definition at line 1394 of file ImportExport.php.

◆ getSoftrefInputValues()

TYPO3\CMS\Impexp\ImportExport::getSoftrefInputValues ( )

Definition at line 1494 of file ImportExport.php.

◆ hasErrors()

TYPO3\CMS\Impexp\ImportExport::hasErrors ( )

◆ isExcludeDisabledRecords()

TYPO3\CMS\Impexp\ImportExport::isExcludeDisabledRecords ( )

Definition at line 1379 of file ImportExport.php.

◆ isForceAllUids()

TYPO3\CMS\Impexp\ImportExport::isForceAllUids ( )

Definition at line 1474 of file ImportExport.php.

◆ isGlobalIgnorePid()

TYPO3\CMS\Impexp\ImportExport::isGlobalIgnorePid ( )

Definition at line 1464 of file ImportExport.php.

◆ isRecordDisabled()

bool TYPO3\CMS\Impexp\ImportExport::isRecordDisabled ( string  $table,
int  $uid 
)
protected

Test whether a record is disabled (e.g. hidden)

Parameters
string$table‪Name of the records' database table
int$uid‪Database uid of the record
Returns
‪bool true if the record is disabled, false otherwise

Definition at line 277 of file ImportExport.php.

References $GLOBALS, and TYPO3\CMS\Webhooks\Message\$uid.

Referenced by TYPO3\CMS\Impexp\ImportExport\addRecord(), TYPO3\CMS\Impexp\Export\exportAddRecord(), and TYPO3\CMS\Impexp\ImportExport\traversePageTree().

◆ isRecordExcluded()

bool TYPO3\CMS\Impexp\ImportExport::isRecordExcluded ( string  $table,
int  $uid 
)
protected

Returns TRUE if the element should be excluded from import and export.

Parameters
string$table‪Table name
int$uid‪Record UID
Returns
‪bool TRUE, if the record should be excluded

Definition at line 1155 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\addRelations(), TYPO3\CMS\Impexp\Export\exportAddRecord(), TYPO3\CMS\Impexp\Export\exportAddRecordsFromRelationsPushRelation(), TYPO3\CMS\Impexp\Import\remapRelationsOfField(), and TYPO3\CMS\Impexp\Export\removeExcludedPagesFromPageTree().

◆ isShowDiff()

TYPO3\CMS\Impexp\ImportExport::isShowDiff ( )

Definition at line 1484 of file ImportExport.php.

◆ isShowStaticRelations()

TYPO3\CMS\Impexp\ImportExport::isShowStaticRelations ( )

Definition at line 1414 of file ImportExport.php.

◆ isSoftRefIncluded()

bool TYPO3\CMS\Impexp\ImportExport::isSoftRefIncluded ( string  $tokenID)
protected

Returns TRUE if the soft reference should be included in export.

Parameters
string$tokenID‪Token ID for soft reference
Returns
‪bool TRUE, if soft reference should be included

Definition at line 1166 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\addFiles(), TYPO3\CMS\Impexp\ImportExport\addRelations(), TYPO3\CMS\Impexp\Export\exportAddFilesFromRelations(), TYPO3\CMS\Impexp\Export\exportAddRecordsFromRelations(), and TYPO3\CMS\Impexp\Export\exportAddRecordsFromRelationsPushRelation().

◆ isTableStatic()

bool TYPO3\CMS\Impexp\ImportExport::isTableStatic ( string  $table)
protected

Returns TRUE if the input table name is to be regarded as a static relation (that is, not exported etc).

Parameters
string$table‪Table name
Returns
‪bool TRUE, if table is marked static

Definition at line 1138 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\addRelations(), TYPO3\CMS\Impexp\Export\exportAddRecordsFromRelationsPushRelation(), and TYPO3\CMS\Impexp\Import\remapRelationsOfField().

◆ isUpdate()

TYPO3\CMS\Impexp\ImportExport::isUpdate ( )

Definition at line 1444 of file ImportExport.php.

◆ removeDefaultImportExportFolder()

TYPO3\CMS\Impexp\ImportExport::removeDefaultImportExportFolder ( )

Definition at line 1076 of file ImportExport.php.

◆ removeTemporaryFolderName()

TYPO3\CMS\Impexp\ImportExport::removeTemporaryFolderName ( )

◆ renderControls()

string TYPO3\CMS\Impexp\ImportExport::renderControls ( array  $line)
protected

Render input controls for import or export

Parameters
array$line‪Output line array
Returns
‪string HTML

Definition at line 794 of file ImportExport.php.

References TYPO3\CMS\Impexp\ImportExport\renderRecordExcludeCheckbox(), TYPO3\CMS\Impexp\ImportExport\renderSoftRefExportSelector(), and TYPO3\CMS\Impexp\ImportExport\renderSoftRefImportTextField().

Referenced by TYPO3\CMS\Impexp\ImportExport\renderPreview().

◆ renderImportModeSelector()

string TYPO3\CMS\Impexp\ImportExport::renderImportModeSelector ( string  $table,
int  $uid,
bool  $doesRecordExist 
)
protected

Render select box with import options for the record.

Parameters
string$table‪Table name
int$uid‪Record UID
bool$doesRecordExist‪Is there already a record with this UID in the database?
Returns
‪string HTML

Definition at line 924 of file ImportExport.php.

References TYPO3\CMS\Webhooks\Message\$uid, TYPO3\CMS\Impexp\ImportExport\getBackendUser(), TYPO3\CMS\Impexp\Import\IMPORT_MODE_AS_NEW, TYPO3\CMS\Impexp\Import\IMPORT_MODE_EXCLUDE, TYPO3\CMS\Impexp\Import\IMPORT_MODE_FORCE_UID, TYPO3\CMS\Impexp\Import\IMPORT_MODE_IGNORE_PID, TYPO3\CMS\Impexp\Import\IMPORT_MODE_RESPECT_PID, and TYPO3\CMS\Impexp\ImportExport\renderSelectBox().

Referenced by TYPO3\CMS\Impexp\ImportExport\addRecord().

◆ renderIndent()

TYPO3\CMS\Impexp\ImportExport::renderIndent ( int  $indent)
protected

◆ renderPreview()

◆ renderRecordExcludeCheckbox()

string TYPO3\CMS\Impexp\ImportExport::renderRecordExcludeCheckbox ( string  $recordRef)
protected

Render check box for exclusion of a record from export.

Parameters
string$recordRef‪The record ID of the form [table]:[id].
Returns
‪string HTML

Definition at line 817 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\renderControls().

◆ renderSelectBox()

string TYPO3\CMS\Impexp\ImportExport::renderSelectBox ( string  $name,
string  $value,
array  $options 
)
protected

Renders a select box from option values.

Parameters
string$nameForm element name
string$value‪Current value
array$options‪Options to display (key/value pairs)
Returns
‪string HTML

Definition at line 957 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\renderImportModeSelector(), and TYPO3\CMS\Impexp\ImportExport\renderSoftRefExportSelector().

◆ renderSoftRefExportSelector()

string TYPO3\CMS\Impexp\ImportExport::renderSoftRefExportSelector ( array  $softref)
protected

Render select box with export options for soft references. An export box is shown only if a substitution scheme is found for the soft reference.

Parameters
array$softref‪Soft reference
Returns
‪string HTML

Definition at line 862 of file ImportExport.php.

References TYPO3\CMS\Impexp\ImportExport\renderSelectBox(), TYPO3\CMS\Impexp\Import\SOFTREF_IMPORT_MODE_EDITABLE, and TYPO3\CMS\Impexp\Import\SOFTREF_IMPORT_MODE_EXCLUDE.

Referenced by TYPO3\CMS\Impexp\ImportExport\renderControls().

◆ renderSoftRefImportTextField()

string TYPO3\CMS\Impexp\ImportExport::renderSoftRefImportTextField ( array  $softref)
protected

Render text field when importing a soft reference.

Parameters
array$softref‪Soft reference
Returns
‪string HTML

Definition at line 832 of file ImportExport.php.

References TYPO3\CMS\Impexp\Import\SOFTREF_IMPORT_MODE_EDITABLE.

Referenced by TYPO3\CMS\Impexp\ImportExport\renderControls().

◆ resolveStoragePath()

string null TYPO3\CMS\Impexp\ImportExport::resolveStoragePath ( string  $dirPrefix,
bool  $checkAlternatives = true 
)
protected

Checks if the input path relative to the public web path can be found in the file mounts of the backend user. If not, it checks all file mounts of the user for the relative path and returns it if found.

Parameters
string$dirPrefix‪Path relative to public web path.
bool$checkAlternatives‪If set to false, do not look for an alternative path.
Returns
‪string|null If a path is available, it will be returned, otherwise NULL.
Exceptions

Definition at line 1093 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\addFiles(), and TYPO3\CMS\Impexp\Import\processSoftReferencesSaveFileCreateRelFile().

◆ setErrorLog()

TYPO3\CMS\Impexp\ImportExport::setErrorLog ( array  $errorLog)

Definition at line 1439 of file ImportExport.php.

◆ setExcludeDisabledRecords()

TYPO3\CMS\Impexp\ImportExport::setExcludeDisabledRecords ( bool  $excludeDisabledRecords)

Set flag to control whether disabled records and their children are excluded (true) or included (false). Defaults to the old behaviour of including everything.

Parameters
bool$excludeDisabledRecords‪Set to true if if all disabled records should be excluded, false otherwise

Definition at line 1374 of file ImportExport.php.

◆ setExcludeMap()

TYPO3\CMS\Impexp\ImportExport::setExcludeMap ( array  $excludeMap)

Definition at line 1389 of file ImportExport.php.

◆ setExtensionDependencies()

TYPO3\CMS\Impexp\ImportExport::setExtensionDependencies ( array  $extensionDependencies)

Definition at line 1409 of file ImportExport.php.

◆ setForceAllUids()

TYPO3\CMS\Impexp\ImportExport::setForceAllUids ( bool  $forceAllUids)

Definition at line 1479 of file ImportExport.php.

◆ setGlobalIgnorePid()

TYPO3\CMS\Impexp\ImportExport::setGlobalIgnorePid ( bool  $globalIgnorePid)

Definition at line 1469 of file ImportExport.php.

◆ setImportMapId()

TYPO3\CMS\Impexp\ImportExport::setImportMapId ( array  $importMapId)

Definition at line 1519 of file ImportExport.php.

◆ setImportMode()

TYPO3\CMS\Impexp\ImportExport::setImportMode ( array  $importMode)

Definition at line 1459 of file ImportExport.php.

◆ setMode()

TYPO3\CMS\Impexp\ImportExport::setMode ( string  $mode)

Definition at line 1509 of file ImportExport.php.

◆ setPid()

TYPO3\CMS\Impexp\ImportExport::setPid ( int  $pid)

◆ setRelStaticTables()

TYPO3\CMS\Impexp\ImportExport::setRelStaticTables ( array  $relStaticTables)

Definition at line 1429 of file ImportExport.php.

◆ setShowDiff()

TYPO3\CMS\Impexp\ImportExport::setShowDiff ( bool  $showDiff)

Definition at line 1489 of file ImportExport.php.

◆ setShowStaticRelations()

TYPO3\CMS\Impexp\ImportExport::setShowStaticRelations ( bool  $showStaticRelations)

Definition at line 1419 of file ImportExport.php.

◆ setSoftrefCfg()

TYPO3\CMS\Impexp\ImportExport::setSoftrefCfg ( array  $softrefCfg)

Definition at line 1399 of file ImportExport.php.

◆ setSoftrefInputValues()

TYPO3\CMS\Impexp\ImportExport::setSoftrefInputValues ( array  $softrefInputValues)

Definition at line 1499 of file ImportExport.php.

◆ setUpdate()

TYPO3\CMS\Impexp\ImportExport::setUpdate ( bool  $update)

Definition at line 1449 of file ImportExport.php.

◆ traverseAllRecords()

TYPO3\CMS\Impexp\ImportExport::traverseAllRecords ( array  $pageTree,
array &  $lines 
)
protected

Go through ALL records (if the pages are displayed first, those will not be among these!)

Parameters
array$pageTree‪Page tree array with uid/subrow (from ->dat[header][pagetree])
array$lines‪Output lines array

Definition at line 341 of file ImportExport.php.

References TYPO3\CMS\Webhooks\Message\$uid, TYPO3\CMS\Impexp\ImportExport\addGeneralErrorsByTable(), and TYPO3\CMS\Impexp\ImportExport\addRecord().

Referenced by TYPO3\CMS\Impexp\ImportExport\renderPreview().

◆ traversePageRecords()

TYPO3\CMS\Impexp\ImportExport::traversePageRecords ( array  $pageTree,
array &  $lines 
)
protected

Go through remaining pages (not in tree)

Parameters
array<int,array>‪$pageTree Page tree array with uid/subrow (from ->dat[header][pagetree])
array$lines‪Output lines array

Definition at line 317 of file ImportExport.php.

References TYPO3\CMS\Webhooks\Message\$uid, and TYPO3\CMS\Impexp\ImportExport\addRecord().

Referenced by TYPO3\CMS\Impexp\ImportExport\renderPreview().

◆ traversePageTree()

TYPO3\CMS\Impexp\ImportExport::traversePageTree ( array  $pageTree,
array &  $lines,
int  $indent = 0 
)
protected

Go through page tree for display

Parameters
array<int,array>‪$pageTree Page tree array with uid/subrow (from ->dat[header][pagetree])
array$lines‪Output lines array
int$indent‪Indentation level

Definition at line 241 of file ImportExport.php.

References TYPO3\CMS\Webhooks\Message\$uid, TYPO3\CMS\Impexp\ImportExport\addRecord(), TYPO3\CMS\Impexp\ImportExport\excludePageAndRecords(), and TYPO3\CMS\Impexp\ImportExport\isRecordDisabled().

Referenced by TYPO3\CMS\Impexp\ImportExport\renderPreview().

Member Data Documentation

◆ $cacheGetRecordPath

array TYPO3\CMS\Impexp\ImportExport::$cacheGetRecordPath = []
protected

Cache for record paths

Definition at line 149 of file ImportExport.php.

◆ $dat

array TYPO3\CMS\Impexp\ImportExport::$dat = []
protected

Internal import/export memory

Definition at line 154 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\Import\loadFile().

◆ $defaultImportExportFolder

Folder TYPO3\CMS\Impexp\ImportExport::$defaultImportExportFolder = null
protected

Definition at line 167 of file ImportExport.php.

◆ $diffUtility

DiffUtility TYPO3\CMS\Impexp\ImportExport::$diffUtility = null
protected

Definition at line 160 of file ImportExport.php.

◆ $doesImport

bool TYPO3\CMS\Impexp\ImportExport::$doesImport = false
protected

Set by importData() when an import is started.

Definition at line 82 of file ImportExport.php.

◆ $errorLog

array TYPO3\CMS\Impexp\ImportExport::$errorLog = []
protected

Error log.

Definition at line 144 of file ImportExport.php.

◆ $excludeDisabledRecords

bool TYPO3\CMS\Impexp\ImportExport::$excludeDisabledRecords = false
protected

Flag to control whether all disabled records and their children are excluded (true) or included (false). Defaults to the old behaviour of including everything.

Definition at line 173 of file ImportExport.php.

◆ $excludeMap

array TYPO3\CMS\Impexp\ImportExport::$excludeMap = []
protected

Exclude map. Keys are table:uid pairs and if set, records are not added to the export.

Definition at line 124 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\Export\setHeaderBasics().

◆ $extensionDependencies

array TYPO3\CMS\Impexp\ImportExport::$extensionDependencies = []
protected

Listing extension dependencies.

Definition at line 134 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\Export\setHeaderBasics().

◆ $fileIdMap

array TYPO3\CMS\Impexp\ImportExport::$fileIdMap = []
protected

Mapping between the fileID from import memory and the final filenames they are written to.

Definition at line 113 of file ImportExport.php.

◆ $fileProcObj

ExtendedFileUtility TYPO3\CMS\Impexp\ImportExport::$fileProcObj = null
protected

◆ $forceAllUids

bool TYPO3\CMS\Impexp\ImportExport::$forceAllUids = false
protected

If set, all UID values are forced! (update or import)

Definition at line 98 of file ImportExport.php.

◆ $globalIgnorePid

bool TYPO3\CMS\Impexp\ImportExport::$globalIgnorePid = false
protected

If set, PID correct is ignored globally

Definition at line 93 of file ImportExport.php.

◆ $iconFactory

IconFactory TYPO3\CMS\Impexp\ImportExport::$iconFactory
protected

Definition at line 164 of file ImportExport.php.

◆ $importMapId

array TYPO3\CMS\Impexp\ImportExport::$importMapId = []
protected

After records are written this array is filled with [table][original_uid] = [new_uid]

Definition at line 139 of file ImportExport.php.

◆ $importMode

array TYPO3\CMS\Impexp\ImportExport::$importMode = []
protected

Setting the import mode for specific import records. Available options are: force_uid, as_new, exclude, ignore_pid, respect_pid

Definition at line 88 of file ImportExport.php.

◆ $lang

LanguageService TYPO3\CMS\Impexp\ImportExport::$lang
protected

Definition at line 163 of file ImportExport.php.

◆ $mode

string TYPO3\CMS\Impexp\ImportExport::$mode = ''
protected

Definition at line 52 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\addSoftRefs().

◆ $permsClause

string TYPO3\CMS\Impexp\ImportExport::$permsClause
protected

A WHERE clause for selection records from the pages table based on read-permissions of the current backend user.

Definition at line 57 of file ImportExport.php.

◆ $pid

◆ $pidRecord

array TYPO3\CMS\Impexp\ImportExport::$pidRecord = null
protected

Root page record of import or of export page tree

Definition at line 67 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\addRecord().

◆ $relStaticTables

array TYPO3\CMS\Impexp\ImportExport::$relStaticTables = []
protected

Add tables names here which should not be exported with the file. (Where relations should be mapped to same UIDs in target system).

Definition at line 119 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\Export\setHeaderBasics().

◆ $remainHeader

array TYPO3\CMS\Impexp\ImportExport::$remainHeader = []
protected

Definition at line 162 of file ImportExport.php.

◆ $showDiff

bool TYPO3\CMS\Impexp\ImportExport::$showDiff = false
protected

If set, a diff-view column is added to the preview.

Definition at line 103 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\renderPreview().

◆ $showStaticRelations

bool TYPO3\CMS\Impexp\ImportExport::$showStaticRelations = false
protected

If set, static relations (not exported) will be shown in preview as well

Definition at line 72 of file ImportExport.php.

◆ $softrefCfg

array TYPO3\CMS\Impexp\ImportExport::$softrefCfg = []
protected

Soft reference token ID modes.

Definition at line 129 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\Export\setHeaderBasics().

◆ $softrefInputValues

array TYPO3\CMS\Impexp\ImportExport::$softrefInputValues = []
protected

Array of values to substitute in editable soft references.

Definition at line 108 of file ImportExport.php.

◆ $temporaryFolderName

string TYPO3\CMS\Impexp\ImportExport::$temporaryFolderName = null
protected

Definition at line 166 of file ImportExport.php.

◆ $update

bool TYPO3\CMS\Impexp\ImportExport::$update = false
protected

Updates all records that has same UID instead of creating new!

Definition at line 77 of file ImportExport.php.

Referenced by TYPO3\CMS\Impexp\ImportExport\addRecord(), and TYPO3\CMS\Impexp\ImportExport\renderPreview().