Method TryGetValue
- Namespace
- LMKit.Extraction
- Assembly
- LM-Kit.NET.dll
TryGetValue(string, out object)
Tries to get the value by name or path as object.
Returns true
if found; otherwise false
.
public bool TryGetValue(string nameOrPath, out object value)
Parameters
nameOrPath
stringElement name or exact path to resolve.
value
objectWhen this method returns, contains the resolved value if found; otherwise
null
.
Returns
- bool
true
if a single value is found; otherwise,false
.
Examples
object v;
if (result.TryGetValue("bill_to.street_address", out v))
{
Console.WriteLine(v);
}
else
{
Console.WriteLine("Not found");
}