controller_selector.rb

Path: sipper/controller_selector.rb
Last Update: Fri May 23 14:38:51 -0400 2008

If the order.yaml does not have any controller then the cotrollers defined in the controllers directory are taken in the alphabetical order, otherwise the order defined in the yaml is taken for the ones present, the rest are arranged alphabetically. There can be an optional block in the yaml file which is invoked to see if the controller should be invoked or not. Much like a rules engine. If the controller doesnt want to handle a request, it returns false, true otherwise. Data structure to check for on request

 - [[fname, <controller_instance>, <block/proc>],..] ordered by order in yaml and then alphabetical
 Iteration-1 only ordered instance array, later add block

Required files

request   yaml   sip_logger   util/sipper_util   controller_class_loader  

[Validate]