>> YANA 4 PHP Framework >> Docs For Class Singleton

Class Singleton

Description

«abstract» Singleton

To create a Singleton class, simply add "extends Singleton" to your class definition and add $this->checkSingletonConstraint() as the first line in your constructor.

Note: this class is abstract, because it extends an abstract super-class without implementing all abstract functions - NOT because it declares any abstract members itself.

  • access: public
  • abstract:

Located in /includes/class_singleton.php

Object
   |
   --Singleton
Method Summary

Direct descendents

Class Description
Language «Singleton» Language
PluginManager «Singleton» PluginManager
Yana «Singleton» Yana

Methods

check Singleton - constraint
void checkSingletonConstraint ()
Description:

Terminates the program and issues an E_USER_ERROR if singleton constraint is breached. (if the constructor is called and another instance of this class already exists)

  • access: protected
inherited from base classes

Inherited From Object

Documentation generated on Wed, 22 Nov 2006 20:19:15 +0100 by phpDocumentor 1.3.1

yana author: Thomas MeyerHomepage: www.all-community.de/pub