abstract class vB_Xml_Import

Traits

Constants

OPTION_OVERWRITE

OPTION_IGNOREMISSINGROUTES

OPTION_IGNOREMISSINGPARENTS

OPTION_ADDWIDGETS

OPTION_OVERWRITECOLUMN

TYPE_ROUTE

TYPE_CHANNEL

TYPE_PAGE

TYPE_PAGETEMPLATE

TYPE_WIDGET

TYPE_THEME

TYPE_SCREENLAYOUT

Properties

protected vB_dB_Assertor $db
protected int $options
protected array $parsedXML
protected $productid
static protected array $importedElements
protected string $overwriteColumn Column to overwrite, if OPTION_OVERWRITECOLUMN is set

Methods

__sleep()

No description

__wakeup()

No description

__construct($productid = 'vbulletin', $options = 9)

No description

setOptions($options)

No description

setOverwriteColumn(string $column)

Sets the column to overwrite, if OPTION_OVERWRITECOLUMN is set

static 
setImportedId($type, $guid, $newid)

Stores an imported element with the new id

static int
getImportedId(string $type, string $guid = NULL)

Returns the id for an imported element

importFromFile(string $filepath, string $guid = false)

Imports objects from the specified filepath

importFromParsedXML(array $parsedXML)

Imports objects from parsed XML starting at the base of the relevant objects.

import()

Import objects

static 
parseFile($filepath)

No description

array
replacePhrasePlaceholdersInArray(array $array)

If an array value is of the form "phrase:" replace it with the actual phrase.

Details

in vB_Trait_NoSerialize at line 15
__sleep()

in vB_Trait_NoSerialize at line 20
__wakeup()

at line 69
__construct($productid = 'vbulletin', $options = 9)

Parameters

$productid
$options

at line 76
setOptions($options)

Parameters

$options

at line 86
setOverwriteColumn(string $column)

Sets the column to overwrite, if OPTION_OVERWRITECOLUMN is set

Parameters

string $column Column name

at line 137
static protected setImportedId($type, $guid, $newid)

Stores an imported element with the new id

Parameters

$type
$guid
$newid

at line 148
static int getImportedId(string $type, string $guid = NULL)

Returns the id for an imported element

Parameters

string $type
string $guid

Return Value

int

at line 173
importFromFile(string $filepath, string $guid = false)

Imports objects from the specified filepath

Parameters

string $filepath
string $guid Only import the record associated with this guid

at line 183
importFromParsedXML(array $parsedXML)

Imports objects from parsed XML starting at the base of the relevant objects.

Parameters

array $parsedXML

at line 192
abstract protected import()

Import objects

at line 194
static parseFile($filepath)

Parameters

$filepath

at line 218
protected array replacePhrasePlaceholdersInArray(array $array)

If an array value is of the form "phrase:" replace it with the actual phrase.

Parameters

array $array

Return Value

array The array with phrases replaced.