]> source.dussan.org Git - aspectj.git/commitdiff
new warnings for generics in patterns
authoracolyer <acolyer>
Thu, 21 Jul 2005 13:26:28 +0000 (13:26 +0000)
committeracolyer <acolyer>
Thu, 21 Jul 2005 13:26:28 +0000 (13:26 +0000)
weaver/src/org/aspectj/weaver/WeaverMessages.java
weaver/src/org/aspectj/weaver/weaver-messages.properties

index 52dcd664e05fe8f505c6f59476cea619c9d70e18..076d0bd32b81ee621299684f048424318aea968c 100644 (file)
@@ -132,6 +132,7 @@ public class WeaverMessages {
        public static final String INCORRECT_NUMBER_OF_TYPE_ARGUMENTS = "incorrectNumberOfTypeArguments";
        public static final String VIOLATES_TYPE_VARIABLE_BOUNDS = "violatesTypeVariableBounds";
        public static final String NO_STATIC_INIT_JPS_FOR_PARAMETERIZED_TYPES = "noStaticInitJPsForParameterizedTypes";
+       public static final String NOT_A_GENERIC_TYPE="notAGenericType";
        
        public static String format(String key) {
                return bundle.getString(key);
@@ -149,4 +150,8 @@ public class WeaverMessages {
                return MessageFormat.format(bundle.getString(key),new Object[] {insert1, insert2, insert3});
        }
 
+       public static String format(String key, Object insert1, Object insert2, Object insert3, Object insert4) {
+               return MessageFormat.format(bundle.getString(key),new Object[] {insert1, insert2, insert3, insert4});
+       }
+
 }
index 442bb03e98286ed67f6c31a427e21ad2374428bb..ddc4b79f6eea04463995b308473ecdde8dea5664 100644 (file)
@@ -140,6 +140,7 @@ bindingNonRuntimeRetentionAnnotation=Annotation type {0} does not have runtime r
 # Generics
 cantDecpMultipleParameterizations=Cannot declare parent {0} onto type {1} since it already has {2} in its hierarchy
 noParameterizedTypePatternInHandler=a parameterized type pattern may not be used in a handler pointcut expression
-incorrectNumberOfTypeArguments=Wrong number of type arguments; Type {0} requires {1}
-violatesTypeVariableBounds=Type {0} does not meet the specification for type parameter {1} in generic type {2}
+incorrectNumberOfTypeArguments=Type pattern does not match because the wrong number of type parameters are specified: Type {0} requires {1} parameter(s)
+violatesTypeVariableBounds=Type {0} does not meet the specification for type parameter {1} ({2}) in generic type {3}
+notAGenericType=Type pattern does not match because {0} is not a generic type
 noStaticInitJPsForParameterizedTypes=no static initialization join points for parameterized types, use generic or raw type instead
\ No newline at end of file