Recent snippets

Popular snippets

  • Implementing active objects with a MailboxProcessor

    Mailbox processors can easily be used to implement active objects. This example shows how to do that with a reusable wrapper type and minimal boilerplate code in the actual class definitions. Supports both asynchronous calls and synchronous calls. For the latter case, exceptions are automatically propagated back to the caller.

    92 people like this

    Posted: 14 years ago by Wolfgang Meyer

  • Chain of responsibility

    The following sample wants to make sure the person’s age is between 18 and 65, weight is no more than 200 and tall enough (>120).

    85 people like this

    Posted: 14 years ago by Tao Liu

  • Minimal XML DSL

    This snippet provides a very small internal DSL for creating and querying XML using the underlying XLinq classes.

    374 people like this

    Posted: 15 years ago by Blake Coverett

Snippets by tags

html (16) sequence (32) dsl (23) pattern matching (15) f# (43) lists (15) tryfsharp (48) array (22) agent (20) math (35) mailboxprocessor (27) web (29) staging (18) sequences (48) seq (54) regex (17) collections (16) list (56) learning f# (16) parsing (28)

View all...

Database contains 3208 snippets out of which 1719 is public.