vBulletin 5.6.5 API

vB_Api_Template extends vB_Api
in package

vB_Api_Template

Tags
access

public

Table of Contents

$common_templates  : mixed
$controller  : string
API Controller
$db  : vB_Database
Database object.
$disabled  : bool
Indicates whether the API was disabled
$disableFalseReturnOnly  : array<string|int, mixed>
Contains white listed methods which return a false response when API is disabled in special scenarios like forum closed, password expiry, ip ban and others.
$disableWhiteList  : array<string|int, mixed>
Contains white listed methods which act as normal when API is disabled no matter of special scenarios like forum closed, password expiry, ip ban and others.
$library  : mixed
$special_templates  : mixed
$instances  : mixed
$instancesRaw  : array<string|int, mixed>
We want API subclasses to access the instances only through getters
$vb4_input_mappings  : mixed
$wrappers  : mixed
__serialize()  : mixed
__sleep()  : mixed
__unserialize()  : mixed
__wakeup()  : mixed
cacheTemplates()  : none
Fetches a number of templates from the database and puts them into the templatecache
callNamed()  : The
Call the given api function by name with a named arguments list.
checkApiState()  : mixed
This method checks whether the API method is enabled.
clearCache()  : mixed
Clears all previously loaded API objects.
delete()  : mixed
Delete a template
deleteAllTemplateFiles()  : mixed
deleteHistoryVersion()  : mixed
Delete template history versions
deleteReplacementVar()  : array<string|int, mixed>
Delete a replacement variable
dismissMerge()  : array<string|int, mixed>
Dismiss automatical merge
fetch()  : mixed
Fetch one template based on its name and style ID.
fetchBulk()  : array<string|int, mixed>
Fetches a bulk of templates from the database
fetchByID()  : array<string|int, mixed>
Fetch template by its ID
fetchCommonTemplates()  : mixed
fetchOriginal()  : array<string|int, mixed>
Fetch original (not customized) template content
fetchReplacementVar()  : array<string|int, mixed>
Find the replacement var by title and styleid
fetchReplacementVarById()  : array<string|int, mixed>
Find the replacement var by templateid
fetchSpecialTemplates()  : mixed
fetchTemplateHooks()  : mixed
fetchUncompiled()  : mixed
Fetch one uncompiled template based on its name and style ID.
fetchVersion()  : mixed
Fetch current or historical uncompiled version of a template
findUpdates()  : array<string|int, mixed>
Find custom templates that need updating
getApiClassName()  : mixed
getCssTemplateSbEditor()  : array<string|int, mixed>
This is the counterpart to saveCssTemplateSbEditor(). Returns the template record, including template text and the textonly value.
getTemplateID()  : mixed
Get template ID by its template name and style id
getTemplateIds()  : array<string|int, mixed>
Get a list of template IDs by thier template names and style id
getTextonlyDS()  : mixed
gets the current textonly array
history()  : array<string|int, mixed>
Return editing history of a template, including old versions and diffs between versions
historyByTemplateID()  : array<string|int, mixed>
Return editing history of a template by its ID, including old versions and diffs between versions
insert()  : int
Insert a new template
insertReplacementVar()  : array<string|int, mixed>
Insert a replacement var
instance()  : vB_Api
Returns an instance of the API object which translates exceptions to an array Use this method for API clients.
instanceInternal()  : vB_Api
Returns an instance of the API object which doesn't handle exceptions This should only be used in other API objects, not for clients of the API
loadLanguage()  : mixed
Preload basic language information we're going to need.
map_vb4_input_to_vb5()  : string
Returns vb5 api method name.
map_vb5_errors_to_vb4()  : mixed
Alters the error array in any way necessary to interface correctly with vb4.
map_vb5_output_to_vb4()  : mixed
Alters the output array in any way necessary to interface correctly with vb4.
massMerge()  : int
Massive merge templates
processReplacementVars()  : string
Process the replacement variables.
revertAllInStyle()  : bool
Revert all templates in a style
revertCssTemplateSbEditor()  : mixed
Delete a template based on style and name
saveAllTemplatesToFile()  : mixed
saveCssTemplateSbEditor()  : bool
This is just a wrapper for delete, save, and update. The presentation layer doesn't actually know which is correct. This forces textonly = 1 if the user doesn't have 'canadmintemplates'.
search()  : mixed
Search and fetch a list of templates
searchAndReplace()  : mixed
Search and Replace templates.
update()  : mixed
Update a template
updateReplacementVar()  : mixed
Update the replacement text for a replacement var
__construct()  : mixed
checkCanSaveTemplate()  : mixed
This checks permissions for saving a template.
checkHasAdminPermission()  : none
Determines if the calling user has the given admin permission, and if not throws an exception
checkHasPermission()  : none
Determines if the calling user has the given bitfield permission, and if not, throws a 'no_permission' exception.
checkIsLoggedIn()  : mixed
Determines if the calling user has the given admin permission, and if not throws an exception
deleteTemplateInternal()  : mixed
getApiClass()  : mixed
getApiClassNameInternal()  : mixed
hasAdminPermission()  : bool
Determines if the calling user has the given admin permission
inDebugMode()  : mixed
isDisableFalseReturnOnly()  : bool
Checks if method returns false response only when API is disabled.
isWhiteListed()  : bool
Checks if method is white listed when API is disabled.
setController()  : mixed
Set controller
buildHooklist()  : mixed
cms_vb4_to_vb5_method_mapping()  : mixed
default_vb4_to_vb5_method_mapping()  : mixed
hasAdminPermissionInternal()  : mixed
Internal function to power the previous cover functions
remove_nulls()  : mixed
wrapLoggerIfNeeded()  : mixed
Wrap the api object with the log wrapper class if needed.

Properties

$common_templates

protected static mixed $common_templates = ['header', 'footer']

$controller

API Controller

protected string $controller

$disabled

Indicates whether the API was disabled

protected bool $disabled = alse

$disableFalseReturnOnly

Contains white listed methods which return a false response when API is disabled in special scenarios like forum closed, password expiry, ip ban and others.

protected array<string|int, mixed> $disableFalseReturnOnly = array()

$disableWhiteList

Contains white listed methods which act as normal when API is disabled no matter of special scenarios like forum closed, password expiry, ip ban and others.

protected array<string|int, mixed> $disableWhiteList = ['fetch', 'fetchBulk', 'fetchTemplateHooks', 'processReplacementVars', 'getTemplateIds']

$special_templates

protected static mixed $special_templates = [ /* None currently exist. The dummy stops some crashes */ 'dummy entry', ]

$instances

private static mixed $instances

$instancesRaw

We want API subclasses to access the instances only through getters

private static array<string|int, mixed> $instancesRaw

$vb4_input_mappings

private static mixed $vb4_input_mappings = array( 'blog.post_comment' => array('method' => 'vb4_blog.post_comment'), 'blog.post_postcomment' => array('method' => 'vb4_blog.post_postcomment'), 'blog.post_updateblog' => array('method' => 'vb4_blog.post_updateblog'), 'blog.post_newblog' => array('method' => 'vb4_blog.post_newblog'), 'blog.post_editblog' => array('method' => 'vb4_blog.post_editblog'), 'blog_list' => array('method' => 'vb4_blog.bloglist'), 'api_init' => array('method' => 'api.init'), 'api_cmssectionlist' => array('method' => 'Vb4_Cms.sectionlist'), 'api_cmscategorylist' => array('method' => 'Vb4_Cms.categorylist'), /* // These can no longer be mapped directly to vB_Api_User::login/logout // due to additional processing of devicetoken that may be required // for mapi calls. 'login_login' => array( 'method' => 'user.login', 'request_mappings' => array( 'vb_login_username' => 'username', 'vb_login_password' => 'password', 'vb_login_md5password' => 'md5password', 'vb_login_md5password_utf' => 'md5passwordutf' ) ), 'login_logout' => array( 'method' => 'user.logout' ), */ 'get_vbfromfacebook' => array('method' => 'vb4_facebook.getVbfromfacebook'), )

$wrappers

private static mixed $wrappers

Methods

__serialize()

public __serialize() : mixed
Return values
mixed

__sleep()

public __sleep() : mixed
Return values
mixed

__unserialize()

public __unserialize(mixed $serialized) : mixed
Parameters
$serialized : mixed
Return values
mixed

__wakeup()

public __wakeup() : mixed
Return values
mixed

cacheTemplates()

Fetches a number of templates from the database and puts them into the templatecache

public cacheTemplates(mixed $templates, mixed $templateidlist[, mixed $skip_bbcode_style = false ][, mixed $force_set = false ]) : none
Parameters
$templates : mixed
$templateidlist : mixed
$skip_bbcode_style : mixed = false
$force_set : mixed = false
Return values
none

callNamed()

Call the given api function by name with a named arguments list.

public callNamed() : The

Used primarily to translate REST requests into API calls.

Return values
The

return of the method or an error if the method doesn't exist, or is static, a constructor or destructor, or otherwise shouldn't be callable as and API method. It is also an error if the value of a paramater is not provided and that parameter doesn't have a default value.

checkApiState()

This method checks whether the API method is enabled.

public checkApiState(mixed $method) : mixed

For extensions check make sure $controller property is already set.

Parameters
$method : mixed
Return values
mixed

clearCache()

Clears all previously loaded API objects.

public static clearCache() : mixed

Intended for use in tests where the loading pattern can cause issues with objects that cache thier own data.

Return values
mixed

delete()

Delete a template

public delete(int $templateid) : mixed
Parameters
$templateid : int

Template ID to be deleted.

Return values
mixed

deleteAllTemplateFiles()

public deleteAllTemplateFiles() : mixed
Return values
mixed

deleteHistoryVersion()

Delete template history versions

public deleteHistoryVersion(array<string|int, mixed> $historyids) : mixed
Parameters
$historyids : array<string|int, mixed>

History IDs to be deleted

Return values
mixed

deleteReplacementVar()

Delete a replacement variable

public deleteReplacementVar(mixed $replacevarid) : array<string|int, mixed>
@param integer $replacevarid -- templateid for the replacement variable
Parameters
$replacevarid : mixed
Return values
array<string|int, mixed>

('success' => true)

@throws vB_Exception_Api 'no_permission' -- user does not have canadminstyles 'invalid_data_w_x_y_z' -- if the template does not exist or is not a replacement var

dismissMerge()

Dismiss automatical merge

public dismissMerge(mixed $templateids) : array<string|int, mixed>
Parameters
$templateids : mixed
Return values
array<string|int, mixed>

Number of affected templates.

fetch()

Fetch one template based on its name and style ID.

public fetch(string $template_name[, int $styleid = -1 ]) : mixed
Parameters
$template_name : string

Template name.

$styleid : int = -1

Style ID. If empty, this method will fetch template from default style.

Return values
mixed

fetchBulk()

Fetches a bulk of templates from the database

public fetchBulk(array<string|int, mixed> $template_names[, int $styleid = -1 ][, mixed $type = 'compiled' ]) : array<string|int, mixed>
Parameters
$template_names : array<string|int, mixed>

List of template names to be fetched.

$styleid : int = -1

Style ID. If empty, this method will fetch template from default style.

$type : mixed = 'compiled'
Return values
array<string|int, mixed>

Array of information about the imported style

fetchByID()

Fetch template by its ID

public fetchByID(int $templateid) : array<string|int, mixed>
Parameters
$templateid : int

Template ID.

Return values
array<string|int, mixed>

Return template array if $templateid is valid.

fetchCommonTemplates()

public fetchCommonTemplates() : mixed
Return values
mixed

fetchOriginal()

Fetch original (not customized) template content

public fetchOriginal(string $title) : array<string|int, mixed>
Parameters
$title : string

Template name.

Return values
array<string|int, mixed>

Original template information

fetchReplacementVar()

Find the replacement var by title and styleid

public fetchReplacementVar(string $findtext, int $dostyleid[, bool $inherit = false ]) : array<string|int, mixed>
Parameters
$findtext : string
$dostyleid : int
$inherit : bool = false

-- do we check for variables in parent styles?

Return values
array<string|int, mixed>

'replacevar' => false|array -- template record for the replacement variable string title integer styleid integer dateline string username string template string template_un string version

fetchReplacementVarById()

Find the replacement var by templateid

public fetchReplacementVarById(int $replacevarid) : array<string|int, mixed>
Parameters
$replacevarid : int
Return values
array<string|int, mixed>

'replacevar' => false|array -- template record for the replacement variable string title integer styleid integer dateline string username string template string template_un string version

fetchSpecialTemplates()

public fetchSpecialTemplates() : mixed
Return values
mixed

fetchTemplateHooks()

public fetchTemplateHooks(mixed $hookName) : mixed
Parameters
$hookName : mixed
Return values
mixed

fetchUncompiled()

Fetch one uncompiled template based on its name and style ID.

public fetchUncompiled(string $template_name[, int $styleid = -1 ]) : mixed
Parameters
$template_name : string

Template name.

$styleid : int = -1

Style ID.

Return values
mixed

fetchVersion()

Fetch current or historical uncompiled version of a template

public fetchVersion(mixed $historyid, mixed $type) : mixed
Parameters
$historyid : mixed
$type : mixed
Return values
mixed

findUpdates()

Find custom templates that need updating

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

Templates that need updating.

getApiClassName()

public static getApiClassName(mixed $controller) : mixed
Parameters
$controller : mixed
Return values
mixed

getCssTemplateSbEditor()

This is the counterpart to saveCssTemplateSbEditor(). Returns the template record, including template text and the textonly value.

public getCssTemplateSbEditor(mixed $styleid, mixed $templateName) : array<string|int, mixed>
Parameters
$styleid : mixed
$templateName : mixed
Return values
array<string|int, mixed>

Array containing the template info

getTemplateID()

Get template ID by its template name and style id

public getTemplateID( $template_name[,  $styleid = -1 ]) : mixed
Parameters
$template_name :

the name of the template

$styleid : = -1
Return values
mixed

getTemplateIds()

Get a list of template IDs by thier template names and style id

public getTemplateIds(array<string|int, mixed> $template_names[, array<string|int, mixed> $styleid = -1 ]) : array<string|int, mixed>
Parameters
$template_names : array<string|int, mixed>

-- a list of template names

$styleid : array<string|int, mixed> = -1

-- must be a style the user has access to. If not specified, the default style is used.

Return values
array<string|int, mixed>

array('ids' => $ids) where $ids is a map of names to the template id for that name. If the name is not found, the entry for that name in the map will be false.

getTextonlyDS()

gets the current textonly array

public getTextonlyDS() : mixed
Return values
mixed

array of styleid => array of template title => 1;

history()

Return editing history of a template, including old versions and diffs between versions

public history(string $title, int $dostyleid) : array<string|int, mixed>
Parameters
$title : string

Template name.

$dostyleid : int

Style ID of the template.

Return values
array<string|int, mixed>

Array of template history revisions.

historyByTemplateID()

Return editing history of a template by its ID, including old versions and diffs between versions

public historyByTemplateID(int $templateid) : array<string|int, mixed>
Parameters
$templateid : int

Template ID.

Return values
array<string|int, mixed>

Array of template history revisions.

insert()

Insert a new template

public insert(int $dostyleid, string $title, string $content[, string $product = 'vbulletin' ][, bool $savehistory = false ][, string $histcomment = '' ][, mixed $forcesaveonerror = false ][, mixed $extra = array() ]) : int
Parameters
$dostyleid : int

Style ID which the new template belongs to.

$title : string

Template name.

$content : string

Template content.

$product : string = 'vbulletin'

The product ID which the template belongs to.

$savehistory : bool = false

Whether to save the change in template history.

$histcomment : string = ''

Comment of the change to be saved to template history.

$forcesaveonerror : mixed = false
$extra : mixed = array()
Return values
int

New inserted template ID.

insertReplacementVar()

Insert a replacement var

public insertReplacementVar(int $dostyleid, string $findtext, string $replacetext) : array<string|int, mixed>
Parameters
$dostyleid : int
$findtext : string
$replacetext : string
Tags
throws
vB_Exception_Api

'no_permission' -- user does not have canadminstyles

Return values
array<string|int, mixed>

integer id -- The id of the newly created replacement var

instance()

Returns an instance of the API object which translates exceptions to an array Use this method for API clients.

public static instance(string $controller[, bool $refresh_cache = false ]) : vB_Api
Parameters
$controller : string

-- name of the API controller to load

$refresh_cache : bool = false

-- true if we want to force the cache to update with a new api object primarily intended for testing

Return values
vB_Api

instanceInternal()

Returns an instance of the API object which doesn't handle exceptions This should only be used in other API objects, not for clients of the API

public static instanceInternal(string $controller[, bool $refresh_cache = false ]) : vB_Api
Parameters
$controller : string

-- name of the API controller to load

$refresh_cache : bool = false

-- true if we want to force the cache to update with a new api object primarily intended for testing

Return values
vB_Api

loadLanguage()

Preload basic language information we're going to need.

public loadLanguage() : mixed
Return values
mixed

map_vb4_input_to_vb5()

Returns vb5 api method name.

public static map_vb4_input_to_vb5(string $method, array<string|int, mixed> &$request) : string

May alter request array.

Parameters
$method : string

-- vb4 method name

$request : array<string|int, mixed>

-- $_REQUEST array for this api request

Return values
string

map_vb5_errors_to_vb4()

Alters the error array in any way necessary to interface correctly with vb4.

public static map_vb5_errors_to_vb4(string $method, array<string|int, mixed> &$data) : mixed
Parameters
$method : string

-- vb4 method name

$data : array<string|int, mixed>

-- error array from vb5

Return values
mixed

map_vb5_output_to_vb4()

Alters the output array in any way necessary to interface correctly with vb4.

public static map_vb5_output_to_vb4(string $method, array<string|int, mixed> &$data) : mixed
Parameters
$method : string

-- vb4 method name

$data : array<string|int, mixed>

-- output array from vb5

Return values
mixed

massMerge()

Massive merge templates

public massMerge([string $product = 'vbulletin' ], int $startat) : int
Parameters
$product : string = 'vbulletin'

Product string ID.

$startat : int

Start offset of the merge.

Return values
int

New startat value. -1 if no more to do.

processReplacementVars()

Process the replacement variables.

public processReplacementVars(mixed $html[, mixed $syleid = -1 ]) : string
Parameters
$html : mixed
$syleid : mixed = -1
Return values
string

The processed output

revertAllInStyle()

Revert all templates in a style

public revertAllInStyle(int $dostyleid) : bool
Parameters
$dostyleid : int

Style ID where the custom templates in it will be reverted

Return values
bool

False if nothing to do.

revertCssTemplateSbEditor()

Delete a template based on style and name

public revertCssTemplateSbEditor(mixed $styleid, mixed $templateName) : mixed

This will delete the template for the given style if it exists If the template doesn't exist we will quietly do nothing.

Parameters
$styleid : mixed
$templateName : mixed
Return values
mixed

saveAllTemplatesToFile()

public saveAllTemplatesToFile() : mixed
Return values
mixed

saveCssTemplateSbEditor()

This is just a wrapper for delete, save, and update. The presentation layer doesn't actually know which is correct. This forces textonly = 1 if the user doesn't have 'canadmintemplates'.

public saveCssTemplateSbEditor(mixed $text, mixed $styleid, mixed $templateName[, mixed $textonly = 1 ]) : bool
Parameters
$text : mixed
$styleid : mixed
$templateName : mixed
$textonly : mixed = 1
Return values
bool

Search and fetch a list of templates

public search(int $dostyleid[, mixed $expandset = null ][, string $searchstring = '' ][, bool $titlesonly = true ]) : mixed
Parameters
$dostyleid : int

Style ID to be searched in. -1 means search in all styles.

$expandset : mixed = null
$searchstring : string = ''

Search for text.

$titlesonly : bool = true

Wether to search template titles (names) only.

Return values
mixed

false if no templates are found. Otherwise an array will be returned with styleids as its keys.

searchAndReplace()

Search and Replace templates.

public searchAndReplace(int $dostyleid, string $searchstring, string $replacestring, bool $case_insensitive, bool $regex, bool $test, int $startat_style, int $startat_template) : mixed
Parameters
$dostyleid : int

Style ID to be searched in. -1 means search in all styles.

$searchstring : string

Search for text.

$replacestring : string

Replace with text.

$case_insensitive : bool

Case-Insensitive or not.

$regex : bool

Whether to use regular expressions.

$test : bool

Test only.

$startat_style : int

Replacement startat style ID.

$startat_template : int

Replacement startat template ID.

Return values
mixed

False if no templates found. Otherwise an array will be returned.

update()

Update a template

public update(int $templateid, string $title, string $content, string $product, string $oldcontent, bool $savehistory, string $histcomment[, bool $forcesaveonerror = false ][, mixed $additional = array() ]) : mixed
Parameters
$templateid : int

Template ID to be updated

$title : string

Template name.

$content : string

Template content.

$product : string

The product ID which the template belongs to.

$oldcontent : string

The content of the template at the time it was loaded. This is used to prevent cases where the template was changed while editing. Pass false to force an update.

$savehistory : bool

Whether to save the change in template history.

$histcomment : string

Comment of the change to be saved to template history.

$forcesaveonerror : bool = false

save the template even though there are errors.

$additional : mixed = array()
Return values
mixed

updateReplacementVar()

Update the replacement text for a replacement var

public updateReplacementVar(int $replacevarid, mixed $replacetext) : mixed
Parameters
$replacevarid : int

-- templateid for the replacement variable

$replacetext : mixed
Tags
paramstring

$replacetext

@return array ('success' => true)

@throws vB_Exception_Api 'no_permission' -- user does not have canadminstyles 'invalid_data_w_x_y_z' -- if the template does not exist or is not a replacement var

Return values
mixed

__construct()

protected __construct() : mixed
Return values
mixed

checkCanSaveTemplate()

This checks permissions for saving a template.

protected checkCanSaveTemplate(mixed $templateid, mixed $existing, mixed &$extra) : mixed

If textonly is set then the action requires only canadminstyles. Otherwise it requires canadmintemplates.

Parameters
$templateid : mixed
$existing : mixed
$extra : mixed
Return values
mixed

checkHasAdminPermission()

Determines if the calling user has the given admin permission, and if not throws an exception

protected checkHasAdminPermission(string|array<string|int, mixed> $adminPermission) : none

Checks for:

  • A valid CP Session
  • The passed adminpermission.
Parameters
$adminPermission : string|array<string|int, mixed>

The admin permission to check. If an array then the check passes if the user has any of the permissions given.

Tags
throws
inlinemodauth_required

-- The current session is not a mod/admin session

throws
nopermission_loggedin

-- The user does not have the given permission

throws
no_permission

-- The user is not logged in at all.

Return values
none

checkHasPermission()

Determines if the calling user has the given bitfield permission, and if not, throws a 'no_permission' exception.

protected checkHasPermission(string $group, string $permission) : none
Parameters
$group : string

The permission group where the permission is located

$permission : string

The permission to check

Tags
throws
no_permission
Return values
none

checkIsLoggedIn()

Determines if the calling user has the given admin permission, and if not throws an exception

protected checkIsLoggedIn() : mixed
Return values
mixed

deleteTemplateInternal()

protected deleteTemplateInternal(mixed $templateids, mixed $styleid, mixed $dobuildreplacements) : mixed
Parameters
$templateids : mixed
$styleid : mixed
$dobuildreplacements : mixed
Return values
mixed

getApiClass()

protected static getApiClass(mixed $controller[, mixed $errorCheck = true ]) : mixed
Parameters
$controller : mixed
$errorCheck : mixed = true
Return values
mixed

getApiClassNameInternal()

protected static getApiClassNameInternal(mixed $controller) : mixed
Parameters
$controller : mixed
Return values
mixed

hasAdminPermission()

Determines if the calling user has the given admin permission

protected hasAdminPermission(string|array<string|int, mixed> $adminPermission) : bool

Useful if you need to know if the calling user but do not care why they do not have that permission. Generally useful if there is a behavior difference between admins and non admins, but the call can be processed for either.

Parameters
$adminPermission : string|array<string|int, mixed>

The admin permission to check. If an array then the check passes if the user has any of the permissions given.

Return values
bool

true if checks pass, false otherwise

inDebugMode()

protected inDebugMode() : mixed
Return values
mixed

isDisableFalseReturnOnly()

Checks if method returns false response only when API is disabled.

protected isDisableFalseReturnOnly(mixed $method) : bool
Parameters
$method : mixed
Return values
bool

Indicates whether method returns false response only.

isWhiteListed()

Checks if method is white listed when API is disabled.

protected isWhiteListed(mixed $method) : bool
Parameters
$method : mixed
Return values
bool

Indicates whether method is or is not a white list.

setController()

Set controller

protected setController(mixed $controller) : mixed
Parameters
$controller : mixed
Return values
mixed

buildHooklist()

private buildHooklist() : mixed
Return values
mixed

cms_vb4_to_vb5_method_mapping()

private static cms_vb4_to_vb5_method_mapping(mixed $method, mixed &$request) : mixed
Parameters
$method : mixed
$request : mixed
Return values
mixed

default_vb4_to_vb5_method_mapping()

private static default_vb4_to_vb5_method_mapping(mixed $method) : mixed
Parameters
$method : mixed
Return values
mixed

hasAdminPermissionInternal()

Internal function to power the previous cover functions

private hasAdminPermissionInternal(mixed $adminPermission) : mixed
@param string|array $adminPermission The admin permission to check.  If an array

then the check passes if the user has any of the permissions given.

Parameters
$adminPermission : mixed
Return values
mixed

remove_nulls()

private static remove_nulls(mixed &$data) : mixed
Parameters
$data : mixed
Return values
mixed

wrapLoggerIfNeeded()

Wrap the api object with the log wrapper class if needed.

private static wrapLoggerIfNeeded(mixed $controller, mixed $api_object) : mixed
Parameters
$controller : mixed
$api_object : mixed
Return values
mixed

Search results