com.esri.arcgis.carto
Class WMSServer

java.lang.Object
  extended by com.esri.arcgis.carto.WMSServer
All Implemented Interfaces:
IWMSServer, com.esri.arcgis.interop.RemoteObjRef, IServerObjectExtension, IObjectActivate, IObjectConstruct, ISupportErrorInfo, Serializable

public class WMSServer
extends Object
implements com.esri.arcgis.interop.RemoteObjRef, IServerObjectExtension, IObjectConstruct, IObjectActivate, IWMSServer, ISupportErrorInfo

The WMS Server Object Extension.

Description

The Class represents the WMS Server Object Extension

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

See Also:
Serialized Form

Field Summary
 
Fields inherited from interface com.esri.arcgis.system.IObjectActivate
IID, IIDe3b78022_143e_4e61_9099_ed319ec061e7, xxDummy
 
Constructor Summary
WMSServer()
          Constructs a WMSServer using ArcGIS Engine.
WMSServer(Object obj)
          Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
WMSServer theWMSServer = (WMSServer) obj;
 
Method Summary
 void activate()
          Activates the object.
 void construct(IPropertySet props)
          Two phase object construction.
 void deactivate()
          Deactivates the object.
 boolean equals(Object o)
          Compare this object with another
static String getClsid()
          getClsid.
 byte[] getData(String capabilities, String request, String[] pMimeType)
          Handle WMS Server binary request.
 String getToPost(String sGet)
          Handle translation from Get to Post.
 int hashCode()
          the hashcode for this object
 void init(IServerObjectHelper pSOH)
          Initializes and starts the server object specified by the IServerObjectHelper reference.
 void interfaceSupportsErrorInfo(GUID riid)
          interfaceSupportsErrorInfo
 void setParameters(String name, String value)
          Handle setting WMS Server parameters.
 void shutdown()
          Stops the server object specified by the IServerObjectHelper reference.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.esri.arcgis.interop.RemoteObjRef
getJintegraDispatch, release
 

Constructor Detail

WMSServer

public WMSServer()
          throws IOException,
                 UnknownHostException
Constructs a WMSServer using ArcGIS Engine.

Throws:
IOException - if there are interop problems
UnknownHostException - if there are interop problems

WMSServer

public WMSServer(Object obj)
          throws IOException
Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
WMSServer theWMSServer = (WMSServer) obj;

Construct a WMSServer using a reference to such an object returned from ArcGIS Engine or Server. This is semantically equivalent to casting obj to WMSServer.

Parameters:
obj - an object returned from ArcGIS Engine or Server
Throws:
IOException - if there are interop problems
Method Detail

getClsid

public static String getClsid()
getClsid.


equals

public boolean equals(Object o)
Compare this object with another

Overrides:
equals in class Object

hashCode

public int hashCode()
the hashcode for this object

Overrides:
hashCode in class Object

init

public void init(IServerObjectHelper pSOH)
          throws IOException,
                 AutomationException
Initializes and starts the server object specified by the IServerObjectHelper reference.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
init in interface IServerObjectExtension
Parameters:
pSOH - A reference to a com.esri.arcgis.server.IServerObjectHelper (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

shutdown

public void shutdown()
              throws IOException,
                     AutomationException
Stops the server object specified by the IServerObjectHelper reference.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
shutdown in interface IServerObjectExtension
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

construct

public void construct(IPropertySet props)
               throws IOException,
                      AutomationException
Two phase object construction.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Specified by:
construct in interface IObjectConstruct
Parameters:
props - A reference to a com.esri.arcgis.system.IPropertySet (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

activate

public void activate()
              throws IOException,
                     AutomationException
Activates the object.

Specified by:
activate in interface IObjectActivate
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

deactivate

public void deactivate()
                throws IOException,
                       AutomationException
Deactivates the object.

Specified by:
deactivate in interface IObjectActivate
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getToPost

public String getToPost(String sGet)
                 throws IOException,
                        AutomationException
Handle translation from Get to Post.

Description

Convert a WMS request string (query string used in WMS HTTP GET request mode) to an WMS request XML (XML used in WMS HTTP POST request mode)

Remarks

According to OGC WMS Implementation Specification, A WMS Server should be able to accept WMS request in both HTTP GET (requests are WMS URL appended by key-value pairs) mode and HTTP Post mode (requests are XML whose DTD or shchema are defined in WMS Specification). To simplify the logic of WMS Server Object Extension, all WMS requests will be converted to XML before they reach the server object, so method GetToPost() is used whenever a WMS request in HTTP GET mode is received.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getToPost in interface IWMSServer
Parameters:
sGet - The sGet (in)
Returns:
The pPost
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getData

public byte[] getData(String capabilities,
                      String request,
                      String[] pMimeType)
               throws IOException,
                      AutomationException
Handle WMS Server binary request.

Description

Parse WMS requests and get responses from Server Object.

Remarks

Responses can either be normal XML document containing meta information, feature information and exception information, or images

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getData in interface IWMSServer
Parameters:
capabilities - The capabilities (in)
request - The request (in)
pMimeType - The pMimeType (out: use single element array)
Returns:
An unsigned byte
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setParameters

public void setParameters(String name,
                          String value)
                   throws IOException,
                          AutomationException
Handle setting WMS Server parameters.

Description

Set the parameters of WMS Server Object Extension.

Remarks

Multiple users will be able to use a same Server Object to provide WMS service, but they may provide different information for their own WMS service, for example, "organization info", "contact info", "Style URL". They can use setParameters() method to populate these information.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
setParameters in interface IWMSServer
Parameters:
name - The name (in)
value - The value (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

interfaceSupportsErrorInfo

public void interfaceSupportsErrorInfo(GUID riid)
                                throws IOException,
                                       AutomationException
interfaceSupportsErrorInfo

Description

Indicates whether the interface supports IErrorInfo.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Specified by:
interfaceSupportsErrorInfo in interface ISupportErrorInfo
Parameters:
riid - A Structure: com.esri.arcgis.support.ms.stdole.GUID (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.