vB_Stylevar_Mapper
in package
Uses
vB_Trait_NoSerialize
Table of Contents
Methods
- __construct() : mixed
- __serialize() : array<string|int, mixed>
- __sleep() : array<string|int, mixed>
- __unserialize() : void
- __wakeup() : void
- addMapping() : mixed
- addPreset() : mixed
- displayResults() : mixed
- load() : mixed
- process() : mixed
- processResults() : mixed
- removeStylevar() : mixed
- updateInheritance() : bool
- Updates any stylevars that inherit from $oldname to inherit from $newname instead
Methods
__construct()
public
__construct([mixed $masterstyleid = -1 ]) : mixed
Parameters
- $masterstyleid : mixed = -1
__serialize()
public
__serialize() : array<string|int, mixed>
Return values
array<string|int, mixed>__sleep()
public
__sleep() : array<string|int, mixed>
Return values
array<string|int, mixed>__unserialize()
public
__unserialize(array<string|int, mixed> $serialized) : void
Parameters
- $serialized : array<string|int, mixed>
__wakeup()
public
__wakeup() : void
addMapping()
public
addMapping(mixed $mapfrom, mixed $mapto[, mixed $product = 'vbulletin' ][, mixed $delete = false ]) : mixed
Parameters
- $mapfrom : mixed
- $mapto : mixed
- $product : mixed = 'vbulletin'
- $delete : mixed = false
addPreset()
public
addPreset(mixed $mapto, mixed $value[, mixed $forced = true ][, mixed $verify = '' ]) : mixed
Parameters
- $mapto : mixed
- $value : mixed
- $forced : mixed = true
- $verify : mixed = ''
displayResults()
public
displayResults([mixed $stop = false ]) : mixed
Parameters
- $stop : mixed = false
load()
public
load() : mixed
process()
public
process() : mixed
processResults()
public
processResults() : mixed
removeStylevar()
public
removeStylevar(mixed $stylevar) : mixed
Parameters
- $stylevar : mixed
updateInheritance()
Updates any stylevars that inherit from $oldname to inherit from $newname instead
public
updateInheritance(mixed $oldname, mixed $newname) : bool
NOTE: This works mostly separate from stylevar mapping, since when you map from one stylevar to another, you're not necessary renaming it to the new one... you might be merely sourcing the value of one to populate the other. If you're actually renaming a stylevar, and the old one won't be used anymore, that's when you call this function. This should be called after doing the regular mapping.
Parameters
- $oldname : mixed
- $newname : mixed
Return values
bool —True if anything was updated, false otherwise.