|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.esri.adf.web.data.GISResource
com.esri.adf.web.aims.data.AIMSMapResource
This class maintains the ArcIMS Resource information. For example the ArcIMS Server Machine name, Port number, Service name etc. It makes TCP or HTTP connection to the specified ArcIMS Server based on the machine name. If the Machine name start with "http" it makes HTTP connection otherwise TCP. In case of TCP Connection the application port number is required. The user name and the password are required properties if the given service name is authenticated.
Resource can be added using JSF managed bean configuration as shown below,
<managed-bean>
<managed-bean-name>aimsResource</managed-bean-name>
<managed-bean-class>com.esri.adf.web.aims.data.AIMSMapResource</managed-bean-class>
<managed-bean-scope>none</managed-bean-scope>
<managed-property>
<property-name>hostName</property-name>
<value>http://machinename</value>
</managed-property>
<managed-property>
<property-name>serviceName</property-name>
<value>ServiceName</value>
</managed-property>
<managed-property>
<property-name>functionalities</property-name>
<map-entries>
<map-entry>
<key>map</key>
<value>#{aimsMap}</value>
</map-entry>
<map-entry>
<key>overview</key>
<value>#{aimsOverview}</value>
</map-entry>
<map-entry>
<key>toc</key>
<value>#{aimsToc}</value>
</map-entry>
<map-entry>
<key>query</key>
<value>#{aimsQuery}</value>
</map-entry>
<map-entry>
<key>geocode</key>
<value>#{aimsGeocode}</value>
</map-entry>
</map-entries>
</managed-property>
</managed-bean>
| Field Summary | |
static java.lang.String |
ARCMAP_RESOURCE_TYPE
The ArcIMS service indicating the type Image Server ArcMap. |
protected com.esri.aims.mtier.io.ConnectionProxy |
connection
The ConnectionProxy object associated with this resource. |
protected java.lang.String |
hostName
The machine name or the URL string to connect ArcIMS Server. |
static java.lang.String |
IMAGE_RESOURCE_TYPE
The ArcIMS service indicating the type Image Server. |
protected java.lang.String |
password
The password to connect the authenticated service. |
protected boolean |
passwordEncrypted
Indicating whether the password is encrpyted or not. |
protected int |
port
The Application server port to connect ArcIMS Server. |
protected java.lang.String |
resourceType
The type of ArcIMS Service. |
protected java.lang.String |
serviceName
The ArcIMS Service name. |
protected java.lang.String |
userName
The user name to connect the authenticated service. |
| Fields inherited from class com.esri.adf.web.data.GISResource |
alias, context, defaultSpatialReference, functionalities, init |
| Constructor Summary | |
AIMSMapResource()
|
|
| Method Summary | |
java.lang.String |
getAlias()
Returns a reader friendly name for this resource. |
protected com.esri.aims.mtier.io.ConnectionProxy |
getConnectionProxy()
Returns the ConnectionProxy object associated with this resource. |
java.lang.String |
getHostName()
Returns the Machine name or URL string of the ArcIMS Server. |
java.lang.String |
getPassword()
Returns the password to connect authenticated service. |
int |
getPort()
Returns the ArcIMS Application Server port number associated with this resource. |
java.lang.String |
getResourceType()
Returns the type of service based on the service name set. |
java.lang.String |
getServiceName()
Return the ArcIMS Service that associated with this resource. |
java.lang.String |
getUserName()
Returns the user name to connect authenticated service. |
void |
init(WebContext context)
This method is called by the WebContext to initialize the resource. |
boolean |
isPasswordEncrypted()
Tests whether the given password is encrypted or not. |
void |
setHostName(java.lang.String hostName)
Set the machine name or URL string of the ArcIMS Server. |
void |
setPassword(java.lang.String password)
Sets the password to connect the authenticate service. |
void |
setPasswordEncrypted(boolean passwordEncrypted)
Sets to true if the given password is encrpted. |
void |
setPort(int port)
Sets the ArcIMS Application Server port number associated with this resource. |
void |
setServiceName(java.lang.String serviceName)
Sets the ArcIMS Service for this resource. |
void |
setUserName(java.lang.String userName)
Sets the user name to connect the authenticate service. |
| Methods inherited from class com.esri.adf.web.data.GISResource |
activate, addFunctionality, destroy, getDefaultSpatialReference, getFunctionalities, getFunctionality, getWebContext, passivate, setAlias, setFunctionalities |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final java.lang.String IMAGE_RESOURCE_TYPE
public static final java.lang.String ARCMAP_RESOURCE_TYPE
protected com.esri.aims.mtier.io.ConnectionProxy connection
ConnectionProxy object associated with this resource.
protected java.lang.String hostName
protected int port
protected java.lang.String serviceName
protected java.lang.String resourceType
protected java.lang.String userName
protected java.lang.String password
protected boolean passwordEncrypted
| Constructor Detail |
public AIMSMapResource()
| Method Detail |
public void init(WebContext context)
GISResource
This method is called by the WebContext to initialize the resource. This is typically called when the
context itself is initialized or when users add a new resource to the context by using the
WebContext#addResource(GISResource) method. A GISResource is usable only after this method has been
called.
This method iterates through all its supported GISFunctionalitys and calls the
GISFunctionality.initFunctionality(GISResource) on them all.
Sub-classes that want to do custom initialization should override this method and make the super
call first before doing the custom stuff:
public void init(WebContext context) {
super.init(context);
myInit();
}
init in interface WebContextInitializeinit in class GISResourcecontext - the WebContext that maintains a reference to this resourceWebContextInitialize.init(com.esri.adf.web.data.WebContext),
GISFunctionality.initFunctionality(GISResource),
WebContext.init(WebContext),
WebContext#addResource(resourceId, GISResource)public java.lang.String getAlias()
GISResourceReturns a reader friendly name for this resource.
It is a good practice for users to explicitly set an alias when the resource is created programmatically or declaratively. Resource providers should provide an auto-generated alias anyway in case users don't explicitly set an alias themselves.
getAlias in class GISResourceprotected com.esri.aims.mtier.io.ConnectionProxy getConnectionProxy()
ConnectionProxy object associated with this resource.
ConnectionProxy objectpublic java.lang.String getHostName()
public int getPort()
public java.lang.String getServiceName()
public java.lang.String getResourceType()
AIMSMapResource.IMAGE_RESOURCE_TYPE
public java.lang.String getUserName()
public java.lang.String getPassword()
public boolean isPasswordEncrypted()
public void setHostName(java.lang.String hostName)
hostName - the host namepublic void setPort(int port)
port - the port numberpublic void setServiceName(java.lang.String serviceName)
serviceName - the ArcIMS service for this resourcepublic void setUserName(java.lang.String userName)
userName - the user namepublic void setPassword(java.lang.String password)
password - the password to connect the authenticate servicepublic void setPasswordEncrypted(boolean passwordEncrypted)
passwordEncrypted - true if password is encrpted; false otherwise
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||