本文整理汇总了PHP中Limb::saveToolkit方法的典型用法代码示例。如果您正苦于以下问题:PHP Limb::saveToolkit方法的具体用法?PHP Limb::saveToolkit怎么用?PHP Limb::saveToolkit使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Limb
的用法示例。
在下文中一共展示了Limb::saveToolkit方法的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: setUp
function setUp()
{
$this->acl_toolkit = new MockSimpleACLBaseToolkit($this);
$this->authorizer = new MockSimpleACLAuthorizer($this);
$this->acl_toolkit->setReturnReference('getAuthorizer', $this->authorizer);
Limb::registerToolkit($this->acl_toolkit, 'SimpleACL');
Limb::saveToolkit();
}
示例2: setUp
function setUp()
{
$toolkit =& Limb::toolkit();
$conn =& $toolkit->getDBConnection();
$this->db =& new SimpleDB($conn);
$this->_cleanUp();
$toolkit =& Limb::saveToolkit();
$toolkit->setRequestResolver('tree_based_entity', new TreeBasedEntityRequestResolver());
}
示例3: setUp
function setUp()
{
$view = new Component();
$this->form_component = new MockFormComponent($this);
$view->addChild($this->form_component, $this->form_id);
$toolkit =& Limb :: saveToolkit();
$toolkit->setView($view);
}
示例4: setUp
function setUp()
{
$template = "<form id='test_form' runat='server'></form>";
registerTestingTemplate('FormProcessingCommandTest.html', $template);
$toolkit =& Limb :: saveToolkit();
$template = new Template('FormProcessingCommandTest.html');
$toolkit->setView($template);
}
示例5: setUp
function setUp()
{
$toolkit =& Limb :: saveToolkit();
$this->action_resolver = new MockRequestResolver($this);
$this->service_resolver = new MockRequestResolver($this);
$this->service = new MockService($this);
$toolkit->setRequestResolver('action', $this->action_resolver);
$toolkit->setRequestResolver('service', $this->service_resolver);
$this->fc = new MockFilterChain($this);
}
示例6: setUp
function setUp()
{
$toolkit =& Limb::toolkit();
$conn =& $toolkit->getDBConnection();
$this->db =& new SimpleDB($conn);
$this->_cleanUp();
$form_template_path = '/test_content_service_node_form.html';
$form_name = 'test_form';
RegisterTestingTemplate($form_template_path, '<form id="' . $form_name . '" runat="server"></form>');
$validator = new LimbHandle(LIMB_SERVICE_NODE_DIR . '/validators/CommonEditServiceNodeValidator');
$this->command = new EditServiceNodeCommand($form_template_path, $form_name, $validator);
$toolkit =& Limb::saveToolkit();
$toolkit->setRequestResolver('tree_based_entity', new TreeBasedEntityRequestResolver());
}
示例7: setUp
function setUp()
{
$toolkit =& Limb::toolkit();
$conn =& $toolkit->getDBConnection();
$this->db =& new SimpleDB($conn);
$this->_cleanUp();
$template_path = '/test_content_service_node_form.html';
$form_id = 'test_form';
$validator = new EditTestContentServiceNodeValidator();
RegisterTestingTemplate($template_path, '<form id="' . $form_id . '" runat="server"></form>');
// dataspace field => content part field
$content_map = array('annotation' => 'annotation', 'content' => 'content');
$this->command = new EditContentServiceNodeCommand($template_path, $form_id, $validator, $content_map);
$toolkit =& Limb::saveToolkit();
$toolkit->setRequestResolver('tree_based_entity', new TreeBasedEntityRequestResolver());
}
示例8: testSaveToolkit
function testSaveToolkit()
{
$toolkit = new ImagineryToolkit();
Limb :: registerToolkit($toolkit, 'test');
$toolkit2 =& Limb :: saveToolkit('test');
$this->assertTrue($toolkit2->reseted);
$toolkit2->foo();
//restoring saved toolkit
Limb :: restoreToolkit('test');
//should be a reference to $toolkit
$toolkit3 =& Limb :: toolkit('test');
$toolkit3->bar();
$this->assertFalse($toolkit->foo_called);
$this->assertTrue($toolkit->bar_called);
Limb :: restoreToolkit('test');
}
示例9: setUp
function setUp()
{
Limb :: saveToolkit();
}
示例10: setUp
function setUp()
{
$this->toolkit =& Limb :: saveToolkit();
$this->fc = new MockFilterChain($this);
}
示例11: setUp
function setUp()
{
$this->toolkit =& Limb :: saveToolkit();
}
示例12: setUp
function setUp()
{
Limb :: saveToolkit();
$this->component = new LimbPagerComponent();
}
示例13: setUp
function setUp()
{
$this->cmd = new SimpleACLLoginCommand();
Limb::saveToolkit();
}