com.sun.xml.ws.model.wsdl
Class WSDLBoundOperationImpl

java.lang.Object
  extended by com.sun.xml.ws.model.wsdl.WSDLBoundOperationImpl
All Implemented Interfaces:
WSDLBoundOperation, WSDLExtensible, WSDLObject

public final class WSDLBoundOperationImpl
extends java.lang.Object
implements WSDLBoundOperation

Implementation of WSDLBoundOperation


Nested Class Summary
protected static class AbstractExtensibleImpl.UnknownWSDLExtension
           
 
Nested classes/interfaces inherited from interface com.sun.xml.ws.api.model.wsdl.WSDLBoundOperation
WSDLBoundOperation.ANONYMOUS
 
Field Summary
protected  java.util.Set<WSDLExtension> extensions
           
protected  java.util.List<AbstractExtensibleImpl.UnknownWSDLExtension> notUnderstoodExtensions
           
 
Constructor Summary
WSDLBoundOperationImpl(javax.xml.stream.XMLStreamReader xsr, WSDLBoundPortTypeImpl owner, javax.xml.namespace.QName name)
           
 
Method Summary
 void addExtension(WSDLExtension ex)
          Adds a new WSDLExtension to this object.
 void addFault(WSDLBoundFaultImpl fault)
           
 void addNotUnderstoodExtension(javax.xml.namespace.QName extnEl, org.xml.sax.Locator locator)
          This can be used if a WSDL extension element that has wsdl:required=true is not understood
 void addPart(WSDLPartImpl part, javax.jws.WebParam.Mode mode)
           
 boolean areRequiredExtensionsUnderstood()
          This method should be called after freezing the WSDLModel
 WSDLBoundOperation.ANONYMOUS getAnonymous()
          Gets the soapbinding:binding/operation/wsaw:Anonymous.
 WSDLBoundPortType getBoundPortType()
          Gives the owner WSDLBoundPortType
<T extends WSDLExtension>
T
getExtension(java.lang.Class<T> type)
          Gets the extension that is assignable to the given type.
 java.lang.Iterable<WSDLExtension> getExtensions()
          Gets all the WSDLExtensions added through WSDLExtensible.addExtension(WSDLExtension).
<T extends WSDLExtension>
java.lang.Iterable<T>
getExtensions(java.lang.Class<T> type)
          Gets all the extensions that is assignable to the given type.
 ParameterBinding getFaultBinding(java.lang.String part)
          Gets ParameterBinding for a given wsdl part in wsdl:fault
 java.util.Map<java.lang.String,java.lang.String> getFaultMimeTypes()
          Map of mime:content@part and the mime type from mime:content@type for wsdl:fault
 java.util.Map<java.lang.String,ParameterBinding> getFaultParts()
          Map of wsdl:fault part name and the binding as ParameterBinding
 java.util.List<WSDLBoundFaultImpl> getFaults()
          Gets all the WSDLFault bound to this operation.
 java.util.Map<java.lang.String,WSDLPart> getInParts()
          Gets all inbound WSDLPart by its name.
 ParameterBinding getInputBinding(java.lang.String part)
          Gets ParameterBinding for a given wsdl part in wsdl:input
 java.util.Map<java.lang.String,java.lang.String> getInputMimeTypes()
          Map of mime:content@part and the mime type from mime:content@type for wsdl:output
 java.util.Map<java.lang.String,ParameterBinding> getInputParts()
          Map of wsdl:input part name and the binding as ParameterBinding
 org.xml.sax.Locator getLocation()
          Gets the source location information in the parsed WSDL.
 java.lang.String getMimeTypeForFaultPart(java.lang.String part)
          Gets the MIME type for a given wsdl part in wsdl:fault
 java.lang.String getMimeTypeForInputPart(java.lang.String part)
          Gets the MIME type for a given wsdl part in wsdl:input
 java.lang.String getMimeTypeForOutputPart(java.lang.String part)
          Gets the MIME type for a given wsdl part in wsdl:output
 javax.xml.namespace.QName getName()
          Short-cut for getOperation().getName()
 WSDLOperationImpl getOperation()
          Gets the wsdl:portType/wsdl:operation model - WSDLOperation, associated with this binding operation.
 java.util.Map<java.lang.String,WSDLPart> getOutParts()
          Gets all outbound WSDLPart by its name.
 ParameterBinding getOutputBinding(java.lang.String part)
          Gets ParameterBinding for a given wsdl part in wsdl:output
 java.util.Map<java.lang.String,java.lang.String> getOutputMimeTypes()
          Map of mime:content@part and the mime type from mime:content@type for wsdl:output
 java.util.Map<java.lang.String,ParameterBinding> getOutputParts()
          Map of wsdl:output part name and the binding as ParameterBinding
 WSDLPartImpl getPart(java.lang.String partName, javax.jws.WebParam.Mode mode)
          Gets WSDLPart for the given wsdl:input or wsdl:output part
 javax.xml.namespace.QName getReqPayloadName()
          Gets the payload QName of the request message.
 java.lang.String getRequestNamespace()
          For rpclit gives namespace value on soapbinding:body@namespace
 javax.xml.namespace.QName getResPayloadName()
          Gets the payload QName of the response message.
 java.lang.String getResponseNamespace()
          For rpclit gives namespace value on soapbinding:body@namespace
 java.lang.String getSOAPAction()
          Gives soapbinding:operation@soapAction value.
 void setAnonymous(WSDLBoundOperation.ANONYMOUS anonymous)
           
 void setFaultExplicitBodyParts(boolean b)
           
 void setInputExplicitBodyParts(boolean b)
           
 void setOutputExplicitBodyParts(boolean b)
           
 void setRequestNamespace(java.lang.String ns)
           
 void setResponseNamespace(java.lang.String ns)
           
 void setSoapAction(java.lang.String soapAction)
           
 void setStyle(javax.jws.soap.SOAPBinding.Style style)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.sun.xml.ws.api.model.wsdl.WSDLExtensible
addExtension, getExtension, getExtensions, getExtensions
 
Methods inherited from interface com.sun.xml.ws.api.model.wsdl.WSDLObject
getLocation
 

Field Detail

extensions

protected final java.util.Set<WSDLExtension> extensions

notUnderstoodExtensions

protected java.util.List<AbstractExtensibleImpl.UnknownWSDLExtension> notUnderstoodExtensions
Constructor Detail

WSDLBoundOperationImpl

public WSDLBoundOperationImpl(javax.xml.stream.XMLStreamReader xsr,
                              WSDLBoundPortTypeImpl owner,
                              javax.xml.namespace.QName name)
Parameters:
name - wsdl:operation name qualified value
Method Detail

getName

public javax.xml.namespace.QName getName()
Description copied from interface: WSDLBoundOperation
Short-cut for getOperation().getName()

Specified by:
getName in interface WSDLBoundOperation

getSOAPAction

public java.lang.String getSOAPAction()
Description copied from interface: WSDLBoundOperation
Gives soapbinding:operation@soapAction value. soapbinding:operation@soapAction is optional attribute. If not present an empty String is returned as per BP 1.1 R2745.

Specified by:
getSOAPAction in interface WSDLBoundOperation

setSoapAction

public void setSoapAction(java.lang.String soapAction)

getPart

public WSDLPartImpl getPart(java.lang.String partName,
                            javax.jws.WebParam.Mode mode)
Description copied from interface: WSDLBoundOperation
Gets WSDLPart for the given wsdl:input or wsdl:output part

Specified by:
getPart in interface WSDLBoundOperation
Returns:
null if no part is found

addPart

public void addPart(WSDLPartImpl part,
                    javax.jws.WebParam.Mode mode)

getInputParts

public java.util.Map<java.lang.String,ParameterBinding> getInputParts()
Map of wsdl:input part name and the binding as ParameterBinding

Returns:
empty Map if there is no parts

getOutputParts

public java.util.Map<java.lang.String,ParameterBinding> getOutputParts()
Map of wsdl:output part name and the binding as ParameterBinding

Returns:
empty Map if there is no parts

getFaultParts

public java.util.Map<java.lang.String,ParameterBinding> getFaultParts()
Map of wsdl:fault part name and the binding as ParameterBinding

Returns:
empty Map if there is no parts

getInParts

public java.util.Map<java.lang.String,WSDLPart> getInParts()
Description copied from interface: WSDLBoundOperation
Gets all inbound WSDLPart by its name.

Specified by:
getInParts in interface WSDLBoundOperation

getOutParts

public java.util.Map<java.lang.String,WSDLPart> getOutParts()
Description copied from interface: WSDLBoundOperation
Gets all outbound WSDLPart by its name.

Specified by:
getOutParts in interface WSDLBoundOperation

getFaults

@NotNull
public java.util.List<WSDLBoundFaultImpl> getFaults()
Description copied from interface: WSDLBoundOperation
Gets all the WSDLFault bound to this operation.

Specified by:
getFaults in interface WSDLBoundOperation

addFault

public void addFault(@NotNull
                     WSDLBoundFaultImpl fault)

getInputMimeTypes

public java.util.Map<java.lang.String,java.lang.String> getInputMimeTypes()
Map of mime:content@part and the mime type from mime:content@type for wsdl:output

Returns:
empty Map if there is no parts

getOutputMimeTypes

public java.util.Map<java.lang.String,java.lang.String> getOutputMimeTypes()
Map of mime:content@part and the mime type from mime:content@type for wsdl:output

Returns:
empty Map if there is no parts

getFaultMimeTypes

public java.util.Map<java.lang.String,java.lang.String> getFaultMimeTypes()
Map of mime:content@part and the mime type from mime:content@type for wsdl:fault

Returns:
empty Map if there is no parts

getInputBinding

public ParameterBinding getInputBinding(java.lang.String part)
Gets ParameterBinding for a given wsdl part in wsdl:input

Parameters:
part - Name of wsdl:part, must be non-null
Returns:
null if the part is not found.

getOutputBinding

public ParameterBinding getOutputBinding(java.lang.String part)
Gets ParameterBinding for a given wsdl part in wsdl:output

Parameters:
part - Name of wsdl:part, must be non-null
Returns:
null if the part is not found.

getFaultBinding

public ParameterBinding getFaultBinding(java.lang.String part)
Gets ParameterBinding for a given wsdl part in wsdl:fault

Parameters:
part - Name of wsdl:part, must be non-null
Returns:
null if the part is not found.

getMimeTypeForInputPart

public java.lang.String getMimeTypeForInputPart(java.lang.String part)
Gets the MIME type for a given wsdl part in wsdl:input

Parameters:
part - Name of wsdl:part, must be non-null
Returns:
null if the part is not found.

getMimeTypeForOutputPart

public java.lang.String getMimeTypeForOutputPart(java.lang.String part)
Gets the MIME type for a given wsdl part in wsdl:output

Parameters:
part - Name of wsdl:part, must be non-null
Returns:
null if the part is not found.

getMimeTypeForFaultPart

public java.lang.String getMimeTypeForFaultPart(java.lang.String part)
Gets the MIME type for a given wsdl part in wsdl:fault

Parameters:
part - Name of wsdl:part, must be non-null
Returns:
null if the part is not found.

getOperation

public WSDLOperationImpl getOperation()
Description copied from interface: WSDLBoundOperation
Gets the wsdl:portType/wsdl:operation model - WSDLOperation, associated with this binding operation.

Specified by:
getOperation in interface WSDLBoundOperation
Returns:
always same WSDLOperation

getBoundPortType

public WSDLBoundPortType getBoundPortType()
Description copied from interface: WSDLBoundOperation
Gives the owner WSDLBoundPortType

Specified by:
getBoundPortType in interface WSDLBoundOperation

setInputExplicitBodyParts

public void setInputExplicitBodyParts(boolean b)

setOutputExplicitBodyParts

public void setOutputExplicitBodyParts(boolean b)

setFaultExplicitBodyParts

public void setFaultExplicitBodyParts(boolean b)

setStyle

public void setStyle(javax.jws.soap.SOAPBinding.Style style)

getReqPayloadName

@Nullable
public javax.xml.namespace.QName getReqPayloadName()
Description copied from interface: WSDLBoundOperation
Gets the payload QName of the request message.

It's possible for an operation to define no body part, in which case this method returns null.

Specified by:
getReqPayloadName in interface WSDLBoundOperation

getResPayloadName

@Nullable
public javax.xml.namespace.QName getResPayloadName()
Description copied from interface: WSDLBoundOperation
Gets the payload QName of the response message.

It's possible for an operation to define no body part, in which case this method returns null.

Specified by:
getResPayloadName in interface WSDLBoundOperation

getRequestNamespace

public java.lang.String getRequestNamespace()
For rpclit gives namespace value on soapbinding:body@namespace

Specified by:
getRequestNamespace in interface WSDLBoundOperation
Returns:
non-null for rpclit and null for doclit
See Also:
RuntimeModeler.processRpcMethod(JavaMethodImpl, String, String, Method)

setRequestNamespace

public void setRequestNamespace(java.lang.String ns)

getResponseNamespace

public java.lang.String getResponseNamespace()
For rpclit gives namespace value on soapbinding:body@namespace

Specified by:
getResponseNamespace in interface WSDLBoundOperation
Returns:
non-null for rpclit and null for doclit
See Also:
RuntimeModeler.processRpcMethod(JavaMethodImpl, String, String, Method)

setResponseNamespace

public void setResponseNamespace(java.lang.String ns)

setAnonymous

public void setAnonymous(WSDLBoundOperation.ANONYMOUS anonymous)

getAnonymous

public WSDLBoundOperation.ANONYMOUS getAnonymous()
Description copied from interface: WSDLBoundOperation
Gets the soapbinding:binding/operation/wsaw:Anonymous. A default value of OPTIONAL is returned.

Specified by:
getAnonymous in interface WSDLBoundOperation
Returns:
Anonymous value of the operation

getExtensions

public final java.lang.Iterable<WSDLExtension> getExtensions()
Description copied from interface: WSDLExtensible
Gets all the WSDLExtensions added through WSDLExtensible.addExtension(WSDLExtension).

Specified by:
getExtensions in interface WSDLExtensible
Returns:
never null.

getExtensions

public final <T extends WSDLExtension> java.lang.Iterable<T> getExtensions(java.lang.Class<T> type)
Description copied from interface: WSDLExtensible
Gets all the extensions that is assignable to the given type.

This allows clients to find specific extensions in a type-safe and convenient way.

Specified by:
getExtensions in interface WSDLExtensible
Parameters:
type - The type of the extension to obtain. Must not be null.
Returns:
Can be an empty fromjava.collection but never null.

getExtension

public <T extends WSDLExtension> T getExtension(java.lang.Class<T> type)
Description copied from interface: WSDLExtensible
Gets the extension that is assignable to the given type.

This is just a convenient version that does

 Iterator itr = getExtensions(type);
 if(itr.hasNext())  return itr.next();
 else               return null;
 

Specified by:
getExtension in interface WSDLExtensible
Returns:
null if the extension was not found.

addExtension

public void addExtension(WSDLExtension ex)
Description copied from interface: WSDLExtensible
Adds a new WSDLExtension to this object.

Specified by:
addExtension in interface WSDLExtensible
Parameters:
ex - must not be null.

addNotUnderstoodExtension

public void addNotUnderstoodExtension(javax.xml.namespace.QName extnEl,
                                      org.xml.sax.Locator locator)
This can be used if a WSDL extension element that has wsdl:required=true is not understood

Parameters:
extnEl -
locator -

areRequiredExtensionsUnderstood

public boolean areRequiredExtensionsUnderstood()
This method should be called after freezing the WSDLModel

Returns:
true if all wsdl required extensions on Port and Binding are understood

getLocation

@NotNull
public final org.xml.sax.Locator getLocation()
Description copied from interface: WSDLObject
Gets the source location information in the parsed WSDL. This is useful when producing error messages.

Specified by:
getLocation in interface WSDLObject


Copyright (c) 1997-2012 Oracle and/or its affiliates. All rights reserved.