ArcGIS Server Geoportal extension
10

com.esri.gpt.catalog.arcims
Class ImsSocketClient

java.lang.Object
  extended by com.esri.gpt.catalog.arcims.ImsClient
      extended by com.esri.gpt.catalog.arcims.ImsSocketClient
Direct Known Subclasses:
ImsHeadlessClient

public class ImsSocketClient
extends ImsClient

Provides MetadataServer communication with a standard ArcIMS server through a socket.


Field Summary
protected static int DATA_TYPE_STRING
           
protected static int POST_REQ
           
 
Constructor Summary
ImsSocketClient(SocketFarm socketFarm, String serviceName, String username, String metadataRole)
          Construct with supplied configuration parameters.
 
Method Summary
protected  String getClientVersion()
          Gets the client version.
protected  String getForbiddenTags()
          Gets the forbidden tags.
protected  String getLocale()
          Gets the locale.
protected  String getMetadataRole()
          Gets the metadata role.
protected  String getPassword()
          Gets the password.
protected  String getServerProperties()
          Gets the server properties.
protected  String getServiceName()
          Gets the service name.
protected  SocketFarm getSocketFarm()
          Gets the socket farm.
protected  String getUsername()
          Gets the username.
protected  StringBuffer readCharacters(InputStream strm)
          Fully reads the characters from an InputStream.
 void sendRequest()
          Sends the request.
protected  void setClientVersion(String version)
          Sets the client version.
protected  void setForbiddenTags(String tags)
          Sets the forbidden tags.
protected  void setLocale(String locale)
          Sets the locale.
protected  void setMetadataRole(String role)
          Sets the metadata role.
protected  void setPassword(String password)
          Sets the password.
protected  void setServerProperties(String properties)
          Sets the server properties.
protected  void setServiceName(String name)
          Sets the service name.
protected  void setSocketFarm(SocketFarm socketFarm)
          Sets the socket farm.
protected  void setUsername(String username)
          Sets the username.
 
Methods inherited from class com.esri.gpt.catalog.arcims.ImsClient
getAxlRequest, getAxlResponse, getResponseCode, getResponseCodeText, getTimeoutMillisecs, setAxlRequest, setAxlResponse, setResponseCode, setResponseCodeText, setTimeoutMillisecs
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DATA_TYPE_STRING

protected static final int DATA_TYPE_STRING
See Also:
Constant Field Values

POST_REQ

protected static final int POST_REQ
See Also:
Constant Field Values
Constructor Detail

ImsSocketClient

public ImsSocketClient(SocketFarm socketFarm,
                       String serviceName,
                       String username,
                       String metadataRole)
Construct with supplied configuration parameters.

Parameters:
socketFarm - the socket farm
serviceName - the service name
username - the username
metadataRole - the user's ArcIMS metadata role
Method Detail

getClientVersion

protected String getClientVersion()
Gets the client version.

Returns:
the client version

setClientVersion

protected void setClientVersion(String version)
Sets the client version.

Parameters:
version - the client version

getForbiddenTags

protected String getForbiddenTags()
Gets the forbidden tags.

Returns:
the forbidden tags

setForbiddenTags

protected void setForbiddenTags(String tags)
Sets the forbidden tags.

Parameters:
tags - the forbidden tags

getLocale

protected String getLocale()
Gets the locale.

Returns:
the locale

setLocale

protected void setLocale(String locale)
Sets the locale.

Parameters:
locale - the locale

getMetadataRole

protected String getMetadataRole()
Gets the metadata role.

Returns:
the metadata role

setMetadataRole

protected void setMetadataRole(String role)
Sets the metadata role.

Parameters:
role - the metadata role

getPassword

protected String getPassword()
Gets the password.

Returns:
the password

setPassword

protected void setPassword(String password)
Sets the password.

Parameters:
password - the password

getServerProperties

protected String getServerProperties()
Gets the server properties.

Returns:
the server properties

setServerProperties

protected void setServerProperties(String properties)
Sets the server properties.

Parameters:
properties - the server properties

getServiceName

protected String getServiceName()
Gets the service name.

Returns:
the service name

setServiceName

protected void setServiceName(String name)
Sets the service name.

Parameters:
name - the service name.

getSocketFarm

protected SocketFarm getSocketFarm()
Gets the socket farm.

Returns:
the socket farm

setSocketFarm

protected void setSocketFarm(SocketFarm socketFarm)
Sets the socket farm.

Parameters:
socketFarm - the socket farm

getUsername

protected String getUsername()
Gets the username.

Returns:
the username

setUsername

protected void setUsername(String username)
Sets the username.

Parameters:
username - the username

readCharacters

protected StringBuffer readCharacters(InputStream strm)
                               throws IOException
Fully reads the characters from an InputStream.

Parameters:
strm - the InputStream
Returns:
the characters read
Throws:
IOException - if an exception occurs

sendRequest

public void sendRequest()
                 throws IOException
Sends the request.

Specified by:
sendRequest in class ImsClient
Throws:
IOException - if a communication exception occurs

ArcGIS Server Geoportal extension
10

Copyright 2010 Environmental Systems Research Institute. All rights reserved. Use is subject to license terms.