WadlApplicationContext.class, wadlApplicationContextInjectionProxy) {});
// In order for the application to properly marshall the Application
// object we need to make sure that we provide a JAXBContext that
// will work
final WadlApplicationContext wac = wadlApplicationContextInjectionProxy;
@Provider @Produces({MediaTypes.WADL_STRING,MediaTypes.WADL_JSON_STRING, MediaType.APPLICATION_XML})
class WadlContextResolver implements ContextResolver<JAXBContext>
{
@Override
public JAXBContext getContext(Class<?> type) {
if (com.sun.research.ws.wadl.Application.class.isAssignableFrom(type)) {
return wac.getJAXBContext();
}
else {
return null;
}
}