Click or drag to resize

DriverExtensionsSession Method (IDriver, ActionSessionConfigBuilder)

Obtain a session which is designed to be used synchronously, which is built on top of the default asynchronous IAsyncSession with the customized SessionConfig.

Namespace:  Neo4j.Driver
Assembly:  Neo4j.Driver.Simple (in Neo4j.Driver.Simple.dll) Version: 4.1.0
Syntax
public static ISession Session(
	this IDriver driver,
	Action<SessionConfigBuilder> action
)

Parameters

driver
Type: Neo4j.DriverIDriver
driver instance
action
Type: SystemActionSessionConfigBuilder
An action, provided with a SessionConfigBuilder instance, that should populate the provided instance with desired session configurations SessionConfig.

Return Value

Type: ISession
A simple session instance

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type IDriver. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also