本文整理汇总了Java中org.apache.cxf.interceptor.InterceptorProvider类的典型用法代码示例。如果您正苦于以下问题:Java InterceptorProvider类的具体用法?Java InterceptorProvider怎么用?Java InterceptorProvider使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
InterceptorProvider类属于org.apache.cxf.interceptor包,在下文中一共展示了InterceptorProvider类的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: initializeProvider
import org.apache.cxf.interceptor.InterceptorProvider; //导入依赖的package包/类
@Override
protected void initializeProvider(InterceptorProvider provider, Bus bus) {
final TraceeRequestInInterceptor requestInInterceptor = new TraceeRequestInInterceptor(backend, profile);
final TraceeResponseInInterceptor responseInInterceptor = new TraceeResponseInInterceptor(backend, profile);
final TraceeRequestOutInterceptor requestOutInterceptor = new TraceeRequestOutInterceptor(backend, profile);
final TraceeResponseOutInterceptor responseOutInterceptor = new TraceeResponseOutInterceptor(backend, profile);
provider.getInInterceptors().add(requestInInterceptor);
provider.getInInterceptors().add(responseInInterceptor);
provider.getOutInterceptors().add(requestOutInterceptor);
provider.getOutInterceptors().add(responseOutInterceptor);
provider.getOutFaultInterceptors().add(responseOutInterceptor);
provider.getInFaultInterceptors().add(requestInInterceptor);
}
示例2: setupWSS4JChain
import org.apache.cxf.interceptor.InterceptorProvider; //导入依赖的package包/类
public static final void setupWSS4JChain(InterceptorProvider endpoint, Map<String, Object> inProps, Map<String, Object> outProps) {
if (null != inProps && !inProps.isEmpty()) {
endpoint.getInInterceptors().add(new SAAJInInterceptor());
endpoint.getInInterceptors().add(new WSS4JInInterceptor(inProps));
// if WS Security is used with a JAX-WS handler (See EjbInterceptor), we have to deal with mustUnderstand flag
// in WS Security headers. So, let's add an interceptor
endpoint.getInInterceptors().add(new WSSPassThroughInterceptor());
}
if (null != outProps && !outProps.isEmpty()) {
endpoint.getOutInterceptors().add(new SAAJOutInterceptor());
endpoint.getOutInterceptors().add(new WSS4JOutInterceptor(outProps));
}
}
示例3: configureInterceptors
import org.apache.cxf.interceptor.InterceptorProvider; //导入依赖的package包/类
public static void configureInterceptors(final InterceptorProvider abip, final String prefix, final Collection<ServiceInfo> availableServices, final Properties beanConfig) {
// interceptors
final String inInterceptorsIds = beanConfig.getProperty(prefix + IN_INTERCEPTORS);
if (inInterceptorsIds != null && !inInterceptorsIds.trim().isEmpty()) {
abip.getInInterceptors().addAll(createInterceptors(availableServices, inInterceptorsIds));
}
final String inFaultInterceptorsIds = beanConfig.getProperty(prefix + IN_FAULT_INTERCEPTORS);
if (inFaultInterceptorsIds != null && !inFaultInterceptorsIds.trim().isEmpty()) {
abip.getInFaultInterceptors().addAll(createInterceptors(availableServices, inFaultInterceptorsIds));
}
final String outInterceptorsIds = beanConfig.getProperty(prefix + OUT_INTERCEPTORS);
if (outInterceptorsIds != null && !outInterceptorsIds.trim().isEmpty()) {
abip.getOutInterceptors().addAll(createInterceptors(availableServices, outInterceptorsIds));
}
final String outFaultInterceptorsIds = beanConfig.getProperty(prefix + OUT_FAULT_INTERCEPTORS);
if (outFaultInterceptorsIds != null && !outFaultInterceptorsIds.trim().isEmpty()) {
abip.getOutFaultInterceptors().addAll(createInterceptors(availableServices, outFaultInterceptorsIds));
}
}
示例4: initializeProvider
import org.apache.cxf.interceptor.InterceptorProvider; //导入依赖的package包/类
@Override
protected void initializeProvider(InterceptorProvider provider, Bus bus) {
provider.getInInterceptors().add(IN);
provider.getInFaultInterceptors().add(IN);
provider.getOutInterceptors().add(OUT);
provider.getOutFaultInterceptors().add(OUT);
}
示例5: addInterceptors
import org.apache.cxf.interceptor.InterceptorProvider; //导入依赖的package包/类
public static void addInterceptors(InterceptorProvider interceptorProvider, Map<String, String> properties) {
MapToBeanConverter converter = null;
final String inInterceptors = properties.get(Constants.CXF_IN_INTERCEPTORS_PROP);
if (inInterceptors != null) {
if (converter == null) {
converter = new MapToBeanConverter(properties);
}
interceptorProvider.getInInterceptors().addAll(createInterceptors(inInterceptors, converter));
}
final String outInterceptors = properties.get(Constants.CXF_OUT_INTERCEPTORS_PROP);
if (outInterceptors != null) {
if (converter == null) {
converter = new MapToBeanConverter(properties);
}
interceptorProvider.getOutInterceptors().addAll(createInterceptors(outInterceptors, converter));
}
final String inFaultInterceptors = properties.get(Constants.CXF_IN_FAULT_INTERCEPTORS_PROP);
if (inFaultInterceptors != null) {
if (converter == null) {
converter = new MapToBeanConverter(properties);
}
interceptorProvider.getInFaultInterceptors().addAll(createInterceptors(inFaultInterceptors, converter));
}
final String outFaultInterceptors = properties.get(Constants.CXF_OUT_FAULT_INTERCEPTORS_PROP);
if (outFaultInterceptors != null) {
if (converter == null) {
converter = new MapToBeanConverter(properties);
}
interceptorProvider.getOutFaultInterceptors().addAll(createInterceptors(outFaultInterceptors, converter));
}
}
示例6: addFeatures
import org.apache.cxf.interceptor.InterceptorProvider; //导入依赖的package包/类
public static void addFeatures(InterceptorProvider interceptorProvider, Bus bus, Map<String, String> properties) {
final String features = properties.get(Constants.CXF_FEATURES_PROP);
if (features != null) {
MapToBeanConverter converter = new MapToBeanConverter(properties);
for (Feature f : createFeatures(features, converter)) {
f.initialize(interceptorProvider, bus);
}
}
}
示例7: initialize
import org.apache.cxf.interceptor.InterceptorProvider; //导入依赖的package包/类
private static void initialize(InterceptorProvider interceptorProv, AbstractLoggingHookInInterceptor<?> hookInInterceptor,
AbstractLoggingProcessInInterceptor<?> processInInterceptor, AbstractLoggingOutInterceptor<?, ?> outInterceptor) {
List<Interceptor<? extends Message>> inInterceptors = interceptorProv.getInInterceptors();
inInterceptors.add(hookInInterceptor);
inInterceptors.add(processInInterceptor);
interceptorProv.getInFaultInterceptors().add(processInInterceptor);
interceptorProv.getOutInterceptors().add(outInterceptor);
interceptorProv.getOutFaultInterceptors().add(outInterceptor);
}
示例8: initializeProvider
import org.apache.cxf.interceptor.InterceptorProvider; //导入依赖的package包/类
@Override
protected void initializeProvider(InterceptorProvider provider, Bus bus) {
if (log.isDebugEnabled()) {
log.debug("Applying logging to all incoming and outgoing CXF SOAP Messages");
}
bus.getInInterceptors().add(loggingInInterceptor);
bus.getInFaultInterceptors().add(loggingInInterceptor);
bus.getOutInterceptors().add(loggingOutInterceptor);
bus.getOutFaultInterceptors().add(loggingOutInterceptor);
}
示例9: initializeProvider
import org.apache.cxf.interceptor.InterceptorProvider; //导入依赖的package包/类
@Override
protected void initializeProvider(InterceptorProvider provider, Bus bus) {
provider.getInInterceptors().add(interceptor);
}
示例10: initialize
import org.apache.cxf.interceptor.InterceptorProvider; //导入依赖的package包/类
@Override
public void initialize(InterceptorProvider interceptorProvider, Bus bus) {
initialized = true;
}
示例11: initializeProvider
import org.apache.cxf.interceptor.InterceptorProvider; //导入依赖的package包/类
@Override
protected void initializeProvider(InterceptorProvider provider, Bus bus) {
if (provider instanceof Client) {
provider = ((Client)provider).getEndpoint();
}
provider.getOutInterceptors().add(new EndpointCheckInterceptor());
}