本文整理汇总了Java中com.sun.xml.internal.ws.client.HandlerConfiguration类的典型用法代码示例。如果您正苦于以下问题:Java HandlerConfiguration类的具体用法?Java HandlerConfiguration怎么用?Java HandlerConfiguration使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
HandlerConfiguration类属于com.sun.xml.internal.ws.client包,在下文中一共展示了HandlerConfiguration类的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: processResponse
import com.sun.xml.internal.ws.client.HandlerConfiguration; //导入依赖的package包/类
/**
* Do MU Header Processing on incoming message (response)
*
* @return
* if all the headers in the packet are understood, returns an action to
* call the previous pipes with response packet
* @throws SOAPFaultException
* if all the headers in the packet are not understood, throws SOAPFaultException
*/
@Override @NotNull
public NextAction processResponse(Packet response) {
if (response.getMessage() == null) {
return super.processResponse(response);
}
HandlerConfiguration handlerConfig = response.handlerConfig;
if (handlerConfig == null) {
//Use from binding instead of defaults in case response packet does not have it,
//may have been changed from the time of invocation, it ok as its only fallback case.
handlerConfig = binding.getHandlerConfig();
}
Set<QName> misUnderstoodHeaders = getMisUnderstoodHeaders(response.getMessage().getHeaders(), handlerConfig.getRoles(),binding.getKnownHeaders());
if((misUnderstoodHeaders == null) || misUnderstoodHeaders.isEmpty()) {
return super.processResponse(response);
}
throw createMUSOAPFaultException(misUnderstoodHeaders);
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:28,代码来源:ClientMUTube.java
示例2: ServerMUTube
import com.sun.xml.internal.ws.client.HandlerConfiguration; //导入依赖的package包/类
public ServerMUTube(ServerTubeAssemblerContext tubeContext, Tube next) {
super(tubeContext.getEndpoint().getBinding(), next);
this.tubeContext = tubeContext;
//On Server, HandlerConfiguration does n't change after publish, so store locally
HandlerConfiguration handlerConfig = binding.getHandlerConfig();
roles = handlerConfig.getRoles();
handlerKnownHeaders = binding.getKnownHeaders();
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:11,代码来源:ServerMUTube.java
示例3: setHandlerChain
import com.sun.xml.internal.ws.client.HandlerConfiguration; //导入依赖的package包/类
/**
* This method separates the logical and protocol handlers and
* sets the HandlerConfiguration.
* Only logical handlers are allowed with HTTPBinding.
* Setting SOAPHandlers throws WebServiceException
*/
public void setHandlerChain(List<Handler> chain) {
for (Handler handler : chain) {
if (!(handler instanceof LogicalHandler)) {
throw new WebServiceException(ClientMessages.NON_LOGICAL_HANDLER_SET(handler.getClass()));
}
}
setHandlerConfig(new HandlerConfiguration(Collections.<String>emptySet(), chain));
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:15,代码来源:HTTPBindingImpl.java
示例4: BindingImpl
import com.sun.xml.internal.ws.client.HandlerConfiguration; //导入依赖的package包/类
protected BindingImpl(BindingID bindingId, WebServiceFeature ... features) {
this.bindingId = bindingId;
handlerConfig = new HandlerConfiguration(Collections.<String>emptySet(), Collections.<Handler>emptyList());
if (handlerConfig.getHandlerKnownHeaders() != null)
knownHeaders.addAll(handlerConfig.getHandlerKnownHeaders());
this.features = new WebServiceFeatureList(features);
this.features.validate();
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:9,代码来源:BindingImpl.java
示例5: setHandlerConfig
import com.sun.xml.internal.ws.client.HandlerConfiguration; //导入依赖的package包/类
protected void setHandlerConfig(HandlerConfiguration handlerConfig) {
this.handlerConfig = handlerConfig;
knownHeaders.clear();
knownHeaders.addAll(addedHeaders);
if (handlerConfig != null && handlerConfig.getHandlerKnownHeaders() != null)
knownHeaders.addAll(handlerConfig.getHandlerKnownHeaders());
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:8,代码来源:BindingImpl.java
示例6: setRoles
import com.sun.xml.internal.ws.client.HandlerConfiguration; //导入依赖的package包/类
/**
* Adds the next and other roles in case this has
* been called by a user without them.
* Creates a new HandlerConfiguration object and sets it on the BindingImpl.
*/
public void setRoles(Set<String> roles) {
if (roles == null) {
roles = new HashSet<String>();
}
if (roles.contains(ROLE_NONE)) {
throw new WebServiceException(ClientMessages.INVALID_SOAP_ROLE_NONE());
}
addRequiredRoles(roles);
setHandlerConfig(new HandlerConfiguration(roles, getHandlerConfig()));
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:16,代码来源:SOAPBindingImpl.java
示例7: setUpProcessor
import com.sun.xml.internal.ws.client.HandlerConfiguration; //导入依赖的package包/类
void setUpProcessor() {
if (handlers == null) {
// Take a snapshot, User may change chain after invocation, Same chain
// should be used for the entire MEP
handlers = new ArrayList<Handler>();
HandlerConfiguration handlerConfig = ((BindingImpl) getBinding()).getHandlerConfig();
List<MessageHandler> msgHandlersSnapShot= handlerConfig.getMessageHandlers();
if (!msgHandlersSnapShot.isEmpty()) {
handlers.addAll(msgHandlersSnapShot);
roles = new HashSet<String>();
roles.addAll(handlerConfig.getRoles());
processor = new SOAPHandlerProcessor(true, this, getBinding(), handlers);
}
}
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:16,代码来源:ClientMessageHandlerTube.java
示例8: setUpHandlersOnce
import com.sun.xml.internal.ws.client.HandlerConfiguration; //导入依赖的package包/类
private void setUpHandlersOnce() {
handlers = new ArrayList<Handler>();
HandlerConfiguration handlerConfig = ((BindingImpl) getBinding()).getHandlerConfig();
List<MessageHandler> msgHandlersSnapShot= handlerConfig.getMessageHandlers();
if (!msgHandlersSnapShot.isEmpty()) {
handlers.addAll(msgHandlersSnapShot);
roles = new HashSet<String>();
roles.addAll(handlerConfig.getRoles());
}
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:11,代码来源:ServerMessageHandlerTube.java
示例9: setUpHandlersOnce
import com.sun.xml.internal.ws.client.HandlerConfiguration; //导入依赖的package包/类
private void setUpHandlersOnce() {
handlers = new ArrayList<Handler>();
HandlerConfiguration handlerConfig = ((BindingImpl) getBinding()).getHandlerConfig();
List<SOAPHandler> soapSnapShot= handlerConfig.getSoapHandlers();
if (!soapSnapShot.isEmpty()) {
handlers.addAll(soapSnapShot);
roles = new HashSet<String>();
roles.addAll(handlerConfig.getRoles());
}
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:11,代码来源:ServerSOAPHandlerTube.java
示例10: setUpProcessor
import com.sun.xml.internal.ws.client.HandlerConfiguration; //导入依赖的package包/类
void setUpProcessor() {
if (handlers == null) {
// Take a snapshot, User may change chain after invocation, Same chain
// should be used for the entire MEP
handlers = new ArrayList<Handler>();
HandlerConfiguration handlerConfig = ((BindingImpl) getBinding()).getHandlerConfig();
List<SOAPHandler> soapSnapShot= handlerConfig.getSoapHandlers();
if (!soapSnapShot.isEmpty()) {
handlers.addAll(soapSnapShot);
roles = new HashSet<String>();
roles.addAll(handlerConfig.getRoles());
processor = new SOAPHandlerProcessor(true, this, getBinding(), handlers);
}
}
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:16,代码来源:ClientSOAPHandlerTube.java
示例11: setUpProcessorInternal
import com.sun.xml.internal.ws.client.HandlerConfiguration; //导入依赖的package包/类
private void setUpProcessorInternal() {
HandlerConfiguration hc = ((BindingImpl) binding).getHandlerConfig();
if (hc != this.hc)
resetProcessor();
this.hc = hc;
setUpProcessor();
}
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:9,代码来源:HandlerTube.java
注:本文中的com.sun.xml.internal.ws.client.HandlerConfiguration类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论