本文整理汇总了Java中com.sun.xml.internal.ws.api.model.SEIModel.getJavaMethod方法的典型用法代码示例。如果您正苦于以下问题:Java SEIModel.getJavaMethod方法的具体用法?Java SEIModel.getJavaMethod怎么用?Java SEIModel.getJavaMethod使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.sun.xml.internal.ws.api.model.SEIModel
的用法示例。
在下文中一共展示了SEIModel.getJavaMethod方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getMethod
import com.sun.xml.internal.ws.api.model.SEIModel; //导入方法依赖的package包/类
/**
* Returns the java Method of which this message is an instance of.
*
* It is not always possible to uniquely identify the WSDL Operation from just the
* information in the Message. Instead, Use {@link com.sun.xml.internal.ws.api.message.Packet#getWSDLOperation()}
* to get the QName of the associated wsdl operation correctly.
*
* <p>
* This method works only for a request. A pipe can determine a {@link Method}
* for a request, and then keep it in a local variable to use it with a response,
* so there should be no need to find out operation from a response (besides,
* there might not be any response!).
*
* @param seiModel
* This represents the java model for the endpoint
* Some server {@link Pipe}s would get this information when they are created.
*
* @return
* Null if there is no corresponding Method for this message. This is
* possible, for example when a protocol message is sent through a
* pipeline, or when we receive an invalid request on the server,
* or when we are on the client and the user appliation sends a random
* DOM through {@link Dispatch}, so this error needs to be handled
* gracefully.
*/
@Deprecated
public final @Nullable JavaMethod getMethod(@NotNull SEIModel seiModel) {
if (wsdlOperationMapping == null && messageMetadata != null) {
wsdlOperationMapping = messageMetadata.getWSDLOperationMapping();
}
if (wsdlOperationMapping != null) {
return wsdlOperationMapping.getJavaMethod();
}
//fall back to the original logic which could be incorrect ...
String localPart = getPayloadLocalPart();
String nsUri;
if (localPart == null) {
localPart = "";
nsUri = "";
} else {
nsUri = getPayloadNamespaceURI();
}
QName name = new QName(nsUri, localPart);
return seiModel.getJavaMethod(name);
}