当前位置: 首页>>代码示例>>PHP>>正文


PHP db_factory::instance方法代码示例

本文整理汇总了PHP中db_factory::instance方法的典型用法代码示例。如果您正苦于以下问题:PHP db_factory::instance方法的具体用法?PHP db_factory::instance怎么用?PHP db_factory::instance使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在db_factory的用法示例。


在下文中一共展示了db_factory::instance方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: setUp

  function setUp()
  {
    $this->db =& db_factory :: instance();
    $this->db_table_test =& db_table_factory :: instance('test1');

    $this->_clean_up();
  }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:7,代码来源:db_table_test.class.php

示例2: setUp

  function setUp()
  {
    parent :: setUp();

    $this->db =& db_factory :: instance();

    $tree =& tree :: instance();

    $values['identifier'] = 'root';
    $this->node_id_root = $tree->create_root_node($values, false, true);

    $values['identifier'] = 'ru';
    $values['object_id'] = 1;
    $this->node_id_ru = $tree->create_sub_node($this->node_id_root, $values);

    $values['identifier'] = 'document';
    $values['object_id'] = 10;
    $this->node_id_document = $tree->create_sub_node($this->node_id_ru, $values);

    $values['identifier'] = 'doc1';
    $values['object_id'] = 20;
    $this->node_id_doc1 = $tree->create_sub_node($this->node_id_ru, $values);

    $values['identifier'] = 'doc2';
    $values['object_id'] = 30;
    $this->node_id_doc2 = $tree->create_sub_node($this->node_id_ru, $values);
  }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:27,代码来源:tree_identifier_rule_test.class.php

示例3: setUp

 function setUp()
 {
     $this->db =& db_factory::instance();
     $this->stats_uri = new stats_uri_self_test_version($this);
     $this->stats_uri->stats_uri();
     $this->_clean_up();
 }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:7,代码来源:stats_uri_test.class.php

示例4: setUp

  function setUp()
  {
    $this->report = new stats_referers_report();
    $this->db =& db_factory :: instance();

    $this->_clean_up();
  }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:7,代码来源:stats_referers_report_test.class.php

示例5: setUp

 function setUp()
 {
     $this->db = db_factory::instance();
     debug_mock::init($this);
     $this->driver = new materialized_path_driver_test_version();
     $this->_clean_up();
 }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:7,代码来源:materialized_path_driver_test.class.php

示例6: db_table

 function db_table()
 {
     $this->_db_table_name = $this->_define_db_table_name();
     $this->_columns = $this->_define_columns();
     $this->_constraints = $this->_define_constraints();
     $this->_db =& db_factory::instance();
 }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:7,代码来源:db_table.class.php

示例7: setUp

 function setUp()
 {
     $this->db = db_factory::instance();
     debug_mock::init($this);
     $this->driver = new nested_sets_driver_test_version();
     $this->_clean_up();
 }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:7,代码来源:nested_sets_driver_test.class.php

示例8: setUp

 function setUp()
 {
     $this->db =& db_factory::instance();
     $this->stats_referer = new stats_referer_self_test_version($this);
     $this->stats_referer->stats_referer();
     $this->_clean_up();
 }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:7,代码来源:stats_referer_test.class.php

示例9: instance

	function full_text_search()
	{
		$this->db =& db_factory :: instance();
		$this->indexer =& new full_text_indexer();
		
		$this->use_boolean_mode = $this->_check_boolean_mode();
	}
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:7,代码来源:full_text_search.class.php

示例10: setUp

  function setUp()
  {
    $this->db =& db_factory :: instance();
    $this->links_manager =& new links_manager();

    $this->_clean_up();
  }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:7,代码来源:links_manager_test.class.php

示例11: setUp

 function setUp()
 {
     $this->db =& db_factory::instance();
     $this->_clean_up();
     $this->_init_site_object();
     $this->object->set_attribute('controller_name', 'site_object_controller');
     $controller_id = site_object_controller::get_id('site_object_controller');
     $this->object->set_attribute('controller_id', $controller_id);
     debug_mock::init($this);
     $user =& user::instance();
     $user->_set_id(10);
     $tree =& tree::instance();
     $values['identifier'] = 'root';
     $values['object_id'] = 100;
     $this->root_node_id = $tree->create_root_node($values, false, true);
     $class_id = $this->object->get_class_id();
     $this->db->sql_insert('sys_site_object', array('id' => 100, 'class_id' => $class_id, 'current_version' => 1));
     $values['identifier'] = 'ru';
     $values['object_id'] = 1;
     $this->parent_node_id = $tree->create_sub_node($this->root_node_id, $values);
     $this->db->sql_insert('sys_site_object', array('id' => 1, 'class_id' => $class_id, 'current_version' => 1));
     $values['identifier'] = 'document';
     $values['object_id'] = 10;
     $this->sub_node_id = $tree->create_sub_node($this->parent_node_id, $values);
     $this->db->sql_insert('sys_site_object', array('id' => 10, 'class_id' => $class_id, 'current_version' => 1));
 }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:26,代码来源:site_object_manipulation_test.class.php

示例12: _valid_perform

 function _valid_perform()
 {
     $object_data =& fetch_mapped_by_url();
     $data = $this->_export();
     $phpbb_user_data['user_rank'] = $data['rank'];
     $db =& db_factory::instance();
     return $db->sql_update('phpbb_users', $phpbb_user_data, array('user_id' => $object_data['id']));
 }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:8,代码来源:set_phpbb_rank_action.class.php

示例13: instance

  function site_object_controller_tester($class_name)
  {
    $this->db =& db_factory :: instance();

    $this->class_name = $class_name;

    parent :: LimbTestCase();
  }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:8,代码来源:site_object_controller_tester.class.php

示例14: instance

  function site_object_tester($class_name) 
  {
  	$this->db =& db_factory :: instance();
  	
  	$this->class_name = $class_name;

  	parent :: UnitTestCase();
  }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:8,代码来源:site_object_tester.class.php

示例15: setUp

 function setUp()
 {
     $this->db =& db_factory::instance();
     $this->cart_handler =& new special_db_cart_handler($this);
     $this->cart_handler->db_cart_handler(10);
     $this->user = new Mockuser($this);
     $this->cart_handler->setReturnReference('_get_user', $this->user);
     $this->_clean_up();
 }
开发者ID:BackupTheBerlios,项目名称:limb-svn,代码行数:9,代码来源:db_cart_handler_test.class.php


注:本文中的db_factory::instance方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。