internal virtual void Optional(GremlinToSqlContext currentContext, GremlinToSqlContext optionalContext) { GremlinTableVariable newVariable = GremlinOptionalVariable.Create(this, optionalContext); currentContext.VariableList.Add(newVariable); currentContext.TableReferences.Add(newVariable); currentContext.SetPivotVariable(newVariable); }
internal virtual void Optional(GremlinToSqlContext currentContext, GremlinToSqlContext optionalContext) { GremlinVariableType variableType = GetVariableType() == optionalContext.PivotVariable.GetVariableType() ? GetVariableType() : GremlinVariableType.Table; GremlinOptionalVariable newVariable = new GremlinOptionalVariable(this, optionalContext, variableType); currentContext.VariableList.Add(newVariable); currentContext.TableReferences.Add(newVariable); currentContext.SetPivotVariable(newVariable); }