com.sun.xml.ws.server
Class ServiceDefinitionImpl

java.lang.Object
  extended by com.sun.xml.ws.server.ServiceDefinitionImpl
All Implemented Interfaces:
ServiceDefinition, Iterable<SDDocument>

public final class ServiceDefinitionImpl
extends Object
implements ServiceDefinition

ServiceDefinition implementation.

You construct a ServiceDefinitionImpl by first constructing a list of SDDocumentImpls.


Field Summary
(package private)  List<SDDocumentFilter> filters
           
(package private)  WSEndpointImpl<?> owner
          Set when WSEndpointImpl is created.
 
Constructor Summary
ServiceDefinitionImpl(List<SDDocumentImpl> docs, SDDocumentImpl primaryWsdl)
           
 
Method Summary
 void addFilter(SDDocumentFilter filter)
          Adds a filter that is called while writing SDDocument's infoset.
 SDDocumentImpl getBySystemId(String systemId)
          Gets the SDDocumentImpl whose SDDocumentImpl.getURL() returns the specified value.
 SDDocument getBySystemId(URL systemId)
           
 SDDocument getPrimary()
          Gets the "primary" SDDocument that represents a WSDL.
 Iterator<SDDocument> iterator()
           
(package private)  void setOwner(WSEndpointImpl<?> owner)
          The owner is set when WSEndpointImpl is created.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

owner

WSEndpointImpl<?> owner
Set when WSEndpointImpl is created.


filters

final List<SDDocumentFilter> filters
Constructor Detail

ServiceDefinitionImpl

public ServiceDefinitionImpl(List<SDDocumentImpl> docs,
                             @NotNull
                             SDDocumentImpl primaryWsdl)
Parameters:
docs - List of SDDocumentImpls to form the description. There must be at least one entry. The first document is considered primary.
Method Detail

setOwner

void setOwner(WSEndpointImpl<?> owner)
The owner is set when WSEndpointImpl is created.


getPrimary

@NotNull
public SDDocument getPrimary()
Description copied from interface: ServiceDefinition
Gets the "primary" SDDocument that represents a WSDL.

This WSDL eventually refers to all the other SDDocuments.

Specified by:
getPrimary in interface ServiceDefinition
Returns:
always non-null.

addFilter

public void addFilter(SDDocumentFilter filter)
Description copied from interface: ServiceDefinition
Adds a filter that is called while writing SDDocument's infoset. This filter is applied to the all the other reachable SDDocuments.

Specified by:
addFilter in interface ServiceDefinition
Parameters:
filter - that is called while writing the document

iterator

public Iterator<SDDocument> iterator()
Specified by:
iterator in interface Iterable<SDDocument>

getBySystemId

public SDDocument getBySystemId(URL systemId)
See Also:
getBySystemId(String)

getBySystemId

public SDDocumentImpl getBySystemId(String systemId)
Gets the SDDocumentImpl whose SDDocumentImpl.getURL() returns the specified value.

Returns:
null if none is found.