This sample loads JSON and then queries values from it using Argon.JToken.SelectToken(System.String)
with a regex JSON Path.
var array = JArray.Parse("""
[
{
'PackageId': 'Argon',
'Version': '11.0.1',
'ReleaseDate': '2018-02-17T00:00:00'
},
{
'PackageId': 'NUnit',
'Version': '3.9.0',
'ReleaseDate': '2017-11-10T00:00:00'
}
]
""");
// Find packages
var packages = array.SelectTokens("$.[?(@.PackageId =~ /^Argon/)]").ToList();
foreach (var item in packages)
{
Console.WriteLine((string) item["PackageId"]);
}
// Argon