BaseSingletonClass

Extends \org\turbocommons\src\main\php\model\BaseStrictClass

A base class that implements the singleton pattern for PHP and can be extended to convert a class to a singleton object

package

Default

Methods

Protection to prevent accessing undefined properties to this class

__get(string $name) : void
inherited

Arguments

$name

string

The property name

Protection to prevent creating extra properties to this class

__set(string $name, string $value) : void
inherited

Arguments

$name

string

The property name

$value

string

The property value

Returns the Singleton instance of this class.

getInstance() : self
static

Response

self

The Singleton instance.