I am using the Neo4j.Driver in C# to query a Neo4J database. My cypher query returns multiple nodes that don't have the same label, lets say i return both movies and actors. I have a C# Movie and a C# Actor class. In order to instantiate the proper C# class (either movie or actor) and set the properties based on the returned records, how do i find out what label(s) a returned node has?
var cursor = await transaction.RunAsync(cypher.ToString());
await cursor.ForEachAsync(record =>
{
var movie = new Movie();
movie.Name = record["name"].As<string>();
....
}