/** * This method return a singleton instance of __RoleManager instance * * @return __RoleManager a reference to the current __RoleManager instance */ public static function &getInstance() { if (self::$_instance == null) { // Use "Lazy initialization" self::$_instance = new __RoleManager(); } return self::$_instance; }