This file contains hidden or 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 Person | |
| { | |
| public string FirstName { get; set; } | |
| public string LastName { get; set; } | |
| public string MiddleName { get; set; } | |
| public override string ToString() | |
| { | |
| return string.Format("{0} {1} {2}", FirstName, MiddleName, LastName); | |
| } |
This file contains hidden or 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 PersonFactory | |
| { | |
| public static FirstNameExpression CreatePerson() | |
| { | |
| return new FirstNameExpression(new Person()); | |
| } | |
| } | |
| public class FirstNameExpression | |
| { |
This file contains hidden or 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 FluentTreeViewHelper | |
| { | |
| /// <summary> | |
| /// Create an HTML tree from a recursive collection of items | |
| /// </summary> | |
| public static FluentTreeView<T> FluentTreeView<T>(this HtmlHelper html, IEnumerable<T> items) | |
| { | |
| return new FluentTreeView<T>(html, items); | |
| } | |
| } |
This file contains hidden or 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
| var myPerson = PersonFluentFactory.Init().Create(); |
This file contains hidden or 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
| static void Main(string[] args) | |
| { | |
| Person tom = PersonFactory | |
| .CreatePerson() | |
| .WithFirstName("Tom") | |
| .WithMiddleName("Paul") | |
| .WithLastName("Smith"); | |
| } |
This file contains hidden or 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 PersonFactory | |
| { | |
| public static FirstNameExpression CreatePerson() | |
| { | |
| return new FirstNameExpression(new Person()); | |
| } | |
| } | |
| public class FirstNameExpression | |
| { |
This file contains hidden or 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 DisplayModeExpression | |
| { | |
| readonly Func<HttpContextBase, bool> _condition; | |
| public DisplayModeExpression(Func<HttpContextBase, bool> condition) | |
| { | |
| _condition = condition; | |
| } | |
| public void UseDisplayMode(string displayModeSuffix) |
This file contains hidden or 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
| class Program | |
| { | |
| static void Main(string[] args) | |
| { | |
| var client = new FitBitClient(); //pretending there are no dependencies for brevity. | |
| var user = client.Get<UserProfile>(new GetUserProfileRequest("someUser")); | |
| } | |
| } |
This file contains hidden or 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
| using System; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| using System.Text; | |
| using AutoMapper; | |
| using NUnit.Framework; | |
| namespace InterfaceMapping | |
| { | |
| [TestFixture] |
This file contains hidden or 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
| using ExquisiteCorpse.Web.Home; | |
| using FubuMVC.Core; | |
| namespace ExquisiteCorpse.Web | |
| { | |
| public class ExquisiteCorpseRegistry : FubuRegistry | |
| { | |
| public ExquisiteCorpseRegistry() | |
| { | |
| Actions |
OlderNewer