Exemplo n.º 1
0
            public override object VisitClassName([NotNull] CssParser.ClassNameContext context)
            {
                var ident     = context.ident();
                var nameIdent = ident.Ident();

                if (nameIdent != null)
                {
                    string text = nameIdent.Symbol.Text;
                    freqList.Increment(text);
                }
                return(base.VisitClassName(context));
            }
Exemplo n.º 2
0
        public override object VisitClassName([NotNull] CssParser.ClassNameContext context)
        {
            var ident     = context.ident();
            var nameIdent = ident.Ident();

            if (nameIdent != null)
            {
                int    index    = nameIdent.Symbol.TokenIndex;
                IToken newToken = editClass.GetChangedToken(tokens[index]);
                tokens[index] = newToken;
            }
            return(base.VisitClassName(context));
        }
Exemplo n.º 3
0
            public override object VisitClassName([NotNull] CssParser.ClassNameContext context)
            {
                var ident     = context.ident();
                var nameIdent = ident.Ident();

                if (nameIdent != null)
                {
                    string text = nameIdent.Symbol.Text;

                    if (classNamesMap.ContainsKey(text))
                    {
                        var newNode = new CommonToken(CssParser.Ident, classNamesMap[text]);
                        ident.Replace(nameIdent, newNode);
                    }
                }
                return(base.VisitClassName(context));
            }
Exemplo n.º 4
0
        public override object VisitClassName([NotNull] CssParser.ClassNameContext context)
        {
            var ident     = context.ident();
            var nameIdent = ident.Ident();

            if (nameIdent != null)
            {
                int    index = nameIdent.Symbol.TokenIndex;
                string text  = token[index].Text;
                if (freqList.ContainsKey())
                {
                    freqList[text]++;
                }
                else
                {
                    freqList.add(text, 0);
                }
            }
            return(base.VisitClassName(context));
        }