gpt4 book ai didi

org.codehaus.enunciate.contract.jaxws.WebFault.getExplicitFaultBeanType()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-24 15:49:05 27 4
gpt4 key购买 nike

本文整理了Java中org.codehaus.enunciate.contract.jaxws.WebFault.getExplicitFaultBeanType()方法的一些代码示例,展示了WebFault.getExplicitFaultBeanType()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。WebFault.getExplicitFaultBeanType()方法的具体详情如下:
包路径:org.codehaus.enunciate.contract.jaxws.WebFault
类名称:WebFault
方法名:getExplicitFaultBeanType

WebFault.getExplicitFaultBeanType介绍

[英]A web fault has an explicit fault bean if all three of the following are present:

  1. A getFaultInfo method that returns the bean instance of a class type.
  2. A constructor taking a message and bean instance.
  3. A constructor taking a message, a bean instance, and a cause.
    [中]如果存在以下三种情况,则web故障具有显式故障bean:
    1.返回类类型的bean实例的getFaultInfo方法。
    1.获取消息和bean实例的构造函数。
    1.获取消息、bean实例和原因的构造函数。

代码示例

代码示例来源:origin: org.codehaus.enunciate/enunciate-core

/**
 * Adds any type definitions referenced by a web fault.
 *
 * @param webFault The web fault.
 */
protected void addReferencedTypeDefinitions(WebFault webFault) {
 if (webFault.isImplicitSchemaElement()) {
  for (ImplicitChildElement childElement : webFault.getChildElements()) {
   WebFault.FaultBeanChildElement fbce = (WebFault.FaultBeanChildElement) childElement;
   REFERENCE_STACK.get().addFirst("property " + fbce.getProperty().getSimpleName());
   addReferencedTypeDefinitions(fbce.isAdapted() ? fbce.getAdapterType() : fbce.getType());
   REFERENCE_STACK.get().removeFirst();
  }
 }
 else {
  REFERENCE_STACK.get().addFirst("explicit fault bean");
  ClassType faultBeanType = webFault.getExplicitFaultBeanType();
  if (faultBeanType != null) {
   addReferencedTypeDefinitions(faultBeanType);
  }
  REFERENCE_STACK.get().removeFirst();
 }
}

代码示例来源:origin: org.codehaus.enunciate/enunciate-xfire-client

String faultClass = classnameFor.convert(webFault);
boolean implicit = webFault.isImplicitSchemaElement();
String faultBean = implicit ? getBeanName(classnameFor, webFault.getImplicitFaultBeanQualifiedName()) : classnameFor.convert(webFault.getExplicitFaultBeanType());

代码示例来源:origin: org.codehaus.enunciate/enunciate-java-client

String faultBean = implicit ? getBeanName(classnameFor, webFault.getImplicitFaultBeanQualifiedName()) : classnameFor.convert(webFault.getExplicitFaultBeanType());
seeAlsos.add(faultBean);

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com