Table of Contents

Method TryGet

Namespace
Neo4j.Driver
Assembly
Neo4j.Driver.dll

TryGet<T>(string, out T)

Tries to get the value specified by the given key and converts it to the given type.

bool TryGet<T>(string key, out T value)

Parameters

key string

The key.

value T

The value, if the key was found.

Returns

bool

true if the value is found; false otherwise.

Type Parameters

T

The type to convert to. Supported types include primitive types, Guid (for native UUID values returned by servers running Bolt 6.1+), graph types such as INode, and collection types. See As<T>(object) for the full list.