Package org.somda.sdc.dpws.service
Class HostingServiceProxyImpl
java.lang.Object
org.somda.sdc.dpws.service.HostingServiceProxyImpl
- All Implemented Interfaces:
HostingServiceProxy,InterceptorHandler,RequestResponseClient
Default implementation of HostingServiceProxy.
-
Method Summary
Modifier and TypeMethodDescriptionGets the physical address that is actively being used to send requests.Gets the unique WS-Discovery target service EPR.Gets all hosted service proxies.longGets the metadata version.Optional<org.somda.sdc.dpws.model.ThisDeviceType>Gets the DPWS ThisDevice information.Optional<org.somda.sdc.dpws.model.ThisModelType>Gets the DPWS ThisModel information.getTypes()Gets types of the hosting service.voidregister(Interceptor interceptor) Registers a callback object.sendRequestResponse(SoapMessage request) Sends a SOAP request message and waits for the response to be received from the recipient.toString()
-
Method Details
-
getEndpointReferenceAddress
Description copied from interface:HostingServiceProxyGets the unique WS-Discovery target service EPR.If TLS is enforced, the value of the endpoint reference address as returned by this function is trustworthy (opposed to
DiscoveredDevice.getEprAddress(), which is potentially retrieved via unsecured UDP).- Specified by:
getEndpointReferenceAddressin interfaceHostingServiceProxy- Returns:
- WS-Discovery target service EPR.
-
getTypes
Description copied from interface:HostingServiceProxyGets types of the hosting service.- Specified by:
getTypesin interfaceHostingServiceProxy- Returns:
- list of types, which classifies the hosting service.
-
getThisModel
Description copied from interface:HostingServiceProxyGets the DPWS ThisModel information.- Specified by:
getThisModelin interfaceHostingServiceProxy- Returns:
- ThisModel information.
-
getThisDevice
Description copied from interface:HostingServiceProxyGets the DPWS ThisDevice information.- Specified by:
getThisDevicein interfaceHostingServiceProxy- Returns:
- ThisDevice information.
-
getHostedServices
Description copied from interface:HostingServiceProxyGets all hosted service proxies.- Specified by:
getHostedServicesin interfaceHostingServiceProxy- Returns:
- all hosted services.
-
getActiveXAddr
Description copied from interface:HostingServiceProxyGets the physical address that is actively being used to send requests.A hosting service can have different physical addresses in order to be accessible. The one that is returned with this function is the one that was used to initially resolve metadata (GetTransfer requests).
- Specified by:
getActiveXAddrin interfaceHostingServiceProxy- Returns:
- the currently active EPR address.
-
getMetadataVersion
public long getMetadataVersion()Description copied from interface:HostingServiceProxyGets the metadata version.Attention: this data might have come from an unreliable source. todo DGr remove that function - the metadata version does not necessarily reflect the hosting service data
- Specified by:
getMetadataVersionin interfaceHostingServiceProxy- Returns:
- the metadata version
-
getRequestResponseClient
- Specified by:
getRequestResponseClientin interfaceHostingServiceProxy
-
register
Description copied from interface:InterceptorHandlerRegisters a callback object.- Specified by:
registerin interfaceInterceptorHandler- Parameters:
interceptor- an object that possessesMessageInterceptorannotated methods.- See Also:
-
sendRequestResponse
public SoapMessage sendRequestResponse(SoapMessage request) throws SoapFaultException, MarshallingException, TransportException, InterceptorException Description copied from interface:RequestResponseClientSends a SOAP request message and waits for the response to be received from the recipient.- Specified by:
sendRequestResponsein interfaceRequestResponseClient- Parameters:
request- outgoing request message.- Returns:
- incoming response message.
- Throws:
SoapFaultException- if a SOAP fault comes up during processing.MarshallingException- if any exception occurs during marshalling or unmarshalling of SOAP messages.TransportException- if transport-related exceptions come up during processing. This will hinder the response from being sent.InterceptorException- if one of the interceptors pops up with an error.
-
toString
-