<?xml version="1.0" encoding="utf-8"?>
<slide>
	<title>Router</title>

	<list>
		<bullet>The router is responsible for the selection of controller
		and action method.</bullet>
		<bullet>Each router contains an array of routes.</bullet>
		<bullet>Routes are objects of classes that implement the
		%ezcMvcRoute% interface: %ezcMvcRailsRoute%,
		%ezcMvcRegexpRoute% and %ezcMvcCatchAllRoute%.</bullet>
		<bullet>Each route tests itself if it matches the request data, and
		returns an %ezcMvcRoutingInformation% object if it matched.</bullet>
	</list>
<example>&lt;?php
return array(
  new ezcMvcRailsRoute( '/', 'shareHomeController', 'list' ),
  new ezcMvcRailsRoute( '/update/:id', 'shareHomeController', 'show' ),
  new ezcMvcRailsRoute( '/view/:id', 
    'shareHomeController', 'show', array( 'id' => 1 ) ),
  new ezcMvcRegexpRoute( '@^people(/((?P&lt;nr>[0-9]+)|(?P&lt;name>.+)))?$@',
    'testController', 'action', array( 'nr' => '', 'name' => '' ),
  new ezcMvcCatchAllRoute() );
?></example>
</slide>
