TenantInterface
in
Table of Contents
- isLandlord() : bool
- Checks if the provided tenant ID matches the landlord's UUID.
- isMultitenantApp() : bool
- Determines if the application is configured to operate in multi-tenant mode.
Methods
isLandlord()
Checks if the provided tenant ID matches the landlord's UUID.
public
isLandlord([null|string $tenant_id = null ]) : bool
This function determines if a given tenant ID is equivalent to the predefined LANDLORD_UUID constant, identifying if the tenant is the landlord.
Parameters
- $tenant_id : null|string = null
-
The tenant ID to check against the landlord's UUID. Default is null.
Return values
bool —True if the tenant ID matches the landlord's UUID, false otherwise.
isMultitenantApp()
Determines if the application is configured to operate in multi-tenant mode.
public
isMultitenantApp() : bool
This is based on the presence and value of the ALLOW_MULTITENANT
constant.
If ALLOW_MULTITENANT
is defined and set to true
, the application is
considered to be in multi-tenant mode.
Return values
bool —Returns true
if the application is in multi-tenant mode, otherwise false
.