[{"data":1,"prerenderedAt":1731},["ShallowReactive",2],{"blog:2007:rails-style-controllers-for-aspnet":3,"blogMore-Development":1666,"comments-rails-style-controllers-for-aspnet":1679},{"_path":4,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":8,"description":9,"date":10,"category":11,"tags":12,"excerpt":16,"body":55,"_type":1658,"_id":1659,"_source":1660,"_file":1661,"_stem":1662,"_extension":1663,"url":1664,"wordCount":1665,"minutes":252,"commentCount":142},"/blog/2007/rails-style-controllers-for-aspnet","2007",false,"en","Rails-style controllers for ASP.NET","Rob Conery has been putting together some great screen casts on SubSonic and his latest on generating controllers pointed out that ASP.NET doesn’t support the Rails-style http://site//controller/method style of execution.","2007-07-26T01:06:00+00:00","Development",[13,14,15],".NET","ASP.NET","C#",{"type":17,"children":18},"root",[19,37],{"type":20,"tag":21,"props":22,"children":23},"element","p",{},[24,27,29,31,33,35],{"type":25,"value":26},"text","Rob Conery",{"type":25,"value":28}," has been putting together some great screen casts on ",{"type":25,"value":30},"SubSonic",{"type":25,"value":32}," and his latest on generating controllers pointed out that ASP.NET doesn’t support the Rails-style ",{"type":25,"value":34},"http://site//controller/method",{"type":25,"value":36}," style of execution.",{"type":20,"tag":21,"props":38,"children":39},{},[40,42,44,46,53],{"type":25,"value":41},"This got me excited and I’ve put together a ",{"type":25,"value":43},"proof-of-concept web project",{"type":25,"value":45}," that demonstrates mapping the path to controller methods using an ",{"type":20,"tag":47,"props":48,"children":50},"code",{"className":49},[],[51],{"type":25,"value":52},"IHttpHandler",{"type":25,"value":54}," and reflection.",{"type":17,"children":56,"toc":1653},[57,82,99,106,127,267,280,470,475,737,748,1583,1588,1594,1599,1604,1617,1623,1628,1633,1638,1647],{"type":20,"tag":21,"props":58,"children":59},{},[60,68,69,75,76,81],{"type":20,"tag":61,"props":62,"children":66},"a",{"href":63,"rel":64},"https://blog.wekeroad.com",[65],"nofollow",[67],{"type":25,"value":26},{"type":25,"value":28},{"type":20,"tag":61,"props":70,"children":73},{"href":71,"rel":72},"https://subsonicproject.com",[65],[74],{"type":25,"value":30},{"type":25,"value":32},{"type":20,"tag":61,"props":77,"children":79},{"href":34,"rel":78},[65],[80],{"type":25,"value":34},{"type":25,"value":36},{"type":20,"tag":21,"props":83,"children":84},{},[85,86,92,93,98],{"type":25,"value":41},{"type":20,"tag":61,"props":87,"children":90},{"href":88,"rel":89},"https://dl.damieng.com/dotnet/RailsControllers.zip",[65],[91],{"type":25,"value":43},{"type":25,"value":45},{"type":20,"tag":47,"props":94,"children":96},{"className":95},[],[97],{"type":25,"value":52},{"type":25,"value":54},{"type":20,"tag":100,"props":101,"children":103},"h2",{"id":102},"how-it-works",[104],{"type":25,"value":105},"How it works",{"type":20,"tag":21,"props":107,"children":108},{},[109,111,117,119,125],{"type":25,"value":110},"It registers the ",{"type":20,"tag":47,"props":112,"children":114},{"className":113},[],[115],{"type":25,"value":116},"ControllerHttpHandler",{"type":25,"value":118}," via the ",{"type":20,"tag":47,"props":120,"children":122},{"className":121},[],[123],{"type":25,"value":124},"web.config",{"type":25,"value":126},":",{"type":20,"tag":128,"props":129,"children":134},"pre",{"className":130,"code":131,"language":132,"meta":133,"style":133},"language-xml shiki shiki-themes everforest-light dracula","\u003ChttpHandlers>\n  \u003Cadd path=\"/ctl/\\*/\\*\" verb=\"POST,GET,HEAD\" type=\"ControllerHttpHandler\" />\n\u003C/httpHandlers>\n","xml","",[135],{"type":20,"tag":47,"props":136,"children":137},{"__ignoreMap":133},[138,161,250],{"type":20,"tag":139,"props":140,"children":143},"span",{"class":141,"line":142},"line",1,[144,150,156],{"type":20,"tag":139,"props":145,"children":147},{"style":146},"--shiki-default:#8DA101;--shiki-dark:#F8F8F2",[148],{"type":25,"value":149},"\u003C",{"type":20,"tag":139,"props":151,"children":153},{"style":152},"--shiki-default:#F57D26;--shiki-dark:#FF79C6",[154],{"type":25,"value":155},"httpHandlers",{"type":20,"tag":139,"props":157,"children":158},{"style":146},[159],{"type":25,"value":160},">\n",{"type":20,"tag":139,"props":162,"children":164},{"class":141,"line":163},2,[165,170,175,181,186,192,198,202,207,211,215,220,224,229,233,237,241,245],{"type":20,"tag":139,"props":166,"children":167},{"style":146},[168],{"type":25,"value":169},"  \u003C",{"type":20,"tag":139,"props":171,"children":172},{"style":152},[173],{"type":25,"value":174},"add",{"type":20,"tag":139,"props":176,"children":178},{"style":177},"--shiki-default:#DFA000;--shiki-default-font-style:inherit;--shiki-dark:#50FA7B;--shiki-dark-font-style:italic",[179],{"type":25,"value":180}," path",{"type":20,"tag":139,"props":182,"children":183},{"style":146},[184],{"type":25,"value":185},"=",{"type":20,"tag":139,"props":187,"children":189},{"style":188},"--shiki-default:#8DA101;--shiki-dark:#E9F284",[190],{"type":25,"value":191},"\"",{"type":20,"tag":139,"props":193,"children":195},{"style":194},"--shiki-default:#8DA101;--shiki-dark:#F1FA8C",[196],{"type":25,"value":197},"/ctl/\\*/\\*",{"type":20,"tag":139,"props":199,"children":200},{"style":188},[201],{"type":25,"value":191},{"type":20,"tag":139,"props":203,"children":204},{"style":177},[205],{"type":25,"value":206}," verb",{"type":20,"tag":139,"props":208,"children":209},{"style":146},[210],{"type":25,"value":185},{"type":20,"tag":139,"props":212,"children":213},{"style":188},[214],{"type":25,"value":191},{"type":20,"tag":139,"props":216,"children":217},{"style":194},[218],{"type":25,"value":219},"POST,GET,HEAD",{"type":20,"tag":139,"props":221,"children":222},{"style":188},[223],{"type":25,"value":191},{"type":20,"tag":139,"props":225,"children":226},{"style":177},[227],{"type":25,"value":228}," type",{"type":20,"tag":139,"props":230,"children":231},{"style":146},[232],{"type":25,"value":185},{"type":20,"tag":139,"props":234,"children":235},{"style":188},[236],{"type":25,"value":191},{"type":20,"tag":139,"props":238,"children":239},{"style":194},[240],{"type":25,"value":116},{"type":20,"tag":139,"props":242,"children":243},{"style":188},[244],{"type":25,"value":191},{"type":20,"tag":139,"props":246,"children":247},{"style":146},[248],{"type":25,"value":249}," />\n",{"type":20,"tag":139,"props":251,"children":253},{"class":141,"line":252},3,[254,259,263],{"type":20,"tag":139,"props":255,"children":256},{"style":146},[257],{"type":25,"value":258},"\u003C/",{"type":20,"tag":139,"props":260,"children":261},{"style":152},[262],{"type":25,"value":155},{"type":20,"tag":139,"props":264,"children":265},{"style":146},[266],{"type":25,"value":160},{"type":20,"tag":21,"props":268,"children":269},{},[270,272,278],{"type":25,"value":271},"There is a very basic ",{"type":20,"tag":47,"props":273,"children":275},{"className":274},[],[276],{"type":25,"value":277},"Controller",{"type":25,"value":279}," abstract base class that just provides a simple way of accessing the context for dealing with request/response for now.",{"type":20,"tag":128,"props":281,"children":285},{"className":282,"code":283,"language":284,"meta":133,"style":133},"language-csharp shiki shiki-themes everforest-light dracula","public abstract class Controller\n{\n  protected System.Web.HttpContext context;\n\n  internal Controller(System.Web.HttpContext context) {\n    this.context = context;\n  }\n}\n","csharp",[286],{"type":20,"tag":47,"props":287,"children":288},{"__ignoreMap":133},[289,314,323,361,371,423,452,461],{"type":20,"tag":139,"props":290,"children":291},{"class":141,"line":142},[292,297,302,308],{"type":20,"tag":139,"props":293,"children":294},{"style":152},[295],{"type":25,"value":296},"public",{"type":20,"tag":139,"props":298,"children":299},{"style":152},[300],{"type":25,"value":301}," abstract",{"type":20,"tag":139,"props":303,"children":305},{"style":304},"--shiki-default:#F85552;--shiki-dark:#FF79C6",[306],{"type":25,"value":307}," class",{"type":20,"tag":139,"props":309,"children":311},{"style":310},"--shiki-default:#3A94C5;--shiki-dark:#8BE9FD",[312],{"type":25,"value":313}," Controller\n",{"type":20,"tag":139,"props":315,"children":316},{"class":141,"line":163},[317],{"type":20,"tag":139,"props":318,"children":320},{"style":319},"--shiki-default:#5C6A72;--shiki-dark:#F8F8F2",[321],{"type":25,"value":322},"{\n",{"type":20,"tag":139,"props":324,"children":325},{"class":141,"line":252},[326,331,337,342,347,351,356],{"type":20,"tag":139,"props":327,"children":328},{"style":152},[329],{"type":25,"value":330},"  protected",{"type":20,"tag":139,"props":332,"children":334},{"style":333},"--shiki-default:#3A94C5;--shiki-default-font-style:inherit;--shiki-dark:#8BE9FD;--shiki-dark-font-style:italic",[335],{"type":25,"value":336}," System",{"type":20,"tag":139,"props":338,"children":339},{"style":319},[340],{"type":25,"value":341},".",{"type":20,"tag":139,"props":343,"children":344},{"style":333},[345],{"type":25,"value":346},"Web",{"type":20,"tag":139,"props":348,"children":349},{"style":319},[350],{"type":25,"value":341},{"type":20,"tag":139,"props":352,"children":353},{"style":333},[354],{"type":25,"value":355},"HttpContext",{"type":20,"tag":139,"props":357,"children":358},{"style":319},[359],{"type":25,"value":360}," context;\n",{"type":20,"tag":139,"props":362,"children":364},{"class":141,"line":363},4,[365],{"type":20,"tag":139,"props":366,"children":368},{"emptyLinePlaceholder":367},true,[369],{"type":25,"value":370},"\n",{"type":20,"tag":139,"props":372,"children":374},{"class":141,"line":373},5,[375,380,386,391,396,400,404,408,412,418],{"type":20,"tag":139,"props":376,"children":377},{"style":152},[378],{"type":25,"value":379},"  internal",{"type":20,"tag":139,"props":381,"children":383},{"style":382},"--shiki-default:#8DA101;--shiki-dark:#50FA7B",[384],{"type":25,"value":385}," Controller",{"type":20,"tag":139,"props":387,"children":388},{"style":319},[389],{"type":25,"value":390},"(",{"type":20,"tag":139,"props":392,"children":393},{"style":333},[394],{"type":25,"value":395},"System",{"type":20,"tag":139,"props":397,"children":398},{"style":319},[399],{"type":25,"value":341},{"type":20,"tag":139,"props":401,"children":402},{"style":333},[403],{"type":25,"value":346},{"type":20,"tag":139,"props":405,"children":406},{"style":319},[407],{"type":25,"value":341},{"type":20,"tag":139,"props":409,"children":410},{"style":333},[411],{"type":25,"value":355},{"type":20,"tag":139,"props":413,"children":415},{"style":414},"--shiki-default:#5C6A72;--shiki-default-font-style:inherit;--shiki-dark:#FFB86C;--shiki-dark-font-style:italic",[416],{"type":25,"value":417}," context",{"type":20,"tag":139,"props":419,"children":420},{"style":319},[421],{"type":25,"value":422},") {\n",{"type":20,"tag":139,"props":424,"children":426},{"class":141,"line":425},6,[427,433,437,443,448],{"type":20,"tag":139,"props":428,"children":430},{"style":429},"--shiki-default:#DF69BA;--shiki-default-font-style:inherit;--shiki-dark:#BD93F9;--shiki-dark-font-style:italic",[431],{"type":25,"value":432},"    this",{"type":20,"tag":139,"props":434,"children":435},{"style":319},[436],{"type":25,"value":341},{"type":20,"tag":139,"props":438,"children":440},{"style":439},"--shiki-default:#35A77C;--shiki-dark:#F8F8F2",[441],{"type":25,"value":442},"context",{"type":20,"tag":139,"props":444,"children":445},{"style":152},[446],{"type":25,"value":447}," =",{"type":20,"tag":139,"props":449,"children":450},{"style":319},[451],{"type":25,"value":360},{"type":20,"tag":139,"props":453,"children":455},{"class":141,"line":454},7,[456],{"type":20,"tag":139,"props":457,"children":458},{"style":319},[459],{"type":25,"value":460},"  }\n",{"type":20,"tag":139,"props":462,"children":464},{"class":141,"line":463},8,[465],{"type":20,"tag":139,"props":466,"children":467},{"style":319},[468],{"type":25,"value":469},"}\n",{"type":20,"tag":21,"props":471,"children":472},{},[473],{"type":25,"value":474},"We then have a test controller or two that implement from this with a couple of methods and the required constructor:",{"type":20,"tag":128,"props":476,"children":478},{"className":282,"code":477,"language":284,"meta":133,"style":133},"public class TestController : Controller\n{\n  public TestController(System.Web.HttpContext context) : base(context) { }\n\n  public void Index() {\n    context.Response.Write(\"This is the index\");\n  }\n\n  public void Welcome() {\n    context.Response.Write(\"Welcome to the TestController\");\n  }\n}\n",[479],{"type":20,"tag":47,"props":480,"children":481},{"__ignoreMap":133},[482,508,515,571,578,601,645,652,659,680,721,729],{"type":20,"tag":139,"props":483,"children":484},{"class":141,"line":142},[485,489,493,498,503],{"type":20,"tag":139,"props":486,"children":487},{"style":152},[488],{"type":25,"value":296},{"type":20,"tag":139,"props":490,"children":491},{"style":304},[492],{"type":25,"value":307},{"type":20,"tag":139,"props":494,"children":495},{"style":310},[496],{"type":25,"value":497}," TestController",{"type":20,"tag":139,"props":499,"children":500},{"style":319},[501],{"type":25,"value":502}," : ",{"type":20,"tag":139,"props":504,"children":505},{"style":333},[506],{"type":25,"value":507},"Controller\n",{"type":20,"tag":139,"props":509,"children":510},{"class":141,"line":163},[511],{"type":20,"tag":139,"props":512,"children":513},{"style":319},[514],{"type":25,"value":322},{"type":20,"tag":139,"props":516,"children":517},{"class":141,"line":252},[518,523,527,531,535,539,543,547,551,555,560,566],{"type":20,"tag":139,"props":519,"children":520},{"style":152},[521],{"type":25,"value":522},"  public",{"type":20,"tag":139,"props":524,"children":525},{"style":382},[526],{"type":25,"value":497},{"type":20,"tag":139,"props":528,"children":529},{"style":319},[530],{"type":25,"value":390},{"type":20,"tag":139,"props":532,"children":533},{"style":333},[534],{"type":25,"value":395},{"type":20,"tag":139,"props":536,"children":537},{"style":319},[538],{"type":25,"value":341},{"type":20,"tag":139,"props":540,"children":541},{"style":333},[542],{"type":25,"value":346},{"type":20,"tag":139,"props":544,"children":545},{"style":319},[546],{"type":25,"value":341},{"type":20,"tag":139,"props":548,"children":549},{"style":333},[550],{"type":25,"value":355},{"type":20,"tag":139,"props":552,"children":553},{"style":414},[554],{"type":25,"value":417},{"type":20,"tag":139,"props":556,"children":557},{"style":319},[558],{"type":25,"value":559},") : ",{"type":20,"tag":139,"props":561,"children":563},{"style":562},"--shiki-default:#5C6A72;--shiki-default-font-style:inherit;--shiki-dark:#BD93F9;--shiki-dark-font-style:italic",[564],{"type":25,"value":565},"base",{"type":20,"tag":139,"props":567,"children":568},{"style":319},[569],{"type":25,"value":570},"(context) { }\n",{"type":20,"tag":139,"props":572,"children":573},{"class":141,"line":363},[574],{"type":20,"tag":139,"props":575,"children":576},{"emptyLinePlaceholder":367},[577],{"type":25,"value":370},{"type":20,"tag":139,"props":579,"children":580},{"class":141,"line":373},[581,585,591,596],{"type":20,"tag":139,"props":582,"children":583},{"style":152},[584],{"type":25,"value":522},{"type":20,"tag":139,"props":586,"children":588},{"style":587},"--shiki-default:#3A94C5;--shiki-dark:#FF79C6",[589],{"type":25,"value":590}," void",{"type":20,"tag":139,"props":592,"children":593},{"style":382},[594],{"type":25,"value":595}," Index",{"type":20,"tag":139,"props":597,"children":598},{"style":319},[599],{"type":25,"value":600},"() {\n",{"type":20,"tag":139,"props":602,"children":603},{"class":141,"line":425},[604,609,614,618,623,627,631,636,640],{"type":20,"tag":139,"props":605,"children":606},{"style":319},[607],{"type":25,"value":608},"    context.",{"type":20,"tag":139,"props":610,"children":611},{"style":439},[612],{"type":25,"value":613},"Response",{"type":20,"tag":139,"props":615,"children":616},{"style":319},[617],{"type":25,"value":341},{"type":20,"tag":139,"props":619,"children":620},{"style":382},[621],{"type":25,"value":622},"Write",{"type":20,"tag":139,"props":624,"children":625},{"style":319},[626],{"type":25,"value":390},{"type":20,"tag":139,"props":628,"children":629},{"style":188},[630],{"type":25,"value":191},{"type":20,"tag":139,"props":632,"children":633},{"style":194},[634],{"type":25,"value":635},"This is the index",{"type":20,"tag":139,"props":637,"children":638},{"style":188},[639],{"type":25,"value":191},{"type":20,"tag":139,"props":641,"children":642},{"style":319},[643],{"type":25,"value":644},");\n",{"type":20,"tag":139,"props":646,"children":647},{"class":141,"line":454},[648],{"type":20,"tag":139,"props":649,"children":650},{"style":319},[651],{"type":25,"value":460},{"type":20,"tag":139,"props":653,"children":654},{"class":141,"line":463},[655],{"type":20,"tag":139,"props":656,"children":657},{"emptyLinePlaceholder":367},[658],{"type":25,"value":370},{"type":20,"tag":139,"props":660,"children":662},{"class":141,"line":661},9,[663,667,671,676],{"type":20,"tag":139,"props":664,"children":665},{"style":152},[666],{"type":25,"value":522},{"type":20,"tag":139,"props":668,"children":669},{"style":587},[670],{"type":25,"value":590},{"type":20,"tag":139,"props":672,"children":673},{"style":382},[674],{"type":25,"value":675}," Welcome",{"type":20,"tag":139,"props":677,"children":678},{"style":319},[679],{"type":25,"value":600},{"type":20,"tag":139,"props":681,"children":683},{"class":141,"line":682},10,[684,688,692,696,700,704,708,713,717],{"type":20,"tag":139,"props":685,"children":686},{"style":319},[687],{"type":25,"value":608},{"type":20,"tag":139,"props":689,"children":690},{"style":439},[691],{"type":25,"value":613},{"type":20,"tag":139,"props":693,"children":694},{"style":319},[695],{"type":25,"value":341},{"type":20,"tag":139,"props":697,"children":698},{"style":382},[699],{"type":25,"value":622},{"type":20,"tag":139,"props":701,"children":702},{"style":319},[703],{"type":25,"value":390},{"type":20,"tag":139,"props":705,"children":706},{"style":188},[707],{"type":25,"value":191},{"type":20,"tag":139,"props":709,"children":710},{"style":194},[711],{"type":25,"value":712},"Welcome to the TestController",{"type":20,"tag":139,"props":714,"children":715},{"style":188},[716],{"type":25,"value":191},{"type":20,"tag":139,"props":718,"children":719},{"style":319},[720],{"type":25,"value":644},{"type":20,"tag":139,"props":722,"children":724},{"class":141,"line":723},11,[725],{"type":20,"tag":139,"props":726,"children":727},{"style":319},[728],{"type":25,"value":460},{"type":20,"tag":139,"props":730,"children":732},{"class":141,"line":731},12,[733],{"type":20,"tag":139,"props":734,"children":735},{"style":319},[736],{"type":25,"value":469},{"type":20,"tag":21,"props":738,"children":739},{},[740,742,747],{"type":25,"value":741},"Finally the magic that joins them up is the ",{"type":20,"tag":47,"props":743,"children":745},{"className":744},[],[746],{"type":25,"value":116},{"type":25,"value":126},{"type":20,"tag":128,"props":749,"children":751},{"className":282,"code":750,"language":284,"meta":133,"style":133},"using System;\nusing System.Web;\nusing System.Reflection;\n\npublic class ControllerHttpHandler : IHttpHandler\n{\n  public void ProcessRequest(HttpContext context) {\n    string[] parts = context.Request.Path.Split('/');\n    if (parts.Length \u003C 4) {\n      context.Response.Write(\"No controller & member specified\");\n      return;\n    }\n\n    string controllerName = parts[2];\n    string methodName = parts[3];\n    Type potentialController = Type.GetType(controllerName);\n    if (potentialController != null && potentialController.IsClass && potentialController.IsSubclassOf(typeof(Controller))) {\n      MethodInfo potentialMethod = potentialController.GetMethod(methodName);\n      if (potentialMethod != null) {\n        Controller controller = (Controller) Activator.CreateInstance(potentialController, context);\n        potentialMethod.Invoke(controller, null);\n      }\n      else\n        context.Response.Write(String.Format(\"Method '{0}' not found on controller '{1}'\", methodName, controllerName));\n    }\n    else\n      context.Response.Write(String.Format(\"Controller '{0}' not found\", controllerName));\n  }\n\n  public bool IsReusable {\n    get { return false; }\n  }\n}\n",[752],{"type":20,"tag":47,"props":753,"children":754},{"__ignoreMap":133},[755,773,796,820,827,852,859,891,959,992,1033,1045,1053,1061,1098,1132,1165,1238,1270,1296,1338,1366,1375,1384,1437,1445,1454,1504,1512,1520,1538,1567,1575],{"type":20,"tag":139,"props":756,"children":757},{"class":141,"line":142},[758,763,768],{"type":20,"tag":139,"props":759,"children":760},{"style":304},[761],{"type":25,"value":762},"using",{"type":20,"tag":139,"props":764,"children":766},{"style":765},"--shiki-default:#DF69BA;--shiki-default-font-style:inherit;--shiki-dark:#8BE9FD;--shiki-dark-font-style:italic",[767],{"type":25,"value":336},{"type":20,"tag":139,"props":769,"children":770},{"style":319},[771],{"type":25,"value":772},";\n",{"type":20,"tag":139,"props":774,"children":775},{"class":141,"line":163},[776,780,784,788,792],{"type":20,"tag":139,"props":777,"children":778},{"style":304},[779],{"type":25,"value":762},{"type":20,"tag":139,"props":781,"children":782},{"style":765},[783],{"type":25,"value":336},{"type":20,"tag":139,"props":785,"children":786},{"style":319},[787],{"type":25,"value":341},{"type":20,"tag":139,"props":789,"children":790},{"style":765},[791],{"type":25,"value":346},{"type":20,"tag":139,"props":793,"children":794},{"style":319},[795],{"type":25,"value":772},{"type":20,"tag":139,"props":797,"children":798},{"class":141,"line":252},[799,803,807,811,816],{"type":20,"tag":139,"props":800,"children":801},{"style":304},[802],{"type":25,"value":762},{"type":20,"tag":139,"props":804,"children":805},{"style":765},[806],{"type":25,"value":336},{"type":20,"tag":139,"props":808,"children":809},{"style":319},[810],{"type":25,"value":341},{"type":20,"tag":139,"props":812,"children":813},{"style":765},[814],{"type":25,"value":815},"Reflection",{"type":20,"tag":139,"props":817,"children":818},{"style":319},[819],{"type":25,"value":772},{"type":20,"tag":139,"props":821,"children":822},{"class":141,"line":363},[823],{"type":20,"tag":139,"props":824,"children":825},{"emptyLinePlaceholder":367},[826],{"type":25,"value":370},{"type":20,"tag":139,"props":828,"children":829},{"class":141,"line":373},[830,834,838,843,847],{"type":20,"tag":139,"props":831,"children":832},{"style":152},[833],{"type":25,"value":296},{"type":20,"tag":139,"props":835,"children":836},{"style":304},[837],{"type":25,"value":307},{"type":20,"tag":139,"props":839,"children":840},{"style":310},[841],{"type":25,"value":842}," ControllerHttpHandler",{"type":20,"tag":139,"props":844,"children":845},{"style":319},[846],{"type":25,"value":502},{"type":20,"tag":139,"props":848,"children":849},{"style":333},[850],{"type":25,"value":851},"IHttpHandler\n",{"type":20,"tag":139,"props":853,"children":854},{"class":141,"line":425},[855],{"type":20,"tag":139,"props":856,"children":857},{"style":319},[858],{"type":25,"value":322},{"type":20,"tag":139,"props":860,"children":861},{"class":141,"line":454},[862,866,870,875,879,883,887],{"type":20,"tag":139,"props":863,"children":864},{"style":152},[865],{"type":25,"value":522},{"type":20,"tag":139,"props":867,"children":868},{"style":587},[869],{"type":25,"value":590},{"type":20,"tag":139,"props":871,"children":872},{"style":382},[873],{"type":25,"value":874}," ProcessRequest",{"type":20,"tag":139,"props":876,"children":877},{"style":319},[878],{"type":25,"value":390},{"type":20,"tag":139,"props":880,"children":881},{"style":333},[882],{"type":25,"value":355},{"type":20,"tag":139,"props":884,"children":885},{"style":414},[886],{"type":25,"value":417},{"type":20,"tag":139,"props":888,"children":889},{"style":319},[890],{"type":25,"value":422},{"type":20,"tag":139,"props":892,"children":893},{"class":141,"line":463},[894,899,904,908,913,918,922,927,931,936,940,946,951,955],{"type":20,"tag":139,"props":895,"children":896},{"style":587},[897],{"type":25,"value":898},"    string",{"type":20,"tag":139,"props":900,"children":901},{"style":319},[902],{"type":25,"value":903},"[] parts ",{"type":20,"tag":139,"props":905,"children":906},{"style":152},[907],{"type":25,"value":185},{"type":20,"tag":139,"props":909,"children":910},{"style":319},[911],{"type":25,"value":912}," context.",{"type":20,"tag":139,"props":914,"children":915},{"style":439},[916],{"type":25,"value":917},"Request",{"type":20,"tag":139,"props":919,"children":920},{"style":319},[921],{"type":25,"value":341},{"type":20,"tag":139,"props":923,"children":924},{"style":439},[925],{"type":25,"value":926},"Path",{"type":20,"tag":139,"props":928,"children":929},{"style":319},[930],{"type":25,"value":341},{"type":20,"tag":139,"props":932,"children":933},{"style":382},[934],{"type":25,"value":935},"Split",{"type":20,"tag":139,"props":937,"children":938},{"style":319},[939],{"type":25,"value":390},{"type":20,"tag":139,"props":941,"children":943},{"style":942},"--shiki-default:#5C6A72;--shiki-dark:#F1FA8C",[944],{"type":25,"value":945},"'",{"type":20,"tag":139,"props":947,"children":948},{"style":194},[949],{"type":25,"value":950},"/",{"type":20,"tag":139,"props":952,"children":953},{"style":942},[954],{"type":25,"value":945},{"type":20,"tag":139,"props":956,"children":957},{"style":319},[958],{"type":25,"value":644},{"type":20,"tag":139,"props":960,"children":961},{"class":141,"line":661},[962,967,972,977,982,988],{"type":20,"tag":139,"props":963,"children":964},{"style":304},[965],{"type":25,"value":966},"    if",{"type":20,"tag":139,"props":968,"children":969},{"style":319},[970],{"type":25,"value":971}," (parts.",{"type":20,"tag":139,"props":973,"children":974},{"style":439},[975],{"type":25,"value":976},"Length",{"type":20,"tag":139,"props":978,"children":979},{"style":152},[980],{"type":25,"value":981}," \u003C",{"type":20,"tag":139,"props":983,"children":985},{"style":984},"--shiki-default:#DF69BA;--shiki-dark:#BD93F9",[986],{"type":25,"value":987}," 4",{"type":20,"tag":139,"props":989,"children":990},{"style":319},[991],{"type":25,"value":422},{"type":20,"tag":139,"props":993,"children":994},{"class":141,"line":682},[995,1000,1004,1008,1012,1016,1020,1025,1029],{"type":20,"tag":139,"props":996,"children":997},{"style":319},[998],{"type":25,"value":999},"      context.",{"type":20,"tag":139,"props":1001,"children":1002},{"style":439},[1003],{"type":25,"value":613},{"type":20,"tag":139,"props":1005,"children":1006},{"style":319},[1007],{"type":25,"value":341},{"type":20,"tag":139,"props":1009,"children":1010},{"style":382},[1011],{"type":25,"value":622},{"type":20,"tag":139,"props":1013,"children":1014},{"style":319},[1015],{"type":25,"value":390},{"type":20,"tag":139,"props":1017,"children":1018},{"style":188},[1019],{"type":25,"value":191},{"type":20,"tag":139,"props":1021,"children":1022},{"style":194},[1023],{"type":25,"value":1024},"No controller & member specified",{"type":20,"tag":139,"props":1026,"children":1027},{"style":188},[1028],{"type":25,"value":191},{"type":20,"tag":139,"props":1030,"children":1031},{"style":319},[1032],{"type":25,"value":644},{"type":20,"tag":139,"props":1034,"children":1035},{"class":141,"line":723},[1036,1041],{"type":20,"tag":139,"props":1037,"children":1038},{"style":304},[1039],{"type":25,"value":1040},"      return",{"type":20,"tag":139,"props":1042,"children":1043},{"style":319},[1044],{"type":25,"value":772},{"type":20,"tag":139,"props":1046,"children":1047},{"class":141,"line":731},[1048],{"type":20,"tag":139,"props":1049,"children":1050},{"style":319},[1051],{"type":25,"value":1052},"    }\n",{"type":20,"tag":139,"props":1054,"children":1056},{"class":141,"line":1055},13,[1057],{"type":20,"tag":139,"props":1058,"children":1059},{"emptyLinePlaceholder":367},[1060],{"type":25,"value":370},{"type":20,"tag":139,"props":1062,"children":1064},{"class":141,"line":1063},14,[1065,1069,1074,1078,1083,1088,1093],{"type":20,"tag":139,"props":1066,"children":1067},{"style":587},[1068],{"type":25,"value":898},{"type":20,"tag":139,"props":1070,"children":1071},{"style":319},[1072],{"type":25,"value":1073}," controllerName ",{"type":20,"tag":139,"props":1075,"children":1076},{"style":152},[1077],{"type":25,"value":185},{"type":20,"tag":139,"props":1079,"children":1080},{"style":439},[1081],{"type":25,"value":1082}," parts",{"type":20,"tag":139,"props":1084,"children":1085},{"style":319},[1086],{"type":25,"value":1087},"[",{"type":20,"tag":139,"props":1089,"children":1090},{"style":984},[1091],{"type":25,"value":1092},"2",{"type":20,"tag":139,"props":1094,"children":1095},{"style":319},[1096],{"type":25,"value":1097},"];\n",{"type":20,"tag":139,"props":1099,"children":1101},{"class":141,"line":1100},15,[1102,1106,1111,1115,1119,1123,1128],{"type":20,"tag":139,"props":1103,"children":1104},{"style":587},[1105],{"type":25,"value":898},{"type":20,"tag":139,"props":1107,"children":1108},{"style":319},[1109],{"type":25,"value":1110}," methodName ",{"type":20,"tag":139,"props":1112,"children":1113},{"style":152},[1114],{"type":25,"value":185},{"type":20,"tag":139,"props":1116,"children":1117},{"style":439},[1118],{"type":25,"value":1082},{"type":20,"tag":139,"props":1120,"children":1121},{"style":319},[1122],{"type":25,"value":1087},{"type":20,"tag":139,"props":1124,"children":1125},{"style":984},[1126],{"type":25,"value":1127},"3",{"type":20,"tag":139,"props":1129,"children":1130},{"style":319},[1131],{"type":25,"value":1097},{"type":20,"tag":139,"props":1133,"children":1135},{"class":141,"line":1134},16,[1136,1141,1146,1150,1155,1160],{"type":20,"tag":139,"props":1137,"children":1138},{"style":333},[1139],{"type":25,"value":1140},"    Type",{"type":20,"tag":139,"props":1142,"children":1143},{"style":319},[1144],{"type":25,"value":1145}," potentialController ",{"type":20,"tag":139,"props":1147,"children":1148},{"style":152},[1149],{"type":25,"value":185},{"type":20,"tag":139,"props":1151,"children":1152},{"style":319},[1153],{"type":25,"value":1154}," Type.",{"type":20,"tag":139,"props":1156,"children":1157},{"style":382},[1158],{"type":25,"value":1159},"GetType",{"type":20,"tag":139,"props":1161,"children":1162},{"style":319},[1163],{"type":25,"value":1164},"(controllerName);\n",{"type":20,"tag":139,"props":1166,"children":1168},{"class":141,"line":1167},17,[1169,1173,1178,1183,1188,1193,1198,1203,1207,1211,1216,1220,1225,1229,1233],{"type":20,"tag":139,"props":1170,"children":1171},{"style":304},[1172],{"type":25,"value":966},{"type":20,"tag":139,"props":1174,"children":1175},{"style":319},[1176],{"type":25,"value":1177}," (potentialController ",{"type":20,"tag":139,"props":1179,"children":1180},{"style":152},[1181],{"type":25,"value":1182},"!=",{"type":20,"tag":139,"props":1184,"children":1185},{"style":984},[1186],{"type":25,"value":1187}," null",{"type":20,"tag":139,"props":1189,"children":1190},{"style":152},[1191],{"type":25,"value":1192}," &&",{"type":20,"tag":139,"props":1194,"children":1195},{"style":319},[1196],{"type":25,"value":1197}," potentialController.",{"type":20,"tag":139,"props":1199,"children":1200},{"style":439},[1201],{"type":25,"value":1202},"IsClass",{"type":20,"tag":139,"props":1204,"children":1205},{"style":152},[1206],{"type":25,"value":1192},{"type":20,"tag":139,"props":1208,"children":1209},{"style":319},[1210],{"type":25,"value":1197},{"type":20,"tag":139,"props":1212,"children":1213},{"style":382},[1214],{"type":25,"value":1215},"IsSubclassOf",{"type":20,"tag":139,"props":1217,"children":1218},{"style":319},[1219],{"type":25,"value":390},{"type":20,"tag":139,"props":1221,"children":1222},{"style":304},[1223],{"type":25,"value":1224},"typeof",{"type":20,"tag":139,"props":1226,"children":1227},{"style":319},[1228],{"type":25,"value":390},{"type":20,"tag":139,"props":1230,"children":1231},{"style":333},[1232],{"type":25,"value":277},{"type":20,"tag":139,"props":1234,"children":1235},{"style":319},[1236],{"type":25,"value":1237},"))) {\n",{"type":20,"tag":139,"props":1239,"children":1241},{"class":141,"line":1240},18,[1242,1247,1252,1256,1260,1265],{"type":20,"tag":139,"props":1243,"children":1244},{"style":333},[1245],{"type":25,"value":1246},"      MethodInfo",{"type":20,"tag":139,"props":1248,"children":1249},{"style":319},[1250],{"type":25,"value":1251}," potentialMethod ",{"type":20,"tag":139,"props":1253,"children":1254},{"style":152},[1255],{"type":25,"value":185},{"type":20,"tag":139,"props":1257,"children":1258},{"style":319},[1259],{"type":25,"value":1197},{"type":20,"tag":139,"props":1261,"children":1262},{"style":382},[1263],{"type":25,"value":1264},"GetMethod",{"type":20,"tag":139,"props":1266,"children":1267},{"style":319},[1268],{"type":25,"value":1269},"(methodName);\n",{"type":20,"tag":139,"props":1271,"children":1273},{"class":141,"line":1272},19,[1274,1279,1284,1288,1292],{"type":20,"tag":139,"props":1275,"children":1276},{"style":304},[1277],{"type":25,"value":1278},"      if",{"type":20,"tag":139,"props":1280,"children":1281},{"style":319},[1282],{"type":25,"value":1283}," (potentialMethod ",{"type":20,"tag":139,"props":1285,"children":1286},{"style":152},[1287],{"type":25,"value":1182},{"type":20,"tag":139,"props":1289,"children":1290},{"style":984},[1291],{"type":25,"value":1187},{"type":20,"tag":139,"props":1293,"children":1294},{"style":319},[1295],{"type":25,"value":422},{"type":20,"tag":139,"props":1297,"children":1299},{"class":141,"line":1298},20,[1300,1305,1310,1314,1319,1323,1328,1333],{"type":20,"tag":139,"props":1301,"children":1302},{"style":333},[1303],{"type":25,"value":1304},"        Controller",{"type":20,"tag":139,"props":1306,"children":1307},{"style":319},[1308],{"type":25,"value":1309}," controller ",{"type":20,"tag":139,"props":1311,"children":1312},{"style":152},[1313],{"type":25,"value":185},{"type":20,"tag":139,"props":1315,"children":1316},{"style":319},[1317],{"type":25,"value":1318}," (",{"type":20,"tag":139,"props":1320,"children":1321},{"style":333},[1322],{"type":25,"value":277},{"type":20,"tag":139,"props":1324,"children":1325},{"style":319},[1326],{"type":25,"value":1327},") Activator.",{"type":20,"tag":139,"props":1329,"children":1330},{"style":382},[1331],{"type":25,"value":1332},"CreateInstance",{"type":20,"tag":139,"props":1334,"children":1335},{"style":319},[1336],{"type":25,"value":1337},"(potentialController, context);\n",{"type":20,"tag":139,"props":1339,"children":1341},{"class":141,"line":1340},21,[1342,1347,1352,1357,1362],{"type":20,"tag":139,"props":1343,"children":1344},{"style":319},[1345],{"type":25,"value":1346},"        potentialMethod.",{"type":20,"tag":139,"props":1348,"children":1349},{"style":382},[1350],{"type":25,"value":1351},"Invoke",{"type":20,"tag":139,"props":1353,"children":1354},{"style":319},[1355],{"type":25,"value":1356},"(controller, ",{"type":20,"tag":139,"props":1358,"children":1359},{"style":984},[1360],{"type":25,"value":1361},"null",{"type":20,"tag":139,"props":1363,"children":1364},{"style":319},[1365],{"type":25,"value":644},{"type":20,"tag":139,"props":1367,"children":1369},{"class":141,"line":1368},22,[1370],{"type":20,"tag":139,"props":1371,"children":1372},{"style":319},[1373],{"type":25,"value":1374},"      }\n",{"type":20,"tag":139,"props":1376,"children":1378},{"class":141,"line":1377},23,[1379],{"type":20,"tag":139,"props":1380,"children":1381},{"style":304},[1382],{"type":25,"value":1383},"      else\n",{"type":20,"tag":139,"props":1385,"children":1387},{"class":141,"line":1386},24,[1388,1393,1397,1401,1405,1410,1415,1419,1423,1428,1432],{"type":20,"tag":139,"props":1389,"children":1390},{"style":319},[1391],{"type":25,"value":1392},"        context.",{"type":20,"tag":139,"props":1394,"children":1395},{"style":439},[1396],{"type":25,"value":613},{"type":20,"tag":139,"props":1398,"children":1399},{"style":319},[1400],{"type":25,"value":341},{"type":20,"tag":139,"props":1402,"children":1403},{"style":382},[1404],{"type":25,"value":622},{"type":20,"tag":139,"props":1406,"children":1407},{"style":319},[1408],{"type":25,"value":1409},"(String.",{"type":20,"tag":139,"props":1411,"children":1412},{"style":382},[1413],{"type":25,"value":1414},"Format",{"type":20,"tag":139,"props":1416,"children":1417},{"style":319},[1418],{"type":25,"value":390},{"type":20,"tag":139,"props":1420,"children":1421},{"style":188},[1422],{"type":25,"value":191},{"type":20,"tag":139,"props":1424,"children":1425},{"style":194},[1426],{"type":25,"value":1427},"Method '{0}' not found on controller '{1}'",{"type":20,"tag":139,"props":1429,"children":1430},{"style":188},[1431],{"type":25,"value":191},{"type":20,"tag":139,"props":1433,"children":1434},{"style":319},[1435],{"type":25,"value":1436},", methodName, controllerName));\n",{"type":20,"tag":139,"props":1438,"children":1440},{"class":141,"line":1439},25,[1441],{"type":20,"tag":139,"props":1442,"children":1443},{"style":319},[1444],{"type":25,"value":1052},{"type":20,"tag":139,"props":1446,"children":1448},{"class":141,"line":1447},26,[1449],{"type":20,"tag":139,"props":1450,"children":1451},{"style":304},[1452],{"type":25,"value":1453},"    else\n",{"type":20,"tag":139,"props":1455,"children":1457},{"class":141,"line":1456},27,[1458,1462,1466,1470,1474,1478,1482,1486,1490,1495,1499],{"type":20,"tag":139,"props":1459,"children":1460},{"style":319},[1461],{"type":25,"value":999},{"type":20,"tag":139,"props":1463,"children":1464},{"style":439},[1465],{"type":25,"value":613},{"type":20,"tag":139,"props":1467,"children":1468},{"style":319},[1469],{"type":25,"value":341},{"type":20,"tag":139,"props":1471,"children":1472},{"style":382},[1473],{"type":25,"value":622},{"type":20,"tag":139,"props":1475,"children":1476},{"style":319},[1477],{"type":25,"value":1409},{"type":20,"tag":139,"props":1479,"children":1480},{"style":382},[1481],{"type":25,"value":1414},{"type":20,"tag":139,"props":1483,"children":1484},{"style":319},[1485],{"type":25,"value":390},{"type":20,"tag":139,"props":1487,"children":1488},{"style":188},[1489],{"type":25,"value":191},{"type":20,"tag":139,"props":1491,"children":1492},{"style":194},[1493],{"type":25,"value":1494},"Controller '{0}' not found",{"type":20,"tag":139,"props":1496,"children":1497},{"style":188},[1498],{"type":25,"value":191},{"type":20,"tag":139,"props":1500,"children":1501},{"style":319},[1502],{"type":25,"value":1503},", controllerName));\n",{"type":20,"tag":139,"props":1505,"children":1507},{"class":141,"line":1506},28,[1508],{"type":20,"tag":139,"props":1509,"children":1510},{"style":319},[1511],{"type":25,"value":460},{"type":20,"tag":139,"props":1513,"children":1515},{"class":141,"line":1514},29,[1516],{"type":20,"tag":139,"props":1517,"children":1518},{"emptyLinePlaceholder":367},[1519],{"type":25,"value":370},{"type":20,"tag":139,"props":1521,"children":1523},{"class":141,"line":1522},30,[1524,1528,1533],{"type":20,"tag":139,"props":1525,"children":1526},{"style":152},[1527],{"type":25,"value":522},{"type":20,"tag":139,"props":1529,"children":1530},{"style":587},[1531],{"type":25,"value":1532}," bool",{"type":20,"tag":139,"props":1534,"children":1535},{"style":319},[1536],{"type":25,"value":1537}," IsReusable {\n",{"type":20,"tag":139,"props":1539,"children":1541},{"class":141,"line":1540},31,[1542,1547,1552,1557,1562],{"type":20,"tag":139,"props":1543,"children":1544},{"style":587},[1545],{"type":25,"value":1546},"    get",{"type":20,"tag":139,"props":1548,"children":1549},{"style":319},[1550],{"type":25,"value":1551}," { ",{"type":20,"tag":139,"props":1553,"children":1554},{"style":304},[1555],{"type":25,"value":1556},"return",{"type":20,"tag":139,"props":1558,"children":1559},{"style":984},[1560],{"type":25,"value":1561}," false",{"type":20,"tag":139,"props":1563,"children":1564},{"style":319},[1565],{"type":25,"value":1566},"; }\n",{"type":20,"tag":139,"props":1568,"children":1570},{"class":141,"line":1569},32,[1571],{"type":20,"tag":139,"props":1572,"children":1573},{"style":319},[1574],{"type":25,"value":460},{"type":20,"tag":139,"props":1576,"children":1578},{"class":141,"line":1577},33,[1579],{"type":20,"tag":139,"props":1580,"children":1581},{"style":319},[1582],{"type":25,"value":469},{"type":20,"tag":21,"props":1584,"children":1585},{},[1586],{"type":25,"value":1587},"That’s it!",{"type":20,"tag":100,"props":1589,"children":1591},{"id":1590},"limitations",[1592],{"type":25,"value":1593},"Limitations",{"type":20,"tag":21,"props":1595,"children":1596},{},[1597],{"type":25,"value":1598},"The controllers and methods are mapped at run-time using reflection. This would probably be too slow for production. Also it currently has to be in a top-level folder because I can’t figure out how to pass the HTTP request back to ASP.NET to try with the rest of the stack if we don’t have a matching controller/method.",{"type":20,"tag":21,"props":1600,"children":1601},{},[1602],{"type":25,"value":1603},"One option might be to have no httpHandlers in the web.config and add the exact controller/method maps at build or run-time. This solves both the top-level problem and potentially the speed.",{"type":20,"tag":21,"props":1605,"children":1606},{},[1607,1609,1615],{"type":25,"value":1608},"Another option to address just the speed of reflection would be to cache the path/method strings to the actual method and type so the only reflection would be the ",{"type":20,"tag":47,"props":1610,"children":1612},{"className":1611},[],[1613],{"type":25,"value":1614},"Activator.CreateInstance",{"type":25,"value":1616},". If that is slow then we could look at pooling the controller instances themselves.",{"type":20,"tag":100,"props":1618,"children":1620},{"id":1619},"going-forward",[1621],{"type":25,"value":1622},"Going forward",{"type":20,"tag":21,"props":1624,"children":1625},{},[1626],{"type":25,"value":1627},"Parameters for a method could be extracted and parsed from the query-string but they are currently ignored.",{"type":20,"tag":21,"props":1629,"children":1630},{},[1631],{"type":25,"value":1632},"Response is raw output; we could do something very similar to rhtml.",{"type":20,"tag":21,"props":1634,"children":1635},{},[1636],{"type":25,"value":1637},"I’m going to chat things over with the Subsonic team and see if we can come up with anything from here.",{"type":20,"tag":21,"props":1639,"children":1640},{},[1641],{"type":20,"tag":1642,"props":1643,"children":1644},"em",{},[1645],{"type":25,"value":1646},"[)amien",{"type":20,"tag":1648,"props":1649,"children":1650},"style",{},[1651],{"type":25,"value":1652},"html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":133,"searchDepth":163,"depth":163,"links":1654},[1655,1656,1657],{"id":102,"depth":163,"text":105},{"id":1590,"depth":163,"text":1593},{"id":1619,"depth":163,"text":1622},"markdown","content:blog:2007:rails-style-controllers-for-aspnet.md","content","blog/2007/rails-style-controllers-for-aspnet.md","blog/2007/rails-style-controllers-for-aspnet","md","/blog/2007/rails-style-controllers-for-aspnet/",644,[1667,1671,1675],{"title":1668,"date":1669,"url":1670},"HTML5 Video Cheatsheet: Optimizing videos for the web","2025-12-05T00:00:00Z","/blog/2025/html5-video-cheatsheet/",{"title":1672,"date":1673,"url":1674},"Transactions in the MongoDB EF Core Provider","2025-10-25","/blog/2025/mongodb-explicit-transactions/",{"title":1676,"date":1677,"url":1678},"Queryable Encryption with the MongoDB EF Core Provider","2025-09-22","/blog/2025/mongodb-queryable-encryption/",[1680],{"_path":1681,"_dir":1682,"_draft":6,"_partial":6,"_locale":7,"title":1683,"description":1684,"id":1685,"name":1686,"email":1687,"avatar":1688,"url":1689,"date":1690,"body":1691,"_type":1658,"_id":1728,"_source":1660,"_file":1729,"_stem":1730,"_extension":1663},"/comments/rails-style-controllers-for-aspnet/1951","rails-style-controllers-for-aspnet","1951","Damien,",1951,"Rob Bazinet","rbazinet@gmail.com","https://www.gravatar.com/avatar/75d620852fc7691a0a3a86c336055e7d?r=pg&d=retro","https://www.accidentaltechnologist.com/","2007-08-03T03:49:04",{"type":17,"children":1692,"toc":1726},[1693,1697,1702,1707,1712,1717],{"type":20,"tag":21,"props":1694,"children":1695},{},[1696],{"type":25,"value":1684},{"type":20,"tag":21,"props":1698,"children":1699},{},[1700],{"type":25,"value":1701},"This is good stuff. I would like to see how far you go with this.",{"type":20,"tag":21,"props":1703,"children":1704},{},[1705],{"type":25,"value":1706},"In my opinion there has to be an easier way to Rails-like features on .NET than with MonoRail.",{"type":20,"tag":21,"props":1708,"children":1709},{},[1710],{"type":25,"value":1711},"I don't think the SubSonic solution is much in the way of MVC unless the view is the new controller.",{"type":20,"tag":21,"props":1713,"children":1714},{},[1715],{"type":25,"value":1716},"Keep it up.",{"type":20,"tag":21,"props":1718,"children":1719},{},[1720,1722],{"type":25,"value":1721},"-Rob",{"type":20,"tag":1723,"props":1724,"children":1725},"br",{},[],{"title":133,"searchDepth":163,"depth":163,"links":1727},[],"content:comments:rails-style-controllers-for-aspnet:1951.md","comments/rails-style-controllers-for-aspnet/1951.md","comments/rails-style-controllers-for-aspnet/1951",1779264592561]