From eb1d697f95742d25109b1d285db38da40464b340 Mon Sep 17 00:00:00 2001 From: aclement Date: Mon, 16 Aug 2004 16:44:13 +0000 Subject: Fix for Bugzilla Bug 72016: No problem type information from AspectJ compiler / AJDE --- bridge/src/org/aspectj/bridge/IMessage.java | 3 +++ bridge/src/org/aspectj/bridge/Message.java | 10 ++++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) (limited to 'bridge') diff --git a/bridge/src/org/aspectj/bridge/IMessage.java b/bridge/src/org/aspectj/bridge/IMessage.java index fcb807016..7829633e9 100644 --- a/bridge/src/org/aspectj/bridge/IMessage.java +++ b/bridge/src/org/aspectj/bridge/IMessage.java @@ -73,6 +73,9 @@ public interface IMessage { /** Caller can verify if this message came about because of a DEOW */ boolean getDeclared(); + /** Return the ID of the message where applicable, see IProblem for list of valid IDs */ + int getID(); + /** @return Throwable associated with this message, or null if none */ Throwable getThrown(); diff --git a/bridge/src/org/aspectj/bridge/Message.java b/bridge/src/org/aspectj/bridge/Message.java index 1ddb18d69..b568f9641 100644 --- a/bridge/src/org/aspectj/bridge/Message.java +++ b/bridge/src/org/aspectj/bridge/Message.java @@ -31,6 +31,7 @@ public class Message implements IMessage { private final String details; private final List/*SourceLocation*/ extraSourceLocations; private final boolean declared; // Is it a DEOW ? + private final int id; /** * Create a (compiler) error or warning message @@ -62,13 +63,14 @@ public class Message implements IMessage { */ public Message(String message, String details, IMessage.Kind kind, ISourceLocation sourceLocation, Throwable thrown, ISourceLocation[] extraSourceLocations) { - this(message,details,kind,sourceLocation,thrown,extraSourceLocations,false); + this(message,details,kind,sourceLocation,thrown,extraSourceLocations,false,0); } public Message(String message, String details, IMessage.Kind kind, ISourceLocation sLoc, Throwable thrown, ISourceLocation[] otherLocs, - boolean declared) { + boolean declared,int id) { this.details = details; + this.id = id; this.message = ((message!=null) ? message : ((thrown==null) ? null : thrown.getMessage())); this.kind = kind; this.sourceLocation = sLoc; @@ -176,4 +178,8 @@ public class Message implements IMessage { return extraSourceLocations; } + public int getID() { + return id; + } + } -- cgit v1.2.3