org.apache.ws.scout.registry
Class RegistryImpl

java.lang.Object
  extended by org.apache.ws.scout.registry.RegistryImpl
All Implemented Interfaces:
IRegistry, IRegistryBase

public class RegistryImpl
extends java.lang.Object
implements IRegistry

RegistryImpl is the implementation of IRegistry.

The execute() function signature has been changed slightly from the jUDDI version, since the URL can no longer be decided dynamically (in an easy enough manner) as we don't use jUDDI data types anymore.

The function code is borrowed from jUDDI, with appropriate modifications so that xmlbeans data types are used intead of jUDDI data types.


Field Summary
static java.lang.String DEFAULT_ADMIN_ENDPOINT
           
static java.lang.String DEFAULT_PROTOCOL_HANDLER
           
static java.lang.String DEFAULT_SECURITY_PROVIDER
           
static java.lang.String DEFAULT_TRANSPORT_CLASS
           
static java.lang.String DEFAULT_UDDI_NAMESPACE
           
static java.lang.String DEFAULT_UDDI_VERSION
           
 
Constructor Summary
RegistryImpl(java.util.Properties props)
          Creates a new instance of RegistryImpl.
 
Method Summary
 DispositionReport deleteBinding(java.lang.String authInfo, java.lang.String[] bindingKeyArray)
          "Used to remove an existing bindingTemplate from the bindingTemplates collection that is part of a specified businessService structure."
 DispositionReport deleteBusiness(java.lang.String authInfo, java.lang.String[] businessKeyArray)
          "Used to delete registered businessEntity information from the registry."
 DispositionReport deletePublisherAssertions(java.lang.String authInfo, PublisherAssertion[] assertionArray)
           
 DispositionReport deleteService(java.lang.String authInfo, java.lang.String[] serviceKeyArray)
          "Used to delete an existing businessService from the businessServices collection that is part of a specified businessEntity."
 DispositionReport deleteTModel(java.lang.String authInfo, java.lang.String[] tModelKeyArray)
          "Used to delete registered information about a tModel.
 javax.xml.bind.JAXBElement<?> execute(javax.xml.bind.JAXBElement<?> uddiRequest, java.net.URI endPointURI)
           
 java.lang.String execute(java.lang.String uddiRequest, java.lang.String urltype)
           
 BindingDetail findBinding(java.lang.String serviceKey, CategoryBag categoryBag, TModelBag tModelBag, FindQualifiers findQualifiers, int maxRows)
          "Used to locate specific bindings within a registered businessService.
 BusinessList findBusiness(Name[] nameArray, DiscoveryURLs discoveryURLs, IdentifierBag identifierBag, CategoryBag categoryBag, TModelBag tModelBag, FindQualifiers findQualifiers, int maxRows)
          Used to locate information about one or more businesses.
 ServiceList findService(java.lang.String businessKey, Name[] nameArray, CategoryBag categoryBag, TModelBag tModelBag, FindQualifiers findQualifiers, int maxRows)
          "Used to locate specific services within a registered businessEntity.
 TModelList findTModel(java.lang.String name, CategoryBag categoryBag, IdentifierBag identifierBag, FindQualifiers findQualifiers, int maxRows)
          "Used to locate one or more tModel information structures.
 java.net.URI getAdminURI()
           
 AssertionStatusReport getAssertionStatusReport(java.lang.String authInfo, java.lang.String completionStatus)
           
 AuthToken getAuthToken(java.lang.String userID, java.lang.String cred)
          "Used to request an authentication token from an Operator Site.
 BusinessDetail getBusinessDetail(java.lang.String businessKey)
          Used to get the full businessEntity information for a particular business entity.
 BusinessDetail getBusinessDetail(java.lang.String[] businessKeyArray)
          "Used to get the full businessEntity information for one or more businesses.
static java.lang.Class getClassForName(java.lang.String name)
           
 java.net.URI getInquiryURI()
           
 java.lang.String getProtocolHandler()
           
 PublisherAssertions getPublisherAssertions(java.lang.String authInfo)
           
 java.net.URI getPublishURI()
           
 RegisteredInfo getRegisteredInfo(java.lang.String authInfo)
           
 java.lang.String getSecurityProvider()
           
 java.net.URI getSecurityURI()
           
 ServiceDetail getServiceDetail(java.lang.String serviceKey)
          "Used to get full details for a particular registered businessService.
 ServiceDetail getServiceDetail(java.lang.String[] serviceKeyArray)
          "Used to get full details for a given set of registered businessService data.
 TModelDetail getTModelDetail(java.lang.String tModelKey)
          "Used to get full details for a particular registered TModel.
 TModelDetail getTModelDetail(java.lang.String[] tModelKeyArray)
          "Used to get full details for a given set of registered tModel data.
 Transport getTransport()
           
 Transport getTransport(java.lang.String className)
          Returns an implementation of Transport based on the className passed in.
 java.lang.String getUddiNamespace()
           
 java.lang.String getUddiVersion()
           
 BindingDetail saveBinding(java.lang.String authInfo, BindingTemplate[] bindingArray)
          "Used to register new bindingTemplate information or update existing bindingTemplate information.
 BusinessDetail saveBusiness(java.lang.String authInfo, BusinessEntity[] businessArray)
          "Used to register new businessEntity information or update existing businessEntity information.
 ServiceDetail saveService(java.lang.String authInfo, BusinessService[] serviceArray)
          "Used to register or update complete information about a businessService exposed by a specified businessEntity."
 TModelDetail saveTModel(java.lang.String authInfo, TModel[] tModelArray)
          "Used to register or update complete information about a tModel."
 void setAdminURI(java.net.URI url)
           
 void setInquiryURI(java.net.URI inquiryURI)
           
 void setProtocolHandler(java.lang.String protocolHandler)
           
 PublisherAssertions setPublisherAssertions(java.lang.String authInfo, PublisherAssertion[] assertionArray)
           
 void setPublishURI(java.net.URI publishURI)
           
 void setSecurityProvider(java.lang.String securityProvider)
           
 void setSecurityURI(java.net.URI securityURI)
           
 void setTransport(Transport transport)
           
 void setUddiNamespace(java.lang.String uddiNS)
           
 void setUddiVersion(java.lang.String uddiVersion)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_ADMIN_ENDPOINT

public static final java.lang.String DEFAULT_ADMIN_ENDPOINT
See Also:
Constant Field Values

DEFAULT_TRANSPORT_CLASS

public static final java.lang.String DEFAULT_TRANSPORT_CLASS
See Also:
Constant Field Values

DEFAULT_SECURITY_PROVIDER

public static final java.lang.String DEFAULT_SECURITY_PROVIDER
See Also:
Constant Field Values

DEFAULT_PROTOCOL_HANDLER

public static final java.lang.String DEFAULT_PROTOCOL_HANDLER
See Also:
Constant Field Values

DEFAULT_UDDI_VERSION

public static final java.lang.String DEFAULT_UDDI_VERSION
See Also:
Constant Field Values

DEFAULT_UDDI_NAMESPACE

public static final java.lang.String DEFAULT_UDDI_NAMESPACE
See Also:
Constant Field Values
Constructor Detail

RegistryImpl

public RegistryImpl(java.util.Properties props)
             throws javax.xml.registry.InvalidRequestException
Creates a new instance of RegistryImpl.

Throws:
javax.xml.registry.InvalidRequestException
Method Detail

execute

public java.lang.String execute(java.lang.String uddiRequest,
                                java.lang.String urltype)
                         throws TransportException
Specified by:
execute in interface IRegistryBase
Parameters:
uddiRequest -
Returns:
String
Throws:
RegistryException
TransportException

execute

public javax.xml.bind.JAXBElement<?> execute(javax.xml.bind.JAXBElement<?> uddiRequest,
                                             java.net.URI endPointURI)
                                      throws RegistryException
Throws:
RegistryException

getAdminURI

public java.net.URI getAdminURI()
Returns:
Returns the adminURL.

setAdminURI

public void setAdminURI(java.net.URI url)
Parameters:
url - The adminURL to set.

getInquiryURI

public java.net.URI getInquiryURI()
Specified by:
getInquiryURI in interface IRegistry
Specified by:
getInquiryURI in interface IRegistryBase
Returns:
Returns the inquiryURL.

setInquiryURI

public void setInquiryURI(java.net.URI inquiryURI)
Specified by:
setInquiryURI in interface IRegistry
Specified by:
setInquiryURI in interface IRegistryBase
Parameters:
inquiryURI - The inquiryURI to set.

getProtocolHandler

public java.lang.String getProtocolHandler()
Returns:
Returns the protocolHandler.

setProtocolHandler

public void setProtocolHandler(java.lang.String protocolHandler)
Parameters:
protocolHandler - The protocolHandler to set.

getPublishURI

public java.net.URI getPublishURI()
Specified by:
getPublishURI in interface IRegistry
Specified by:
getPublishURI in interface IRegistryBase
Returns:
Returns the publishURL.

getSecurityURI

public java.net.URI getSecurityURI()
Specified by:
getSecurityURI in interface IRegistryBase
Returns:
Returns the publishURL.

setPublishURI

public void setPublishURI(java.net.URI publishURI)
Specified by:
setPublishURI in interface IRegistry
Specified by:
setPublishURI in interface IRegistryBase
Parameters:
publishURI - The publishURI to set.

setSecurityURI

public void setSecurityURI(java.net.URI securityURI)
Specified by:
setSecurityURI in interface IRegistryBase
Parameters:
publishURI - The publishURI to set.

getSecurityProvider

public java.lang.String getSecurityProvider()
Returns:
Returns the securityProvider.

setSecurityProvider

public void setSecurityProvider(java.lang.String securityProvider)
Parameters:
securityProvider - The securityProvider to set.

getTransport

public Transport getTransport()
Specified by:
getTransport in interface IRegistry
Specified by:
getTransport in interface IRegistryBase
Returns:
Returns the transport.

setTransport

public void setTransport(Transport transport)
Specified by:
setTransport in interface IRegistry
Specified by:
setTransport in interface IRegistryBase
Parameters:
transport - The transport to set.

getUddiNamespace

public java.lang.String getUddiNamespace()
Returns:
Returns the uddiNS.

setUddiNamespace

public void setUddiNamespace(java.lang.String uddiNS)
Parameters:
uddiNS - The uddiNS to set.

getUddiVersion

public java.lang.String getUddiVersion()
Returns:
Returns the uddiVersion.

setUddiVersion

public void setUddiVersion(java.lang.String uddiVersion)
Parameters:
uddiVersion - The uddiVersion to set.

deleteBinding

public DispositionReport deleteBinding(java.lang.String authInfo,
                                       java.lang.String[] bindingKeyArray)
                                throws RegistryException
"Used to remove an existing bindingTemplate from the bindingTemplates collection that is part of a specified businessService structure."

Specified by:
deleteBinding in interface IRegistry
Throws:
RegistryException;
RegistryException

deleteBusiness

public DispositionReport deleteBusiness(java.lang.String authInfo,
                                        java.lang.String[] businessKeyArray)
                                 throws RegistryException
"Used to delete registered businessEntity information from the registry."

Specified by:
deleteBusiness in interface IRegistry
Throws:
RegistryException;
RegistryException

deletePublisherAssertions

public DispositionReport deletePublisherAssertions(java.lang.String authInfo,
                                                   PublisherAssertion[] assertionArray)
                                            throws RegistryException
Specified by:
deletePublisherAssertions in interface IRegistry
Throws:
RegistryException;
RegistryException

deleteService

public DispositionReport deleteService(java.lang.String authInfo,
                                       java.lang.String[] serviceKeyArray)
                                throws RegistryException
"Used to delete an existing businessService from the businessServices collection that is part of a specified businessEntity."

Specified by:
deleteService in interface IRegistry
Throws:
RegistryException;
RegistryException

deleteTModel

public DispositionReport deleteTModel(java.lang.String authInfo,
                                      java.lang.String[] tModelKeyArray)
                               throws RegistryException
"Used to delete registered information about a tModel. If there are any references to a tModel when this call is made, the tModel will be marked deleted instead of being physically removed."

Specified by:
deleteTModel in interface IRegistry
Throws:
RegistryException;
RegistryException

findBusiness

public BusinessList findBusiness(Name[] nameArray,
                                 DiscoveryURLs discoveryURLs,
                                 IdentifierBag identifierBag,
                                 CategoryBag categoryBag,
                                 TModelBag tModelBag,
                                 FindQualifiers findQualifiers,
                                 int maxRows)
                          throws RegistryException
Used to locate information about one or more businesses. Returns a businessList message that matches the conditions specified.

Specified by:
findBusiness in interface IRegistry
Throws:
RegistryException;
RegistryException

findBinding

public BindingDetail findBinding(java.lang.String serviceKey,
                                 CategoryBag categoryBag,
                                 TModelBag tModelBag,
                                 FindQualifiers findQualifiers,
                                 int maxRows)
                          throws RegistryException
"Used to locate specific bindings within a registered businessService. Returns a bindingDetail message."

Specified by:
findBinding in interface IRegistry
Throws:
RegistryException

findService

public ServiceList findService(java.lang.String businessKey,
                               Name[] nameArray,
                               CategoryBag categoryBag,
                               TModelBag tModelBag,
                               FindQualifiers findQualifiers,
                               int maxRows)
                        throws RegistryException
"Used to locate specific services within a registered businessEntity. Return a serviceList message." From the XML spec (API, p18) it appears that the name, categoryBag, and tModelBag arguments are mutually exclusive.

Specified by:
findService in interface IRegistry
Throws:
RegistryException;
RegistryException

findTModel

public TModelList findTModel(java.lang.String name,
                             CategoryBag categoryBag,
                             IdentifierBag identifierBag,
                             FindQualifiers findQualifiers,
                             int maxRows)
                      throws RegistryException
"Used to locate one or more tModel information structures. Returns a tModelList structure."

Specified by:
findTModel in interface IRegistry
Throws:
RegistryException;
RegistryException

getAssertionStatusReport

public AssertionStatusReport getAssertionStatusReport(java.lang.String authInfo,
                                                      java.lang.String completionStatus)
                                               throws RegistryException
Specified by:
getAssertionStatusReport in interface IRegistry
Throws:
RegistryException;
RegistryException

getAuthToken

public AuthToken getAuthToken(java.lang.String userID,
                              java.lang.String cred)
                       throws RegistryException
"Used to request an authentication token from an Operator Site. Authentication tokens are required to use all other APIs defined in the publishers API. This server serves as the program's equivalent of a login request."

Specified by:
getAuthToken in interface IRegistry
Throws:
RegistryException;
RegistryException

getBusinessDetail

public BusinessDetail getBusinessDetail(java.lang.String businessKey)
                                 throws RegistryException
Used to get the full businessEntity information for a particular business entity. Returns a businessDetail message.

Specified by:
getBusinessDetail in interface IRegistry
Throws:
RegistryException;
RegistryException

getBusinessDetail

public BusinessDetail getBusinessDetail(java.lang.String[] businessKeyArray)
                                 throws RegistryException
"Used to get the full businessEntity information for one or more businesses. Returns a businessDetail message."

Specified by:
getBusinessDetail in interface IRegistry
Throws:
RegistryException;
RegistryException

getPublisherAssertions

public PublisherAssertions getPublisherAssertions(java.lang.String authInfo)
                                           throws RegistryException
Specified by:
getPublisherAssertions in interface IRegistry
Throws:
RegistryException;
RegistryException

getRegisteredInfo

public RegisteredInfo getRegisteredInfo(java.lang.String authInfo)
                                 throws RegistryException
Specified by:
getRegisteredInfo in interface IRegistry
Throws:
RegistryException;
RegistryException

getServiceDetail

public ServiceDetail getServiceDetail(java.lang.String serviceKey)
                               throws RegistryException
"Used to get full details for a particular registered businessService. Returns a serviceDetail message."

Specified by:
getServiceDetail in interface IRegistry
Throws:
RegistryException;
RegistryException

getServiceDetail

public ServiceDetail getServiceDetail(java.lang.String[] serviceKeyArray)
                               throws RegistryException
"Used to get full details for a given set of registered businessService data. Returns a serviceDetail message."

Specified by:
getServiceDetail in interface IRegistry
Throws:
RegistryException;
RegistryException

getTModelDetail

public TModelDetail getTModelDetail(java.lang.String tModelKey)
                             throws RegistryException
"Used to get full details for a particular registered TModel. Returns a tModelDetail message."

Specified by:
getTModelDetail in interface IRegistry
Throws:
RegistryException;
RegistryException

getTModelDetail

public TModelDetail getTModelDetail(java.lang.String[] tModelKeyArray)
                             throws RegistryException
"Used to get full details for a given set of registered tModel data. Returns a tModelDetail message."

Specified by:
getTModelDetail in interface IRegistry
Throws:
RegistryException;
RegistryException

setPublisherAssertions

public PublisherAssertions setPublisherAssertions(java.lang.String authInfo,
                                                  PublisherAssertion[] assertionArray)
                                           throws RegistryException
Specified by:
setPublisherAssertions in interface IRegistry
Throws:
RegistryException;
RegistryException

saveBinding

public BindingDetail saveBinding(java.lang.String authInfo,
                                 BindingTemplate[] bindingArray)
                          throws RegistryException
"Used to register new bindingTemplate information or update existing bindingTemplate information. Use this to control information about technical capabilities exposed by a registered business."

Specified by:
saveBinding in interface IRegistry
Throws:
RegistryException;
RegistryException

saveBusiness

public BusinessDetail saveBusiness(java.lang.String authInfo,
                                   BusinessEntity[] businessArray)
                            throws RegistryException
"Used to register new businessEntity information or update existing businessEntity information. Use this to control the overall information about the entire business. Of the save_x APIs this one has the broadest effect."

Specified by:
saveBusiness in interface IRegistry
Throws:
RegistryException;
RegistryException

saveService

public ServiceDetail saveService(java.lang.String authInfo,
                                 BusinessService[] serviceArray)
                          throws RegistryException
"Used to register or update complete information about a businessService exposed by a specified businessEntity."

Specified by:
saveService in interface IRegistry
Throws:
RegistryException;
RegistryException

saveTModel

public TModelDetail saveTModel(java.lang.String authInfo,
                               TModel[] tModelArray)
                        throws RegistryException
"Used to register or update complete information about a tModel."

Specified by:
saveTModel in interface IRegistry
Throws:
RegistryException;
RegistryException

getTransport

public Transport getTransport(java.lang.String className)
Returns an implementation of Transport based on the className passed in. If a null value is passed then the default Transport implementation "org.apache.ws.scout.transport.AxisTransport" is created and returned.

Returns:
Transport

getClassForName

public static java.lang.Class getClassForName(java.lang.String name)
                                       throws java.lang.ClassNotFoundException,
                                              java.lang.NoClassDefFoundError
Parameters:
name -
Returns:
The class object for the name given
Throws:
java.lang.ClassNotFoundException
java.lang.NoClassDefFoundError


Copyright © 2004-2012 The Apache Software Foundation. All Rights Reserved.