aboutsummaryrefslogtreecommitdiffstats
path: root/bridge/src
diff options
context:
space:
mode:
authoracolyer <acolyer>2005-07-23 07:07:16 +0000
committeracolyer <acolyer>2005-07-23 07:07:16 +0000
commit31d0b1f9f1814b3e7f576b446ae684c326754c1b (patch)
tree4dec64751a3141a8f6acbb4bc30b3c853a2e1c56 /bridge/src
parent70b4d547c59917cc23ba75ffcb799807042f2915 (diff)
downloadaspectj-31d0b1f9f1814b3e7f576b446ae684c326754c1b.tar.gz
aspectj-31d0b1f9f1814b3e7f576b446ae684c326754c1b.zip
added extra utility method for warnings
Diffstat (limited to 'bridge/src')
-rw-r--r--bridge/src/org/aspectj/bridge/MessageUtil.java8
1 files changed, 8 insertions, 0 deletions
diff --git a/bridge/src/org/aspectj/bridge/MessageUtil.java b/bridge/src/org/aspectj/bridge/MessageUtil.java
index fd4a41efe..85d782302 100644
--- a/bridge/src/org/aspectj/bridge/MessageUtil.java
+++ b/bridge/src/org/aspectj/bridge/MessageUtil.java
@@ -175,6 +175,14 @@ public class MessageUtil {
}
}
+ /** @return WARNING_NOMESSAGE if message is empty or IMessage otherwise */ //
+ public static IMessage warn(String message, ISourceLocation location) {
+ if (LangUtil.isEmpty(message)) {
+ return WARNING_NOMESSAGE;
+ } else {
+ return new Message(message, IMessage.WARNING, null, location);
+ }
+ }
/** @return ERROR_NOMESSAGE if message is empty or IMessage otherwise */ //
public static IMessage error(String message) {
if (LangUtil.isEmpty(message)) {