Skip to content

alexdodonov/mezon-singleton

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Singleton

##Intro##

This class implements basic singleton pattern.

##Usage##

Using singleton behaviour in your applications is so simple as it can be. Just extend the class Singleton, and enjoy using it!

See the code:

// including all necessary files
require_once( dirname( dirname( dirname( __FILE__ ) ) ).'/conf/conf.php' );
require_once( $MEZON_PATH.'/vendor/singleton/singleton.php' );

// creatingyour own class
class   MyClass extends Singleton
{
    // methods and their implementations
}

That's all!

You can see the Template Engine class for real usage of this pattern.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages