Recent snippets

Popular snippets

  • Composable WCF Web API using Async

    A functional wrapper around the new WCF Web APIs (http://wcf.codeplex.com/). Composition is achieved through the use of the HttpRequestMessage -> Async signature. Pushing the app calls in the MessageHandler intercepts all requests and allows you to take control at the earliest point possible before operation selection occurs. Extending this slightly to call the innerChannel's SendAsync would allow you to create a middleware layer that would work both with this and other, normal Web API services.

    56 people like this

    Posted: 13 years ago by Ryan Riley

  • Active pattern for let binding inside patterns

    The Let active pattern demonstrated by this snippet can be used to assign values to symbols in pattern matching. This is useful for writing complex pattern matching using match as we can handle multiple cases using a single clause.

    64 people like this

    Posted: 13 years ago by Tomas Petricek

  • Chain of responsibility II

    Unlike the previous chain of responsibility, this version use the pipeline to chain responsibilities.

    103 people like this

    Posted: 12 years ago by Tao Liu

Snippets by tags

list (56) fold (22) web (29) lazy (20) http (18) html (15) monad (23) regex (17) game (32) f# (43) kata (17) sequences (48) computation builder (17) fparsec (15) computation expression (15) async (98) tutorial (17) agent (20) staging (18) design patterns (18)

View all...

Database contains 3185 snippets out of which 1709 is public.