deegree 2.3 (2010/04/09 10:10 build-4-official)

org.deegree.ogcwebservices.wms
Class RemoteWMService

java.lang.Object
  extended by org.deegree.ogcwebservices.wms.RemoteWMService
All Implemented Interfaces:
OGCWebService

public class RemoteWMService
extends Object
implements OGCWebService

An instance of the class acts as a wrapper to a remote WMS.

Version:
$Revision: 18195 $
Author:
Andreas Poth

Field Summary
protected  HashMap<String,URL> addresses
           
protected  WMSCapabilities capabilities
           
 
Constructor Summary
RemoteWMService(WMSCapabilities capabilities)
          Creates a new instance of RemoteWMService
 
Method Summary
 Object doService(OGCWebServiceRequest request)
          the method performs the handling of the passed OGCWebServiceEvent directly and returns the result to the calling class/method
 OGCCapabilities getCapabilities()
          returns the capabilities of a OGC web service
protected  String getInputStreamContent(InputStream is)
           
protected  Object handleDescribeLayer(DescribeLayer request)
           
protected  Object handleFeatureInfo(GetFeatureInfo request)
          reads feature infos from the remote WMS by performing a FeatureInfo request against it.
protected  WMSCapabilities handleGetCapabilities(WMSGetCapabilities request)
          reads the capabilities from the remote WMS by performing a GetCapabilities request against it.
protected  Object handleGetLegendGraphic(GetLegendGraphic request)
           
protected  Object handleGetMap(GetMap request)
          performs a GetMap request against the remote service.
protected  Object handleGetStyles(GetStyles request)
           
protected  Object handlePutStyles(PutStyles request)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

addresses

protected HashMap<String,URL> addresses

capabilities

protected WMSCapabilities capabilities
Constructor Detail

RemoteWMService

public RemoteWMService(WMSCapabilities capabilities)
Creates a new instance of RemoteWMService

Parameters:
capabilities -
Method Detail

getCapabilities

public OGCCapabilities getCapabilities()
Description copied from interface: OGCWebService
returns the capabilities of a OGC web service

Specified by:
getCapabilities in interface OGCWebService
Returns:
the capabilities of a OGC web service

doService

public Object doService(OGCWebServiceRequest request)
                 throws OGCWebServiceException
the method performs the handling of the passed OGCWebServiceEvent directly and returns the result to the calling class/method

Specified by:
doService in interface OGCWebService
Parameters:
request - request (WMS, WCS, WFS, WCAS, WCTS, WTS, Gazetter) to perform
Returns:
result of a service operation
Throws:
OGCWebServiceException

handleGetMap

protected Object handleGetMap(GetMap request)
                       throws OGCWebServiceException
performs a GetMap request against the remote service. The result contains the map decoded in the desired format as a byte array.

Parameters:
request - GetMap request
Returns:
the requested map-image
Throws:
OGCWebServiceException - if the url in the request is null

handleFeatureInfo

protected Object handleFeatureInfo(GetFeatureInfo request)
                            throws OGCWebServiceException
reads feature infos from the remote WMS by performing a FeatureInfo request against it. As long the result of a FeatureInfo request is generic (for usual it is som HTML) it isn't easy to combine the result with that of other WMS's

Parameters:
request - feature info request
Returns:
the response of the GetFeatureInfo request.
Throws:
OGCWebServiceException - if the request could not be excuted correctly.

handleGetCapabilities

protected WMSCapabilities handleGetCapabilities(WMSGetCapabilities request)
                                         throws OGCWebServiceException
reads the capabilities from the remote WMS by performing a GetCapabilities request against it.

Parameters:
request - capabilities request
Returns:
remote capabilities
Throws:
OGCWebServiceException - if the request could not be executed correctly.

handleGetStyles

protected Object handleGetStyles(GetStyles request)
                          throws OGCWebServiceException
Parameters:
request - get styles request (WMS 1.1.1 - SLD)
Returns:
null
Throws:
OGCWebServiceException - if the url in the request is null

handlePutStyles

protected Object handlePutStyles(PutStyles request)
                          throws OGCWebServiceException
Parameters:
request - put styles request (WMS 1.1.1 - SLD)
Returns:
null
Throws:
OGCWebServiceException - if the url in the request is null

handleDescribeLayer

protected Object handleDescribeLayer(DescribeLayer request)
                              throws OGCWebServiceException
Parameters:
request - describe layer request (WMS 1.1.1 - SLD)
Returns:
null
Throws:
OGCWebServiceException - if the url in the request is null

handleGetLegendGraphic

protected Object handleGetLegendGraphic(GetLegendGraphic request)
                                 throws OGCWebServiceException
Parameters:
request - describe layer request (WMS 1.1.1 - SLD)
Returns:
null
Throws:
OGCWebServiceException - if the url in the request is null

getInputStreamContent

protected String getInputStreamContent(InputStream is)
                                throws IOException
Parameters:
is -
Returns:
thr content as String
Throws:
IOException

deegree 2.3 (2010/04/09 10:10 build-4-official)

an open source project founded by lat/lon, Bonn, Germany.
For more information visit: http://www.deegree.org