Permalink
Browse files

more

  • Loading branch information...
1 parent f66c247 commit fa1c4f2ea28267ac9d9e41e11132de6d6821c21a @patriot1burke patriot1burke committed Apr 30, 2012
@@ -66,6 +66,18 @@ public Interceptors getClientInterceptors()
}
@Override
+ public void addExceptionMapper(ExceptionMapper provider, Class providerClass)
+ {
+ getDelegate().addExceptionMapper(provider, providerClass);
+ }
+
+ @Override
+ public void addStringConverter(StringConverter provider, Class providerClass)
+ {
+ getDelegate().addStringConverter(provider, providerClass);
+ }
+
+ @Override
public void addExceptionMapper(ExceptionMapper provider, Type exceptionType)
{
getDelegate().addExceptionMapper(provider, exceptionType);
@@ -610,15 +610,21 @@ public void addMessageBodyWriter(MessageBodyWriter provider, Class providerClass
public void addExceptionMapper(Class<? extends ExceptionMapper> providerClass)
{
ExceptionMapper provider = getProviderInstance(providerClass);
- addExceptionMapper(provider);
+ addExceptionMapper(provider, providerClass);
}
public void addExceptionMapper(ExceptionMapper provider)
{
- Type exceptionType = Types.getActualTypeArgumentsOfAnInterface(provider.getClass(), ExceptionMapper.class)[0];
+ addExceptionMapper(provider, provider.getClass());
+ }
+
+ public void addExceptionMapper(ExceptionMapper provider, Class providerClass)
+ {
+ Type exceptionType = Types.getActualTypeArgumentsOfAnInterface(providerClass, ExceptionMapper.class)[0];
addExceptionMapper(provider, exceptionType);
}
+
public void addExceptionMapper(ExceptionMapper provider, Type exceptionType)
{
providers.put(provider.getClass(), provider);
@@ -723,12 +729,17 @@ public void injectProperties(Object o)
public void addStringConverter(Class<? extends StringConverter> resolver)
{
StringConverter writer = getProviderInstance(resolver);
- addStringConverter(writer);
+ addStringConverter(writer, resolver);
}
public void addStringConverter(StringConverter provider)
{
- Type parameter = Types.getActualTypeArgumentsOfAnInterface(provider.getClass(), StringConverter.class)[0];
+ addStringConverter(provider, provider.getClass());
+ }
+
+ public void addStringConverter(StringConverter provider, Class providerClass)
+ {
+ Type parameter = Types.getActualTypeArgumentsOfAnInterface(providerClass, StringConverter.class)[0];
addStringConverter(provider, parameter);
}

0 comments on commit fa1c4f2

Please sign in to comment.