public override object VisitRestrictions([NotNull] ChatParser.RestrictionsContext context) { var rList = new MsgGroups(); foreach (var r in context.restriction()) { var newList = (List <int>)VisitRestriction(r); newList.Sort(); rList.Add(newList); } return(rList); }
/// <summary> /// Visit a parse tree produced by <see cref="ChatParser.restrictions"/>. /// <para> /// The default implementation returns the result of calling <see cref="AbstractParseTreeVisitor{Result}.VisitChildren(IRuleNode)"/> /// on <paramref name="context"/>. /// </para> /// </summary> /// <param name="context">The parse tree.</param> /// <return>The visitor result.</return> public virtual Result VisitRestrictions([NotNull] ChatParser.RestrictionsContext context) { return(VisitChildren(context)); }