/// <summary> /// build a XPT Node for a parameter name /// </summary> /// <param name="ctx"></param> /// <returns></returns> public bool BuildXPTNode(VariableNameContext ctx) { RuleContext root = GetRootContext(ctx, typeof(SelectStatementBlockContext)); if (root != null) { if (((SelectStatementBlockContext)root).names.ContainsKey(ctx.GetText())) { // set the XPTreeNode to the Symbol ctx.XPTreeNode = ((StatementBlock)((SelectStatementBlockContext)root).XPTreeNode).Variables.Where(x => x.ID == ctx.GetText()).FirstOrDefault(); } } this.NotifyErrorListeners(String.Format(Messages.RCM_5, ctx.GetText(), "StatementBlock")); return(false); }
/// <summary> /// build a XPT Node for a parameter name /// </summary> /// <param name="ctx"></param> /// <returns></returns> public bool BuildXPTNode(VariableNameContext ctx) { RuleContext root = GetRootContext(ctx, typeof(SelectStatementBlockContext)); if (root != null) { if (((SelectStatementBlockContext)root).names.ContainsKey(ctx.GetText())) { // set the XPTreeNode to the Symbol ctx.XPTreeNode = ((StatementBlock)((SelectStatementBlockContext)root).XPTreeNode).Variables.Where(x => x.ID == ctx.GetText()).FirstOrDefault(); } } this.NotifyErrorListeners(String.Format(Messages.RCM_5, ctx.GetText(), "StatementBlock")); return false; }