mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-16 00:48:54 +00:00
update docs
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@320072 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
702e372f6c
commit
5dbf975065
8 changed files with 87 additions and 17 deletions
|
@ -10,8 +10,8 @@
|
|||
<refsect1 role="description">
|
||||
&reftitle.description;
|
||||
<methodsynopsis>
|
||||
<modifier>abstract</modifier> <modifier>public</modifier> <type>void</type><methodname>Yaf_Route_Interface::route</methodname>
|
||||
<methodparam><type>string</type><parameter>request</parameter></methodparam>
|
||||
<modifier>abstract</modifier> <modifier>public</modifier> <type>bool</type><methodname>Yaf_Route_Interface::route</methodname>
|
||||
<methodparam><type>Yaf_Request_Abstract</type><parameter>request</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
<methodname>Yaf_Route_Interface::route</methodname> is the only method
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
&reftitle.description;
|
||||
<methodsynopsis>
|
||||
<methodname>Yaf_Route_Map::__construct</methodname>
|
||||
<methodparam choice="opt"><type>string</type><parameter>controller_prefer</parameter></methodparam>
|
||||
<methodparam choice="opt"><type>string</type><parameter>delimiter</parameter></methodparam>
|
||||
<methodparam choice="opt"><type>string</type><parameter>controller_prefer</parameter><initializer>false</initializer></methodparam>
|
||||
<methodparam choice="opt"><type>string</type><parameter>delimiter</parameter><initializer>''</initializer></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
|
||||
|
@ -29,7 +29,7 @@
|
|||
<term><parameter>controller_prefer</parameter></term>
|
||||
<listitem>
|
||||
<para>
|
||||
|
||||
Whether the result should considering as controller or action
|
||||
</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -51,6 +51,76 @@
|
|||
</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1 role="examples">
|
||||
&reftitle.examples;
|
||||
<example>
|
||||
<title><function>Yaf_Route_Map</function>example</title>
|
||||
<programlisting role="php">
|
||||
<![CDATA[
|
||||
<?php
|
||||
/**
|
||||
* Add a map route to Yaf_Router route stack
|
||||
*/
|
||||
Yaf_Dispatcher::getInstance()->getRouter()->addRoute("name",
|
||||
new Yaf_Route_Map());
|
||||
]]>
|
||||
</programlisting>
|
||||
&example.outputs.similar;
|
||||
<screen>
|
||||
<![CDATA[
|
||||
/* for http://yourdomain.com/product/foo/bar
|
||||
* route will result in following values:
|
||||
*/
|
||||
array(
|
||||
"controller" => "product_foo_bar",
|
||||
)
|
||||
]]>
|
||||
</screen>
|
||||
</example>
|
||||
<example>
|
||||
<title><function>Yaf_Route_Map</function>example</title>
|
||||
<programlisting role="php">
|
||||
<![CDATA[
|
||||
<?php
|
||||
/**
|
||||
* Add a map route to Yaf_Router route stack
|
||||
*/
|
||||
Yaf_Dispatcher::getInstance()->getRouter()->addRoute("name",
|
||||
new Yaf_Route_Map(true, "_"));
|
||||
]]>
|
||||
</programlisting>
|
||||
&example.outputs.similar;
|
||||
<screen>
|
||||
<![CDATA[
|
||||
/* for http://yourdomain.com/user/list/_/foo/22
|
||||
* route will result in following values:
|
||||
*/
|
||||
array(
|
||||
"action" => "user_list",
|
||||
)
|
||||
|
||||
/**
|
||||
* and request parameters:
|
||||
*/
|
||||
array(
|
||||
"foo" => 22,
|
||||
)
|
||||
]]>
|
||||
</screen>
|
||||
</example>
|
||||
</refsect1>
|
||||
|
||||
<refsect1 role="seealso">
|
||||
&reftitle.seealso;
|
||||
<simplelist>
|
||||
<member><methodname>Yaf_Router::addRoute</methodname></member>
|
||||
<member><classname>Yaf_Route_Static</classname></member>
|
||||
<member><classname>Yaf_Route_Supervar</classname></member>
|
||||
<member><classname>Yaf_Route_Simple</classname></member>
|
||||
<member><classname>Yaf_Route_Regex</classname></member>
|
||||
<member><classname>Yaf_Route_Rewrite</classname></member>
|
||||
</simplelist>
|
||||
</refsect1>
|
||||
|
||||
</refentry>
|
||||
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
<refsect1 role="description">
|
||||
&reftitle.description;
|
||||
<methodsynopsis>
|
||||
<modifier>public</modifier> <type>void</type><methodname>Yaf_Route_Map::route</methodname>
|
||||
<methodparam><type>string</type><parameter>request</parameter></methodparam>
|
||||
<modifier>public</modifier> <type>bool</type><methodname>Yaf_Route_Map::route</methodname>
|
||||
<methodparam><type>Yaf_Request_Abstract</type><parameter>request</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
<refsect1 role="description">
|
||||
&reftitle.description;
|
||||
<methodsynopsis>
|
||||
<modifier>public</modifier> <type>void</type><methodname>Yaf_Route_Regex::route</methodname>
|
||||
<methodparam><type>string</type><parameter>request</parameter></methodparam>
|
||||
<modifier>public</modifier> <type>bool</type><methodname>Yaf_Route_Regex::route</methodname>
|
||||
<methodparam><type>Yaf_Request_Abstract</type><parameter>request</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
<refsect1 role="description">
|
||||
&reftitle.description;
|
||||
<methodsynopsis>
|
||||
<modifier>public</modifier> <type>void</type><methodname>Yaf_Route_Rewrite::route</methodname>
|
||||
<methodparam><type>string</type><parameter>request</parameter></methodparam>
|
||||
<modifier>public</modifier> <type>bool</type><methodname>Yaf_Route_Rewrite::route</methodname>
|
||||
<methodparam><type>Yaf_Request_Abstract</type><parameter>request</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
<refsect1 role="description">
|
||||
&reftitle.description;
|
||||
<methodsynopsis>
|
||||
<modifier>public</modifier> <type>void</type><methodname>Yaf_Route_Simple::route</methodname>
|
||||
<methodparam><type>string</type><parameter>request</parameter></methodparam>
|
||||
<modifier>public</modifier> <type>bool</type><methodname>Yaf_Route_Simple::route</methodname>
|
||||
<methodparam><type>Yaf_Request_Abstract</type><parameter>request</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
see <methodname>Yaf_Route_Simple::__construct</methodname>
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
<refsect1 role="description">
|
||||
&reftitle.description;
|
||||
<methodsynopsis>
|
||||
<modifier>public</modifier> <type>void</type><methodname>Yaf_Route_Static::route</methodname>
|
||||
<methodparam><type>string</type><parameter>request</parameter></methodparam>
|
||||
<modifier>public</modifier> <type>bool</type><methodname>Yaf_Route_Static::route</methodname>
|
||||
<methodparam><type>Yaf_Request_Abstract</type><parameter>request</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
<refsect1 role="description">
|
||||
&reftitle.description;
|
||||
<methodsynopsis>
|
||||
<modifier>public</modifier> <type>void</type><methodname>Yaf_Route_Supervar::route</methodname>
|
||||
<methodparam><type>string</type><parameter>request</parameter></methodparam>
|
||||
<modifier>public</modifier> <type>bool</type><methodname>Yaf_Route_Supervar::route</methodname>
|
||||
<methodparam><type>Yaf_Request_Abstract</type><parameter>request</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
|
||||
|
|
Loading…
Reference in a new issue