{
@Produces
@TypedMessageLogger
Object produceTypedLogger(InjectionPoint injectionPoint)
{
Annotated annotated = injectionPoint.getAnnotated();
if (annotated.isAnnotationPresent(Category.class))
{
if (annotated.isAnnotationPresent(Locale.class))
{
return getMessageLogger(getInjectionPointRawType(injectionPoint), annotated.getAnnotation(Category.class).value(), toLocale(annotated.getAnnotation(Locale.class).value()));
}
else
{
return getMessageLogger(getInjectionPointRawType(injectionPoint), annotated.getAnnotation(Category.class).value());
}
}
else if (annotated.isAnnotationPresent(TypedCategory.class))
{
if (annotated.isAnnotationPresent(Locale.class))
{
return getMessageLogger(getInjectionPointRawType(injectionPoint), annotated.getAnnotation(TypedCategory.class).value().getName(), toLocale(annotated.getAnnotation(Locale.class).value()));
}
else
{
return getMessageLogger(getInjectionPointRawType(injectionPoint), annotated.getAnnotation(TypedCategory.class).value().getName());
}
}
else
{
if (annotated.isAnnotationPresent(Locale.class))
{
return getMessageLogger(getInjectionPointRawType(injectionPoint), getDeclaringRawType(injectionPoint).getName(), toLocale(annotated.getAnnotation(Locale.class).value()));
}
else
{
return getMessageLogger(getInjectionPointRawType(injectionPoint), getDeclaringRawType(injectionPoint).getName());
}