Examples of QualifiedAllocationExpression


Examples of org.eclipse.jdt.internal.compiler.ast.QualifiedAllocationExpression

  }

  TypeDeclaration updatedType = updatedTypeDeclaration(depth + 1, knownTypes);
  if (updatedType != null && (updatedType.bits & ASTNode.IsAnonymousType) != 0){
    /* in presence of an anonymous type, we want the full allocation expression */
    QualifiedAllocationExpression allocation = updatedType.allocation;

    if (allocation.statementEnd == -1) {
      allocation.statementEnd = updatedType.declarationSourceEnd;
    }
    return allocation;
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.ast.QualifiedAllocationExpression

  }
  TypeBinding missingType = (TypeBinding) missingTypes.get(0);
  int start = location.sourceStart;
  int end = location.sourceEnd;
  if (location instanceof QualifiedAllocationExpression) {
    QualifiedAllocationExpression qualifiedAllocation = (QualifiedAllocationExpression) location;
    if (qualifiedAllocation.anonymousType != null) {
      start = qualifiedAllocation.anonymousType.sourceStart;
      end = qualifiedAllocation.anonymousType.sourceEnd;
    }
  }
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.ast.QualifiedAllocationExpression

    superInterfacesLength = superInterfaces.length;
    interfaceNames = new char[superInterfacesLength][];
  } else {
    if ((typeDeclaration.bits & ASTNode.IsAnonymousType) != 0) {
      // see PR 3442
      QualifiedAllocationExpression alloc = typeDeclaration.allocation;
      if (alloc != null && alloc.type != null) {
        superInterfaces = new TypeReference[] { alloc.type};
        superInterfacesLength = 1;
        interfaceNames = new char[1][];
      }
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.ast.QualifiedAllocationExpression

  this.sourceEnds = null;
}
private int sourceEnd(TypeDeclaration typeDeclaration) {
  if ((typeDeclaration.bits & ASTNode.IsAnonymousType) != 0) {
    QualifiedAllocationExpression allocation = typeDeclaration.allocation;
    if (allocation.enumConstant != null) // case of enum constant body
      return allocation.enumConstant.sourceEnd;
    return allocation.type.sourceEnd;
  } else {
    return typeDeclaration.sourceEnd;
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.ast.QualifiedAllocationExpression

  }
  TypeBinding missingType = (TypeBinding) missingTypes.get(0);
  int start = location.sourceStart;
  int end = location.sourceEnd;
  if (location instanceof QualifiedAllocationExpression) {
    QualifiedAllocationExpression qualifiedAllocation = (QualifiedAllocationExpression) location;
    if (qualifiedAllocation.anonymousType != null) {
      start = qualifiedAllocation.anonymousType.sourceStart;
      end = qualifiedAllocation.anonymousType.sourceEnd;
    }
  }
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.ast.QualifiedAllocationExpression

  }

  TypeDeclaration updatedType = updatedTypeDeclaration(depth + 1, knownTypes);
  if (updatedType != null && (updatedType.bits & ASTNode.IsAnonymousType) != 0){
    /* in presence of an anonymous type, we want the full allocation expression */
    QualifiedAllocationExpression allocation = updatedType.allocation;

    if (allocation.statementEnd == -1) {
      allocation.statementEnd = updatedType.declarationSourceEnd;
    }
    return allocation;
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.ast.QualifiedAllocationExpression

  }
  TypeBinding missingType = (TypeBinding) missingTypes.get(0);
  int start = location.sourceStart;
  int end = location.sourceEnd;
  if (location instanceof QualifiedAllocationExpression) {
    QualifiedAllocationExpression qualifiedAllocation = (QualifiedAllocationExpression) location;
    if (qualifiedAllocation.anonymousType != null) {
      start = qualifiedAllocation.anonymousType.sourceStart;
      end = qualifiedAllocation.anonymousType.sourceEnd;
    }
  }
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.ast.QualifiedAllocationExpression

  if (((length = this.astLengthStack[this.astLengthPtr--]) == 1)
    && (this.astStack[this.astPtr] == null)) {
    //NO ClassBody
    this.astPtr--;
    if (isQualified) {
      alloc = new QualifiedAllocationExpression();
    } else {
      alloc = new AllocationExpression();
    }
    alloc.sourceEnd = this.endPosition; //the position has been stored explicitly
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.ast.QualifiedAllocationExpression

    anonymousType.name = CharOperation.NO_CHAR;
    anonymousType.bits |= (ASTNode.IsAnonymousType|ASTNode.IsLocalType);
    anonymousType.sourceStart = this.intStack[this.intPtr--];
    anonymousType.declarationSourceStart = anonymousType.sourceStart;
    anonymousType.sourceEnd = this.rParenPos; // closing parenthesis
    QualifiedAllocationExpression alloc = new QualifiedAllocationExpression(anonymousType);
    alloc.type = getTypeReference(0);
    alloc.sourceStart = anonymousType.sourceStart;
    alloc.sourceEnd = anonymousType.sourceEnd ;
    this.lastCheckPoint = anonymousType.bodyStart = this.scanner.currentPosition;
    this.currentElement = this.currentElement.add(anonymousType, 0);
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.ast.QualifiedAllocationExpression

protected void consumeClassInstanceCreationExpressionQualified() {
  // ClassInstanceCreationExpression ::= Primary '.' 'new' SimpleName '(' ArgumentListopt ')' ClassBodyopt
  // ClassInstanceCreationExpression ::= ClassInstanceCreationExpressionName 'new' SimpleName '(' ArgumentListopt ')' ClassBodyopt
  classInstanceCreation(true);

  QualifiedAllocationExpression qae =
    (QualifiedAllocationExpression) this.expressionStack[this.expressionPtr];
 
  if (qae.anonymousType == null) {
    this.expressionLengthPtr--;
    this.expressionPtr--;
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.