com.bbn.openmap.layer.location.db
Class LocationData

java.lang.Object
  extended by com.bbn.openmap.layer.location.db.LocationData

public class LocationData
extends java.lang.Object

This class is responsible for retrieving Latitude and Longitude Data from a table in a Database given a City/Town name, State. Also it retrieves identifier of the object that would be used to represent this City/Town on Map. For instance, identifier can be either a url or a name that can be looked up somewhere else.

This class needs the RecordSet to be called with the following query:
select CITY (string), STATE (string), GRAPHIC (string, url or graphic name), LATITUDE (float), LONGITUDE (float) from LOCATION_TABLE (tablename where data is stored)
The class is expecting the results in this order.


Field Summary
protected  java.lang.String cityName
           
protected  java.lang.String graphicName
           
protected  float latitude
           
protected  float longitude
           
protected  java.lang.String queryString
           
protected  java.lang.String stateName
           
 
Constructor Summary
LocationData(RecordSet drs)
           
 
Method Summary
 java.lang.String getCityName()
           
 java.lang.String getGraphicName()
           
 float getLatitude()
           
 float getLongitude()
           
 java.lang.String getQueryString()
           
 java.lang.String getStateName()
           
static void main(java.lang.String[] args)
           
 void setQueryString(java.lang.String inQueryString)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

cityName

protected java.lang.String cityName

stateName

protected java.lang.String stateName

graphicName

protected java.lang.String graphicName

latitude

protected float latitude

longitude

protected float longitude

queryString

protected java.lang.String queryString
Constructor Detail

LocationData

public LocationData(RecordSet drs)
             throws java.sql.SQLException
Throws:
java.sql.SQLException
Method Detail

getCityName

public java.lang.String getCityName()
Returns:
city name of current record

getStateName

public java.lang.String getStateName()

getGraphicName

public java.lang.String getGraphicName()

getLatitude

public float getLatitude()

getLongitude

public float getLongitude()

getQueryString

public java.lang.String getQueryString()

setQueryString

public void setQueryString(java.lang.String inQueryString)

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

main

public static void main(java.lang.String[] args)


Copyright (C) BBNT Solutions LLC; See http://openmap.bbn.com/ for details