This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static class RouteCollectionExtensions | |
{ | |
private static void MapResources(this RouteCollection routes, string model) | |
{ | |
MapResources(routes, model, model + "s"); | |
} | |
private static void MapResources(this RouteCollection routes, string model, string models) | |
{ | |
// models - index |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class JsonBuilder | |
{ | |
private readonly StringBuilder _sb; | |
private readonly Stack<bool> _hasPreviousProperties; | |
private bool RequiresComma { get { return _hasPreviousProperties.Count > 0 && _hasPreviousProperties.Peek(); } } | |
public JsonBuilder() { | |
_sb = new StringBuilder(); |
NewerOlder