Tabnine Logo
Select.astIdentifier
Code IndexAdd Tabnine to your IDE (free)

How to use
astIdentifier
method
in
lombok.ast.Select

Best Java code snippets using lombok.ast.Select.astIdentifier (Showing top 20 results out of 315)

origin: com.amazon.device.tools.lint/lint-checks

private boolean handleSelect(Select select) {
  if (select.toString().startsWith(R_DRAWABLE_PREFIX)) {
    String name = select.astIdentifier().astValue();
    if (mNotificationIcons == null) {
      mNotificationIcons = Sets.newHashSet();
    }
    mNotificationIcons.add(name);
    return true;
  }
  return false;
}
origin: com.android.tools.external.lombok/lombok-ast

@Override public void visitFieldReference(FieldReference node) {
  lombok.ast.Select select = new lombok.ast.Select();
  select.astIdentifier(toIdentifier(node.token, node.nameSourcePosition));
  select.astOperand((lombok.ast.Expression) toTree(node.receiver));
  
  set(node, setPosition(node, select));
}

origin: me.tatarka.retrolambda.projectlombok/lombok.ast

@Override public void visitFieldReference(FieldReference node) {
  lombok.ast.Select select = new lombok.ast.Select();
  select.astIdentifier(toIdentifier(node.token, node.nameSourcePosition));
  select.astOperand((lombok.ast.Expression) toTree(node.receiver));
  
  set(node, setPosition(node, select));
}

origin: me.tatarka.retrolambda.projectlombok/lombok.ast

@Override
public boolean visitSelect(Select node) {
  int start = posOfStructure(node.astIdentifier(), ".", true);
  int end = node.getPosition().getEnd();
  return set(node, setPos(start, end,
      treeMaker.Select(toExpression(node.astOperand()), toName(node.astIdentifier()))));
}

origin: org.projectlombok/lombok.ast

@Override public void visitFieldReference(FieldReference node) {
  lombok.ast.Select select = new lombok.ast.Select();
  select.astIdentifier(toIdentifier(node.token, node.nameSourcePosition));
  select.astOperand((lombok.ast.Expression) toTree(node.receiver));
  
  set(node, setPosition(node, select));
}

origin: com.android.tools.external.lombok/lombok-ast

@Override
public boolean visitSelect(Select node) {
  int start = posOfStructure(node.astIdentifier(), ".", true);
  int end = node.getPosition().getEnd();
  return set(node, setPos(start, end,
      treeMaker.Select(toExpression(node.astOperand()), toName(node.astIdentifier()))));
}

origin: org.projectlombok/lombok.ast

@Override
public boolean visitSelect(Select node) {
  int start = posOfStructure(node.astIdentifier(), ".", true);
  int end = node.getPosition().getEnd();
  return set(node, setPos(start, end,
      treeMaker.Select(toExpression(node.astOperand()), toName(node.astIdentifier()))));
}

origin: me.tatarka.retrolambda.projectlombok/lombok.ast

  private List<String> unwrapSelectChain(Select s) {
    List<String> list = Lists.newArrayList();
    while (s != null) {
      list.add(s.astIdentifier().astValue());
      Expression parent = s.astOperand();
      if (parent instanceof Select) {
        s = (Select) parent;
      } else if (parent instanceof Identifier) {
        s = null;
        list.add(((Identifier)parent).astValue());
      } else if (parent == null) {
        break;
      } else {
        throw new ResolutionException(parent, "Identifies expected here, not a " + parent.getClass().getSimpleName());
      }
    }
    
    Collections.reverse(list);
    return list;
  }
}
origin: com.amazon.device.tools.lint/lint-checks

@Override
public boolean visitSelect(Select node) {
  if (node.astIdentifier().astValue().equals("layout") //$NON-NLS-1$
      && node.astOperand() instanceof VariableReference
      && ((VariableReference) node.astOperand()).astIdentifier().astValue()
        .equals("R")                             //$NON-NLS-1$
      && node.getParent() instanceof Select) {
    String layout = ((Select) node.getParent()).astIdentifier().astValue();
    registerLayoutActivity(layout, mClassFqn);
  }
  return false;
}
origin: com.amazon.device.tools.lint/lint-checks

  @Override
  public boolean visitBinaryExpression(BinaryExpression node) {
    BinaryOperator operator = node.astOperator();
    if (operator == BinaryOperator.ASSIGN || operator == BinaryOperator.OR_ASSIGN) {
      Expression left = node.astLeft();
      String variable;
      if (left instanceof Select && ((Select) left).astOperand() instanceof This) {
        variable = ((Select) left).astIdentifier().astValue();
      } else {
        variable = left.toString();
      }
      mVariables.add(variable);
    }
    return super.visitBinaryExpression(node);
  }
}
origin: com.android.tools.external.lombok/lombok-ast

public Node createSelectOperation(Node identifier) {
  return posify(new Select().astIdentifier(createIdentifierIfNeeded(identifier, currentPos())));
}

origin: org.projectlombok/lombok.ast

public Node createSelectOperation(Node identifier) {
  return posify(new Select().astIdentifier(createIdentifierIfNeeded(identifier, currentPos())));
}

origin: me.tatarka.retrolambda.projectlombok/lombok.ast

public Node createSelectOperation(Node identifier) {
  return posify(new Select().astIdentifier(createIdentifierIfNeeded(identifier, currentPos())));
}

origin: com.android.tools.external.lombok/lombok-ast

private lombok.ast.Expression toSelect(char[][] tokens, long[] positions) {
  if (tokens.length < 2) return null;
  if (tokens.length != positions.length) throw new IllegalStateException("bug");
  
  lombok.ast.Identifier current0 = toIdentifier(tokens[0], positions[0]);
  lombok.ast.Expression current = new lombok.ast.VariableReference().astIdentifier(current0);
  current.setPosition(current0.getPosition());
  
  for (int i = 1; i < tokens.length; i++) {
    lombok.ast.Select select = new lombok.ast.Select().astIdentifier(toIdentifier(tokens[i], positions[i]));
    select.astOperand(current);
    current = select;
  }
  
  return current;
}

origin: me.tatarka.retrolambda.projectlombok/lombok.ast

private lombok.ast.Expression toSelect(char[][] tokens, long[] positions) {
  if (tokens.length < 2) return null;
  if (tokens.length != positions.length) throw new IllegalStateException("bug");
  
  lombok.ast.Identifier current0 = toIdentifier(tokens[0], positions[0]);
  lombok.ast.Expression current = new lombok.ast.VariableReference().astIdentifier(current0);
  current.setPosition(current0.getPosition());
  
  for (int i = 1; i < tokens.length; i++) {
    lombok.ast.Select select = new lombok.ast.Select().astIdentifier(toIdentifier(tokens[i], positions[i]));
    select.astOperand(current);
    current = select;
  }
  
  return current;
}

origin: org.projectlombok/lombok.ast

private lombok.ast.Expression toSelect(char[][] tokens, long[] positions) {
  if (tokens.length < 2) return null;
  if (tokens.length != positions.length) throw new IllegalStateException("bug");
  
  lombok.ast.Identifier current0 = toIdentifier(tokens[0], positions[0]);
  lombok.ast.Expression current = new lombok.ast.VariableReference().astIdentifier(current0);
  current.setPosition(current0.getPosition());
  
  for (int i = 1; i < tokens.length; i++) {
    lombok.ast.Select select = new lombok.ast.Select().astIdentifier(toIdentifier(tokens[i], positions[i]));
    select.astOperand(current);
    current = select;
  }
  
  return current;
}

origin: com.amazon.device.tools.lint/lint-checks

/** Adds any variables referenced in the given expression into the given list */
private static void addReferencedVariables(Collection<String> variables,
    Expression expression) {
  if (expression instanceof BinaryExpression) {
    BinaryExpression binary = (BinaryExpression) expression;
    addReferencedVariables(variables, binary.astLeft());
    addReferencedVariables(variables, binary.astRight());
  } else if (expression instanceof UnaryExpression) {
    UnaryExpression unary = (UnaryExpression) expression;
    addReferencedVariables(variables, unary.astOperand());
  } else if (expression instanceof VariableReference) {
    VariableReference reference = (VariableReference) expression;
    variables.add(reference.astIdentifier().astValue());
  } else if (expression instanceof Select) {
    Select select = (Select) expression;
    if (select.astOperand() instanceof This) {
      variables.add(select.astIdentifier().astValue());
    }
  }
}
origin: com.android.tools.external.lombok/lombok-ast

@Override
public boolean visitSelect(Select node) {
  parensOpen(node);
  formatter.buildInline(node);
  if (node.rawOperand() != null) {
    formatter.nameNextElement("operand");
    visit(node.rawOperand());
    formatter.append(".");
  }
  formatter.nameNextElement("selected");
  visit(node.astIdentifier());
  formatter.closeInline();
  parensClose(node);
  return true;
}

origin: me.tatarka.retrolambda.projectlombok/lombok.ast

@Override
public boolean visitSelect(Select node) {
  parensOpen(node);
  formatter.buildInline(node);
  if (node.rawOperand() != null) {
    formatter.nameNextElement("operand");
    visit(node.rawOperand());
    formatter.append(".");
  }
  formatter.nameNextElement("selected");
  visit(node.astIdentifier());
  formatter.closeInline();
  parensClose(node);
  return true;
}

origin: org.projectlombok/lombok.ast

@Override
public boolean visitSelect(Select node) {
  parensOpen(node);
  formatter.buildInline(node);
  if (node.rawOperand() != null) {
    formatter.nameNextElement("operand");
    visit(node.rawOperand());
    formatter.append(".");
  }
  formatter.nameNextElement("selected");
  visit(node.astIdentifier());
  formatter.closeInline();
  parensClose(node);
  return true;
}

lombok.astSelectastIdentifier

Popular methods of Select

  • astOperand
  • <init>
  • getPosition
  • rawOperand
  • getParent
  • toString

Popular in Java

  • Running tasks concurrently on multiple threads
  • compareTo (BigDecimal)
  • runOnUiThread (Activity)
  • findViewById (Activity)
  • InputStream (java.io)
    A readable source of bytes.Most clients will use input streams that read data from the file system (
  • PrintStream (java.io)
    Fake signature of an existing Java class.
  • UnknownHostException (java.net)
    Thrown when a hostname can not be resolved.
  • XPath (javax.xml.xpath)
    XPath provides access to the XPath evaluation environment and expressions. Evaluation of XPath Expr
  • IOUtils (org.apache.commons.io)
    General IO stream manipulation utilities. This class provides static utility methods for input/outpu
  • Loader (org.hibernate.loader)
    Abstract superclass of object loading (and querying) strategies. This class implements useful common
  • From CI to AI: The AI layer in your organization
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now