Examples of XmlAttributeNode


Examples of com.google.dart.engine.html.ast.XmlAttributeNode

  private NgRepeatProcessor() {
  }

  @Override
  public void apply(AngularHtmlUnitResolver resolver, XmlTagNode node) {
    XmlAttributeNode attribute = node.getAttribute(NG_REPEAT);
    int offset = attribute.getValueToken().getOffset() + 1;
    String spec = attribute.getText();
    // check syntax
    Matcher syntaxMatcher = SYNTAX_PATTERN.matcher(spec);
    if (!syntaxMatcher.matches()) {
      resolver.reportErrorForOffset(AngularCode.INVALID_REPEAT_SYNTAX, offset, spec.length() - 2);
      return;
View Full Code Here

Examples of com.google.dart.engine.html.ast.XmlAttributeNode

    {
      AngularSelectorElement selector = element.getSelector();
      if (selector instanceof HasAttributeSelectorElementImpl) {
        selectorAttributeName = ((HasAttributeSelectorElementImpl) selector).getName();
        // resolve attribute expression
        XmlAttributeNode attribute = node.getAttribute(selectorAttributeName);
        if (attribute != null) {
          attribute.setElement(selector);
        }
      }
    }
    //
    for (AngularPropertyElement property : element.getProperties()) {
      // prepare attribute name
      String name = property.getName();
      if (name.equals(".")) {
        name = selectorAttributeName;
      }
      // prepare attribute
      XmlAttributeNode attribute = node.getAttribute(name);
      if (attribute == null) {
        continue;
      }
      // if not resolved as the selector, resolve as a property
      if (!name.equals(selectorAttributeName)) {
        attribute.setElement(property);
      }
      // skip if attribute has no value
      if (!hasValue(attribute)) {
        continue;
      }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.