Recent snippets

Popular snippets

  • 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

  • Read only ref

    F# implementation of RO_ref from the "Effective ML" talk.

    93 people like this

    Posted: 15 years ago by fholm

  • Asynchronous sequences

    An asynchronous sequence is similar to the seq type, but the elements of the sequence are generated asynchronously without blocking the caller as in Async. This snippet declares asynchronous sequence and uses it to compare two files in 1k blocks.

    109 people like this

    Posted: 15 years ago by Tomas Petricek

  • ObservableObject

    The ObservableObject type implements the INotifyPropertyChanged interface used in WPF and Silverlight to notify on changes to properties that are bound to a control. Specify property names type safely using F# Quotations, i.e. <@ this.PropertyName @> when invoking the NotifyPropertyChanged method. If you are following the MVVM pattern then your View Model class can inherit from the ObservableObject type.

    69 people like this

    Posted: 15 years ago by Phillip Trelford

  • WPF / SilverLight Converter II

    version 1 is http://fssnip.net/62. This new version support convert from any existing function to a converter function by using composition and pipeline. The convert function is to make the function signature agree to the IValueConverter interface. You can add new functions in the FunctionLibrary module and reuse the class definition to reduce the coding effort. The first sample is to show how to make the converter pipeline work, the second one is a debugger converter used to debug the data binding problem.

    91 people like this

    Posted: 14 years ago by Tao Liu

  • NUnit Sugar

    Some simple functions for writing more idiomatic F# tests with NUnit.

    91 people like this

    Posted: 15 years ago by Ryan Riley

Snippets by tags

computation builder (17) reflection (19) wpf (20) algorithms (25) json (16) computation expression (15) http (18) tryfsharp (48) regex (17) tutorial (17) quotations (21) list (56) staging (18) sequences (48) f# (43) kata (17) design patterns (18) collections (16) mailboxprocessor (27) parsing (28)

View all...

Database contains 3208 snippets out of which 1719 is public.