/[Frey]/branches/mojo/lib/Frey/Mojo.pm
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /branches/mojo/lib/Frey/Mojo.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 231 by dpavlin, Sat Nov 1 13:20:25 2008 UTC revision 232 by dpavlin, Sat Nov 1 15:16:33 2008 UTC
# Line 22  sub dispatch { Line 22  sub dispatch {
22      }      }
23  }  }
24    
25    use Frey::ClassLoader;
26    
27  # This method will run once at server start  # This method will run once at server start
28  sub startup {  sub startup {
29      my $self = shift;      my $self = shift;
30    
31            Frey::ClassLoader->new->load_all_classes();
32    
33      # The routes      # The routes
34      my $r = $self->routes;      my $r = $self->routes;
35    
36      # Default route      # Default route
37      $r->route('/:controller/:action/:id')      $r->route('/:controller/:action/:class')
38        ->to(controller => 'example', action => 'welcome', id => 1);        ->to(controller => 'run', action => 'markup', class => 'Frey::ClassBrowser');
39  }  }
40    
41  1;  1;

Legend:
Removed from v.231  
changed lines
  Added in v.232

  ViewVC Help
Powered by ViewVC 1.1.26