/// <summary> /// Generates the relationship string for the relationship object. /// </summary> /// <returns>The Cypher string representing the relationship object</returns> public string GetCypherRelationshipString() { SourceId = SourceId.Split(':')[1]; TargetId = TargetId.Split(':')[1]; string rolesPropertyString = "{roles:" + CypherQueryUtils.GetCypherStringArray(Roles) + "}"; return($"({SourceId})-[:{CypherQueryUtils.GetCypherRelationshipType(Type)} {rolesPropertyString}]-({TargetId})"); }
/// <summary> /// Generates the Cypher property string for the MediaNode. /// </summary> /// <returns>The Cypher property string for the MediaNode</returns> public override string GetCypherPropertyString() { // Get the base string return($"{base.GetCypherPropertyString()}, releaseDate:\"{ReleaseDate.ToShortDateString()}\", franchise:\"{Franchise}\", genres:{CypherQueryUtils.GetCypherStringArray(Genres)}"); }
/// <summary> /// Generates and returns the Cyper property string for the base /// node. The returned string is not formated with brackets '{'. /// </summary> /// <returns>A string representing the properties of the node /// for use in cypher queries</returns> public virtual string GetCypherPropertyString() { return($"names:{CypherQueryUtils.GetCypherStringArray(Names)}"); }