mirror of
https://github.com/DesignPatternsPHP/DesignPatternsPHP.git
synced 2025-07-29 19:20:18 +02:00
@@ -28,6 +28,13 @@ final class Singleton
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* prevent the instance from being cloned (which would create a second instance of it)
|
||||||
|
*/
|
||||||
|
private function __clone()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* prevent from being unserialized (which would create a second instance of it)
|
* prevent from being unserialized (which would create a second instance of it)
|
||||||
*/
|
*/
|
||||||
|
Reference in New Issue
Block a user