com.genexus.ws.RestReaderInterceptor Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of gxwrapperjavax Show documentation
Show all versions of gxwrapperjavax Show documentation
Core classes for the runtime used by Java and Android apps generated with GeneXus
The newest version!
package com.genexus.ws;
import java.io.IOException;
import java.io.InputStream;
import javax.ws.rs.WebApplicationException;
import javax.ws.rs.ext.Provider;
import javax.ws.rs.ext.ReaderInterceptor;
import javax.ws.rs.ext.ReaderInterceptorContext;
@Provider
public class RestReaderInterceptor implements ReaderInterceptor {
@Override
public Object aroundReadFrom(ReaderInterceptorContext context) throws IOException, WebApplicationException {
try (InputStream is = context.getInputStream()){
InputStream isBody = com.genexus.WrapperUtils.storeRestRequestBody(is);
context.setInputStream(isBody);
return context.proceed();
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy