\MocaBonita\toolsMbSingleton

Main class of the MocaBonita Singleton

Summary

Methods
Properties
Constants
getInstance()
__clone()
__wakeup()
No public properties found
No constants found
__construct()
init()
$instances
N/A
No private methods found
No private properties found
N/A

Properties

Methods

getInstance()

getInstance() : static

The singleton pattern is useful when we need to make sure that we only have a single instance of a class for the entire request lifecycle in a Web application. This usually occurs when we have global objects (such as a configuration class) or a resource (Such as an event queue).

Returns

static

__clone()

__clone() 

Clone Not allowed

Throws

\MocaBonita\tools\MbException

__wakeup()

__wakeup() 

WakeUp Not allowed.

Throws

\MocaBonita\tools\MbException

__construct()

__construct() 

Singleton construct

init()

init() 

Method to be started