parameter.isAnnotationPresent(DefaultValue.class)) {
mustPatch = true;
}
boolean encoded = parameter.isAnnotationPresent(Encoded.class) || methodHasEncodedAnnotation || classHasEncodedAnnotation;
DefaultValue defaultValue = parameter.getAnnotation(DefaultValue.class);
if (defaultValue != null) {
mustPatch = true;
}
DiscoveredParameter jerseyParameter = new DiscoveredParameter(annotation, parameter.getBaseType(), defaultValue, encoded);
discovered.add(jerseyParameter);
LOGGER.fine(" recorded " + jerseyParameter);
parameterToPatchInfoMap.put(parameter, new PatchInformation(jerseyParameter, getSyntheticQualifierFor(jerseyParameter), false));
}
}
}
}
}
else {
// a method *not* annotated with @Inject -- here we only deal with
// setter methods with a JAX-RS "qualifier" (Context, QueryParam, etc.)
// on the method itself
if (isSetterMethod(method)) {
boolean methodHasEncodedAnnotation = method.isAnnotationPresent(Encoded.class);
for (Annotation annotation : method.getAnnotations()) {
Set<DiscoveredParameter> discovered = discoveredParameterMap.get(annotation.annotationType());
if (discovered != null) {
if (knownParameterQualifiers.contains(annotation.annotationType())) {
mustPatch = true;
setterMethodsWithoutInject.add(method);
for (AnnotatedParameter<? super T> parameter : method.getParameters()) {
boolean encoded = parameter.isAnnotationPresent(Encoded.class) || methodHasEncodedAnnotation || classHasEncodedAnnotation;
DefaultValue defaultValue = parameter.getAnnotation(DefaultValue.class);
if (defaultValue == null) {
defaultValue = method.getAnnotation(DefaultValue.class);
}
DiscoveredParameter jerseyParameter = new DiscoveredParameter(annotation, parameter.getBaseType(), defaultValue, encoded);
discovered.add(jerseyParameter);