The caching functions are available in the Fog.Caching module. You can use them with code such as the following:
[<DataContract>]
type TestRecord =
{ [<DataMember>] mutable Id : Guid
[<DataMember>] mutable Name : string }
let testRecord = { Id = Guid.NewGuid(); Name = "Dan" }
let key = testRecord.Id.ToString()
Put key testRecord |> ignore
let result = Get<TestRecord> key
Fog is available via NuGet as ID Fog and the full source can be found on my GitHub.
No comments:
Post a Comment