本文整理匯總了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();
}