aboutsummaryrefslogtreecommitdiffstats
path: root/org.aspectj.ajdt.core
diff options
context:
space:
mode:
authoraclement <aclement>2005-08-18 07:51:03 +0000
committeraclement <aclement>2005-08-18 07:51:03 +0000
commitdea8672c24a4ef917fc37619282b1695de2e843d (patch)
treeef8cf0f1bfb3fd0723f03ad3fa61e42b85741326 /org.aspectj.ajdt.core
parent9329ddd9d346ad2474d249777c172e8015148cf1 (diff)
downloadaspectj-dea8672c24a4ef917fc37619282b1695de2e843d.tar.gz
aspectj-dea8672c24a4ef917fc37619282b1695de2e843d.zip
Modified access to onType to be via a get/set pair - enabling me to get in and do some stuff for generic ITDs.
Diffstat (limited to 'org.aspectj.ajdt.core')
-rw-r--r--org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/InterTypeDeclaration.java10
-rw-r--r--org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/parser/DeclarationFactory.java2
-rw-r--r--org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/AsmElementFormatter.java4
3 files changed, 12 insertions, 4 deletions
diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/InterTypeDeclaration.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/InterTypeDeclaration.java
index 79777a767..b8eeb4a85 100644
--- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/InterTypeDeclaration.java
+++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/InterTypeDeclaration.java
@@ -44,7 +44,7 @@ import org.aspectj.weaver.Shadow;
* @author Jim Hugunin
*/
public abstract class InterTypeDeclaration extends AjMethodDeclaration {
- public TypeReference onType;
+ protected TypeReference onType;
protected ReferenceBinding onTypeBinding;
protected List phantomTypeVariableToRealIndex;
@@ -273,5 +273,13 @@ public abstract class InterTypeDeclaration extends AjMethodDeclaration {
public char[] getDeclaredSelector() {
return declaredSelector;
}
+
+ public void setOnType(TypeReference onType) {
+ this.onType = onType;
+ }
+
+ public TypeReference getOnType() {
+ return onType;
+ }
}
diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/parser/DeclarationFactory.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/parser/DeclarationFactory.java
index 250e791f0..750f6997d 100644
--- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/parser/DeclarationFactory.java
+++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/parser/DeclarationFactory.java
@@ -258,7 +258,7 @@ public class DeclarationFactory implements IDeclarationFactory {
* @see org.eclipse.jdt.internal.compiler.parser.Parser.IDeclarationFactory#setOnType(org.eclipse.jdt.internal.compiler.ast.MethodDeclaration, org.eclipse.jdt.internal.compiler.ast.TypeReference)
*/
public void setOnType(MethodDeclaration interTypeDecl, TypeReference onType) {
- ((InterTypeDeclaration)interTypeDecl).onType = onType;
+ ((InterTypeDeclaration)interTypeDecl).setOnType(onType);
}
/* (non-Javadoc)
diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/AsmElementFormatter.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/AsmElementFormatter.java
index 756a2bc6a..8dab02aec 100644
--- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/AsmElementFormatter.java
+++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/AsmElementFormatter.java
@@ -185,7 +185,7 @@ public class AsmElementFormatter {
} else if (methodDeclaration instanceof InterTypeDeclaration) {
InterTypeDeclaration itd = (InterTypeDeclaration)methodDeclaration;
- String name = itd.onType.toString() + "." + new String(itd.getDeclaredSelector());
+ String name = itd.getOnType().toString() + "." + new String(itd.getDeclaredSelector());
if (methodDeclaration instanceof InterTypeFieldDeclaration) {
node.setKind(IProgramElement.Kind.INTER_TYPE_FIELD);
node.setName(name);
@@ -206,7 +206,7 @@ public class AsmElementFormatter {
// }
// argumentsSignature.append(")");
// InterTypeConstructorDeclaration itcd = (InterTypeConstructorDeclaration)methodDeclaration;
- node.setName(itd.onType.toString() + "." + itd.onType.toString()/*+argumentsSignature.toString()*/);
+ node.setName(itd.getOnType().toString() + "." + itd.getOnType().toString()/*+argumentsSignature.toString()*/);
} else {
node.setKind(IProgramElement.Kind.ERROR);
node.setName(name);