Package com.google.dart.engine.ast

Examples of com.google.dart.engine.ast.SimpleStringLiteral


  private void parseCustomTag() {
    List<Expression> arguments = annotation.getArguments().getArguments();
    if (arguments.size() == 1) {
      Expression nameExpression = arguments.get(0);
      if (nameExpression instanceof SimpleStringLiteral) {
        SimpleStringLiteral nameLiteral = (SimpleStringLiteral) nameExpression;
        String name = nameLiteral.getValue();
        int nameOffset = nameLiteral.getValueOffset();
        PolymerTagDartElementImpl element = new PolymerTagDartElementImpl(
            name,
            nameOffset,
            classElement);
        classElement.addToolkitObjects(element);
        nameLiteral.setToolkitElement(element);
      }
    }
  }
View Full Code Here


      }
      return;
    }
    // property name in quotes
    if (arg instanceof SimpleStringLiteral) {
      SimpleStringLiteral argLiteral = (SimpleStringLiteral) arg;
      String exprSource = argLiteral.getStringValue();
      int argOffset = argLiteral.getValueOffset();
      // remove leading +/-
      if (StringUtilities.startsWithChar(exprSource, '+')) {
        exprSource = exprSource.substring(1);
        argOffset++;
      } else if (StringUtilities.startsWithChar(exprSource, '-')) {
View Full Code Here

TOP

Related Classes of com.google.dart.engine.ast.SimpleStringLiteral

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.