Skip to content

inClassScope : boolean

function Util.inClassScope(class: class, includeInherited: boolean, includeFriend: boolean, classes: {[string]: class}?, defaultLevel: number?): boolean

This function checks if the current thread is allowed to access a specific class property from a certain access specifier.

Default syntax

local isAllowed = Util.inClassScope(class, false, true, Classes) -- For the Private access specifier

Parameters

class: class The class.
includeInherited: boolean Determines if inherited classes can access.
includeFriend: boolean Determines if friend classes/methods can access.
classes: Table A table that contains classes. If includeFriend is set to true, this table will be given to the Util.checkFriendship() function.
defaultLevel: number Determines the default call stack level the function will start doing the checks on.

Returns

boolean