com.sun.xml.ws.server
Class ServiceDefinitionImpl

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

public final class ServiceDefinitionImpl
extends Object
implements ServiceDefinition, SDDocumentResolver

ServiceDefinition implementation.

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

Author:
Kohsuke Kawaguchi

Constructor Summary
ServiceDefinitionImpl(Collection<SDDocumentImpl> docs, SDDocumentImpl primaryWsdl)
           
 
Method Summary
 void addFilter(SDDocumentFilter filter)
          Adds a filter that is called while writing SDDocument's infoset.
 SDDocument getPrimary()
          Gets the "primary" SDDocument that represents a WSDL.
 Iterator<SDDocument> iterator()
           
 SDDocument resolve(String systemId)
          Gets the SDDocumentImpl whose SDDocumentImpl.getURL() returns the specified value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ServiceDefinitionImpl

public ServiceDefinitionImpl(Collection<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

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>

resolve

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

Specified by:
resolve in interface SDDocumentResolver
Parameters:
systemId - document's systemId
Returns:
null if none is found.


Copyright © 2005-2015 Oracle Corporation. All Rights Reserved.