X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=src%2Forg%2Feclipse%2Fjdt%2Finternal%2Fcompiler%2Fast%2FSingleTypeReference.java;fp=src%2Forg%2Feclipse%2Fjdt%2Finternal%2Fcompiler%2Fast%2FSingleTypeReference.java;h=0000000000000000000000000000000000000000;hb=6f0cd02d46e011bd5599e1b7fefc6159cb811135;hp=4d29467d66ca46fca5e8b7a3353e883a01d95ec1;hpb=622d0e5a4b1b35b6918a516a79a0cc22272a919e;p=org.ibex.tool.git diff --git a/src/org/eclipse/jdt/internal/compiler/ast/SingleTypeReference.java b/src/org/eclipse/jdt/internal/compiler/ast/SingleTypeReference.java deleted file mode 100644 index 4d29467..0000000 --- a/src/org/eclipse/jdt/internal/compiler/ast/SingleTypeReference.java +++ /dev/null @@ -1,76 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2000, 2004 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Common Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/cpl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jdt.internal.compiler.ast; - -import org.eclipse.jdt.internal.compiler.ASTVisitor; -import org.eclipse.jdt.internal.compiler.lookup.*; - -public class SingleTypeReference extends TypeReference { - - public char[] token; - - public SingleTypeReference(char[] source, long pos) { - - token = source; - sourceStart = (int) (pos>>>32) ; - sourceEnd = (int) (pos & 0x00000000FFFFFFFFL) ; - - } - - public SingleTypeReference(char[] source ,TypeBinding type, long pos) { - this(source, pos) ; - this.resolvedType = type ; - } - - public TypeReference copyDims(int dim){ - //return a type reference copy of me with some dimensions - //warning : the new type ref has a null binding - - return new ArrayTypeReference(token,null,dim,(((long)sourceStart)<<32)+sourceEnd) ; - } - - public TypeBinding getTypeBinding(Scope scope) { - if (this.resolvedType != null) - return this.resolvedType; - return scope.getType(token); - } - - public char [][] getTypeName() { - return new char[][] { token }; - } - - public StringBuffer printExpression(int indent, StringBuffer output){ - - return output.append(token); - } - - public TypeBinding resolveTypeEnclosing(BlockScope scope, ReferenceBinding enclosingType) { - - ReferenceBinding memberTb = scope.getMemberType(token, enclosingType); - if (!memberTb.isValidBinding()) { - scope.problemReporter().invalidEnclosingType(this, memberTb, enclosingType); - return null; - } - if (isTypeUseDeprecated(memberTb, scope)) - scope.problemReporter().deprecatedType(memberTb, this); - return this.resolvedType = memberTb; - } - - public void traverse(ASTVisitor visitor, BlockScope scope) { - visitor.visit(this, scope); - visitor.endVisit(this, scope); - } - - public void traverse(ASTVisitor visitor, ClassScope scope) { - visitor.visit(this, scope); - visitor.endVisit(this, scope); - } -}