|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
ObjectGeoRSSData
public class GeoRSSData
Implements QuadTreeData to store GeoRSS items into quad tree. Provides methods to save and load GeoRSS items to and from file.
| Constructor Summary | |
|---|---|
GeoRSSData(String filename,
DirectPosition2D latLon)
Creates a GeoRSSData object that stores the name of the file that the entry's information is written to and the geo location of the entry. |
|
| Method Summary | |
|---|---|
String |
getFileName()
Returns the name of the file where the entry's info is saved. |
DirectPosition2D |
getLatLon()
|
double |
getX()
Returns the Java 2D x-coordinate for the longitude. |
double |
getY()
Returns the Java 2D y-coordinate for the latitude. |
static HashMap<String,String> |
loadFromFile(String fullFileName)
Reads the file that contains the GeoRSS entry's information and returns a HashMap of key, value pairs where the key is the name of the element e.g. |
void |
saveToFile(Item item,
GeoRSSModule geoRSSModule,
String directory)
Saves the GeoRSS entry to file. |
| Methods inherited from class Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public GeoRSSData(String filename,
DirectPosition2D latLon)
filename - filename where rss entry's info is storedlatLon - geo location of the entry| Method Detail |
|---|
public double getX()
getX in interface QuadTreeDatapublic double getY()
getY in interface QuadTreeDatapublic DirectPosition2D getLatLon()
getLatLon in interface QuadTreeDatapublic String getFileName()
getFileName in interface QuadTreeData
public void saveToFile(Item item,
GeoRSSModule geoRSSModule,
String directory)
item - the Item object from Java ROME API containing the GeoRSS entrygeoRSSModule - the Java ROME API GeoRSSModule to parse geo locationdirectory - the path of the directory in which to save the filepublic static HashMap<String,String> loadFromFile(String fullFileName)
fullFileName - the full path to the file
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||