Asf_Dispatcher::setDefaultAction

设置默认的action名称


Description

public Asf_Dispatcher Asf_Dispatcher::setDefaultAction(string $name)

Parameters

name

名称, 不区分大小写

Return Values

Asf_Dispatcher Object 代表返回成功, false 代表失败

Examples

Example #1

<?php
class Bootstrap
{
    public function _initHow($dispatcher)
    {
        $dispatcher->setDefaultAction('check');
    }
}

Example #2

<?php
class Bootstrap
{
    public function _initHow($dispatcher)
    {
        $dispatcher->setDefaultModule('api')->setDefaultService('index')
            ->setDefaultAction('check');
    }
}