Adds dictionary searching/filtering to EPiServer Find's .NET API
In order to build Dictionary2Find the NuGet packages that it depends on must be restored. See http://docs.nuget.org/docs/workflows/using-nuget-without-committing-packages
Add DictionaryConventions to the conventions:
client.Conventions.AddDictionaryConventions();
and start searching:
result = client.Search<Document>()
.For("Henrik")
.InField(x => x.MetadataDictionary["Author"])
.GetResult();
or filtering by key/value:
result = client.Search<Document>()
.Filter(x => x.MetadataDictionary["Author"].Match("Henrik"))
.GetResult();
...by keys:
result = client.Search<Document>()
.Filter(x => x.MetadataDictionary.Keys.Match("Author"))
.GetResult();
...by values:
result = client.Search<Document>()
.Filter(x => x.MetadataDictionary.Values.Match("Henrik"))
.GetResult();