1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-23 17:05:26 +02:00

Minor message correction

This commit is contained in:
John Cortell 2010-10-22 16:06:47 +00:00
parent 7a3b67561a
commit 3641fa0fa2

View file

@ -555,17 +555,17 @@ public class DsfSession
if (method.isAnnotationPresent(DsfServiceEventHandler.class)) { if (method.isAnnotationPresent(DsfServiceEventHandler.class)) {
Class<?>[] paramTypes = method.getParameterTypes(); Class<?>[] paramTypes = method.getParameterTypes();
if (paramTypes.length != 1) { // must have one and only param if (paramTypes.length != 1) { // must have one and only param
throw new IllegalArgumentException("ServiceEventHandler method has incorrect number of parameters"); //$NON-NLS-1$ throw new IllegalArgumentException("@DsfServiceEventHandler method has incorrect number of parameters"); //$NON-NLS-1$
} }
retVal.add(method); retVal.add(method);
} }
} }
} catch(SecurityException e) { } catch(SecurityException e) {
throw new IllegalArgumentException("No permission to access ServiceEventHandler method"); //$NON-NLS-1$ throw new IllegalArgumentException("No permission to access @DsfServiceEventHandler method"); //$NON-NLS-1$
} }
if (retVal.isEmpty()) { if (retVal.isEmpty()) {
throw new IllegalArgumentException("No methods marked with @ServiceEventHandler in listener, is listener declared public?"); //$NON-NLS-1$ throw new IllegalArgumentException("No methods annotated with @DsfServiceEventHandler in listener, is listener declared public?"); //$NON-NLS-1$
} }
return retVal.toArray(new Method[retVal.size()]); return retVal.toArray(new Method[retVal.size()]);
} }