Package com.github.sommeri.less4j.core.ast

Examples of com.github.sommeri.less4j.core.ast.SelectorAttribute


    List<HiddenTokenAwareTree> children = token.getChildren();
    if (children.size() == 0)
      throw new BugHappened(GRAMMAR_MISMATCH, token);

    if (children.size() == 1)
      return new SelectorAttribute(token, children.get(0).getText());

    if (children.size() < 3)
      throw new BugHappened(GRAMMAR_MISMATCH, token);

    Expression value = handleTerm(children.get(2));
    switch (value.getType()) {
    case IDENTIFIER_EXPRESSION:
    case STRING_EXPRESSION:
    case NUMBER:
      //those are OK
      break;

    default:
      problemsHandler.warnLessjsIncompatibleSelectorAttributeValue(value);
      break;
    }
    return new SelectorAttribute(token, children.get(0).getText(), handleSelectorOperator(children.get(1)), value);
  }
View Full Code Here


        return pseudoclassesEqual(pClass1, pClass2);
      }

      case SELECTOR_ATTRIBUTE: {
        SelectorAttribute attribute1 = (SelectorAttribute) first;
        SelectorAttribute attribute2 = (SelectorAttribute) second;

        return attributesEqual(attribute1, attribute2);
      }

      default:
View Full Code Here

TOP

Related Classes of com.github.sommeri.less4j.core.ast.SelectorAttribute

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.