oracle.panama.spatial
Class SpatialManager

java.lang.Object
  |
  +--oracle.panama.spatial.SpatialManager

public class SpatialManager
extends java.lang.Object

This class defines a manager that can generate service objects for geocoding, routing and YP. This class defines final variables only and is thread-safe.


Constructor Summary
SpatialManager()
           
 
Method Summary
TypeMethod
static YPBusiness createBusiness(Location location, java.lang.String telephone, java.lang.String description)
          This function creates an object of a class implementing YPBusiness.
static Location createLocation(Point geom, java.lang.String companyName, java.lang.String firstLine, java.lang.String secondLine, java.lang.String lastLine, java.lang.String countryName)
          This function creates an object of a class implementing Location.
static Location createLocation(Point geom, java.lang.String companyName, java.lang.String firstLine, java.lang.String secondLine, java.lang.String cityName, java.lang.String stateName, java.lang.String postalCode, java.lang.String postalCodeExt, java.lang.String countryName)
          This function creates an object of a class implementing Location.
static Location createLocation(Point geom, java.lang.String matchCode, java.lang.String companyName, java.lang.String firstLine, java.lang.String secondLine, java.lang.String cityName, java.lang.String stateName, java.lang.String postalCode, java.lang.String postalCodeExt, java.lang.String lastLine, java.lang.String countyName, java.lang.String blockNum)
          This function creates an object of a class implementing Location.
static Location createLocation(Point geom, java.lang.String matchCode, java.lang.String companyName, java.lang.String firstLine, java.lang.String secondLine, java.lang.String cityName, java.lang.String stateName, java.lang.String postalCode, java.lang.String postalCodeExt, java.lang.String lastLine, java.lang.String countyName, java.lang.String blockNum, java.lang.String countryName)
          This function creates an object of a class implementing Location.
static Location createLocation(java.lang.String companyName, java.lang.String firstLine, java.lang.String secondLine, java.lang.String lastLine, java.lang.String countryName)
          This function creates an object of a class implementing Location.
static Location createLocation(java.lang.String companyName, java.lang.String firstLine, java.lang.String secondLine, java.lang.String cityName, java.lang.String stateName, java.lang.String postalCode, java.lang.String postalCodeExt, java.lang.String countryName)
          This function creates an object of a class implementing Location.
static Point createPoint()
          This function creates an object of a class implementing Point.
static Point createPoint(double longitude, double latitude)
          This function creates an object of a class implementing Point.
static Point createPoint(double longitude, double latitude, double radiusInMeters)
          This function creates an object of a class implementing Point.
static Point createPoint(double longitude, double latitude, java.lang.String label)
          This function creates an object of a class implementing Point.
static Point createPoint(double longitude, double latitude, java.lang.String label, double radiusInMeters)
          This function creates an object of a class implementing Point.
static Geocoder getGeocoder()
          This returns a Geocoder object.
static Mapper getMapper()
          This returns a Mapper object.
static RegionModel getRegionModel()
          Get RegionModel.
static Router getRouter()
          This returns a Router object.
static TrafficReporter getTrafficReporter()
           
static YPFinder getYPFinder()
          This returns a YPFinder object.
static java.util.Iterator listAllGeocodingProviders()
          This function returns an Iterator enumerating all geocoding providers in undefined order.
static java.util.Iterator listAllMappingProviders()
          This function returns an Iterator enumerating all mapping providers in undefined order.
static java.util.Iterator listAllRoutingProviders()
          This function returns an Iterator enumerating all routing providers in undefined order.
static java.util.Iterator listAllTrafficProviders()
           
static java.util.Iterator listAllYPProviders()
          This function returns an Iterator enumerating all YP providers in undefined order.
static void reloadPropertiesAndXMLFiles()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SpatialManager

public SpatialManager()
Method Detail

getGeocoder

public static Geocoder getGeocoder()
This returns a Geocoder object.
Returns:
a Geocoder object

getMapper

public static Mapper getMapper()
This returns a Mapper object.
Returns:
a Mapper object

getRouter

public static Router getRouter()
This returns a Router object.
Returns:
a Router object

getYPFinder

public static YPFinder getYPFinder()
This returns a YPFinder object.
Returns:
a YPFinder object

getTrafficReporter

public static TrafficReporter getTrafficReporter()

reloadPropertiesAndXMLFiles

public static void reloadPropertiesAndXMLFiles()

createLocation

public static Location createLocation(Point geom,
                                      java.lang.String companyName,
                                      java.lang.String firstLine,
                                      java.lang.String secondLine,
                                      java.lang.String lastLine,
                                      java.lang.String countryName)
This function creates an object of a class implementing Location.
Parameters:
geom - a Geometry representing the lat/lon of the location
companyName - a String representing the company name
firstLine - a String representing the first address line
secondLine - a String representing the second address line
lastLine - a String representing the last address line
countryName - a String representing the country
Returns:
an object of a class implementing Location representing the requested address

createLocation

public static Location createLocation(Point geom,
                                      java.lang.String companyName,
                                      java.lang.String firstLine,
                                      java.lang.String secondLine,
                                      java.lang.String cityName,
                                      java.lang.String stateName,
                                      java.lang.String postalCode,
                                      java.lang.String postalCodeExt,
                                      java.lang.String countryName)
This function creates an object of a class implementing Location.
Parameters:
geom - a Geometry representing the lat/lon of the location
companyName - a String representing the company name
firstLine - a String representing the first address line
secondLine - a String representing the second address line
cityName - a String representing the city name
stateName - a String representing the state name
postalCode - a String representing the postal code
postalCodeExt - a String representing the postal code extension
countryName - a String representing the country
Returns:
an object of a class implementing Location representing the requested address

createLocation

public static Location createLocation(Point geom,
                                      java.lang.String matchCode,
                                      java.lang.String companyName,
                                      java.lang.String firstLine,
                                      java.lang.String secondLine,
                                      java.lang.String cityName,
                                      java.lang.String stateName,
                                      java.lang.String postalCode,
                                      java.lang.String postalCodeExt,
                                      java.lang.String lastLine,
                                      java.lang.String countyName,
                                      java.lang.String blockNum)
This function creates an object of a class implementing Location.
Parameters:
geom - a Geometry representing the lat/lon of the location
matchCode - a String representing the match code from geocoding
companyName - a String representing the company name
firstLine - a String representing the first address line
secondLine - a String representing the second address line
cityName - a String representing the city name
stateName - a String representing the state name
postalCode - a String representing the postal code
postalCodeExt - a String representing the postal code extension
lastLine - a String representing the last address line
countyName - a String representing the county name
blockNum - a String representing the block number
Returns:
an object of a class implementing Location representing the requested address

createLocation

public static Location createLocation(Point geom,
                                      java.lang.String matchCode,
                                      java.lang.String companyName,
                                      java.lang.String firstLine,
                                      java.lang.String secondLine,
                                      java.lang.String cityName,
                                      java.lang.String stateName,
                                      java.lang.String postalCode,
                                      java.lang.String postalCodeExt,
                                      java.lang.String lastLine,
                                      java.lang.String countyName,
                                      java.lang.String blockNum,
                                      java.lang.String countryName)
This function creates an object of a class implementing Location.
Parameters:
geom - a Geometry representing the lat/lon of the location
matchCode - a String representing the match code from geocoding
companyName - a String representing the company name
firstLine - a String representing the first address line
secondLine - a String representing the second address line
cityName - a String representing the city name
stateName - a String representing the state name
postalCode - a String representing the postal code
postalCodeExt - a String representing the postal code extension
lastLine - a String representing the last address line
countyName - a String representing the county name
blockNum - a String representing the block number
countryName - a String representing the country
Returns:
an object of a class implementing Location representing the requested address

createLocation

public static Location createLocation(java.lang.String companyName,
                                      java.lang.String firstLine,
                                      java.lang.String secondLine,
                                      java.lang.String lastLine,
                                      java.lang.String countryName)
This function creates an object of a class implementing Location. The geographic location is geocoded automatically.
Parameters:
companyName - a String representing the company name
firstLine - a String representing the first address line
secondLine - a String representing the second address line
lastLine - a String representing the last address line
countryName - a String representing the country
Returns:
an object of a class implementing Location representing the requested address

createLocation

public static Location createLocation(java.lang.String companyName,
                                      java.lang.String firstLine,
                                      java.lang.String secondLine,
                                      java.lang.String cityName,
                                      java.lang.String stateName,
                                      java.lang.String postalCode,
                                      java.lang.String postalCodeExt,
                                      java.lang.String countryName)
This function creates an object of a class implementing Location. The geographic location is geocoded automatically.
Parameters:
companyName - a String representing the company name
firstLine - a String representing the first address line
secondLine - a String representing the second address line
cityName - a String representing the city name
stateName - a String representing the state name
postalCode - a String representing the postal code
postalCodeExt - a String representing the postal code extension
countryName - a String representing the country
Returns:
an object of a class implementing Location representing the requested address

createPoint

public static Point createPoint()
This function creates an object of a class implementing Point.
Returns:
an object of a class implementing Point representing the requested position

createPoint

public static Point createPoint(double longitude,
                                double latitude)
This function creates an object of a class implementing Point.
Parameters:
longitude - a double representing the longitude of this PointImpl (must not be null)
latitude - a double representing the latitude of this PointImpl (must not be null)
Returns:
an object of a class implementing Point representing the requested position

createPoint

public static Point createPoint(double longitude,
                                double latitude,
                                double radiusInMeters)
This function creates an object of a class implementing Point.
Parameters:
longitude - a double representing the longitude of this PointImpl (must not be null)
latitude - a double representing the latitude of this PointImpl (must not be null)
radiusInMeters - a double representing an optional radius around this point
Returns:
an object of a class implementing Point representing the requested position

createPoint

public static Point createPoint(double longitude,
                                double latitude,
                                java.lang.String label)
This function creates an object of a class implementing Point.
Parameters:
longitude - a double representing the longitude of this PointImpl (must not be null)
latitude - a double representing the latitude of this PointImpl (must not be null)
label - a String representing a label for this PointImpl (may be null)
Returns:
an object of a class implementing Point representing the requested position

createPoint

public static Point createPoint(double longitude,
                                double latitude,
                                java.lang.String label,
                                double radiusInMeters)
This function creates an object of a class implementing Point.
Parameters:
longitude - a double representing the longitude of this PointImpl (must not be null)
latitude - a double representing the latitude of this PointImpl (must not be null)
label - a String representing a label for this PointImpl (may be null)
radiusInMeters - a double representing an optional radius around this point
Returns:
an object of a class implementing Point representing the requested position

listAllGeocodingProviders

public static java.util.Iterator listAllGeocodingProviders()
This function returns an Iterator enumerating all geocoding providers in undefined order. In contrast to the function selectProvider, this function will simply provide a list. The user is free to query the providers' names or other attributes. He is also free to request services from his chosen provider. But he also assumes tasks otherwise performed by the framework: Whether the provider fails or succeeds - no failover will happen, no statistics of success or performance will be kept. If the provider throws a RuntimeException, the caller has to catch it.
Returns:
an Iterator enumerating all geocoding providers (they all extend the Provider class and implement the Geocoder interface)

listAllMappingProviders

public static java.util.Iterator listAllMappingProviders()
This function returns an Iterator enumerating all mapping providers in undefined order. In contrast to the function selectProvider, this function will simply provide a list. The user is free to query the providers' names or other attributes. He is also free to request services from his chosen provider. But he also assumes tasks otherwise performed by the framework: Whether the provider fails or succeeds - no failover will happen, no statistics of success or performance will be kept. If the provider throws a RuntimeException, the caller has to catch it.
Returns:
an Iterator enumerating all mapping providers (they all extend the Provider class and implement the Mapper interface)

listAllRoutingProviders

public static java.util.Iterator listAllRoutingProviders()
This function returns an Iterator enumerating all routing providers in undefined order. In contrast to the function selectProvider, this function will simply provide a list. The user is free to query the providers' names or other attributes. He is also free to request services from his chosen provider. But he also assumes tasks otherwise performed by the framework: Whether the provider fails or succeeds - no failover will happen, no statistics of success or performance will be kept. If the provider throws a RuntimeException, the caller has to catch it.
Returns:
an Iterator enumerating all routing providers (they all extend the Provider class and implement the Router interface)

listAllYPProviders

public static java.util.Iterator listAllYPProviders()
This function returns an Iterator enumerating all YP providers in undefined order. In contrast to the function selectProvider, this function will simply provide a list. The user is free to query the providers' names or other attributes. He is also free to request services from his chosen provider. But he also assumes tasks otherwise performed by the framework: Whether the provider fails or succeeds - no failover will happen, no statistics of success or performance will be kept. If the provider throws a RuntimeException, the caller has to catch it.
Returns:
an Iterator enumerating all YP providers (they all extend the Provider class and implement the YPFinderSimple interface)

listAllTrafficProviders

public static java.util.Iterator listAllTrafficProviders()

createBusiness

public static YPBusiness createBusiness(Location location,
                                        java.lang.String telephone,
                                        java.lang.String description)
This function creates an object of a class implementing YPBusiness.
Parameters:
location - A Location object representing the address and/or location coordinates of the business. This is an essential component of a Location object and should not be null. However, it is not checked whether the value is non-null.
telephone - a String representing the telephone number of the business (may be null)
description - a String representing a description of the business (may be null)
Returns:
an object of a class implementing YPBusiness representing the requested business

getRegionModel

public static RegionModel getRegionModel()
Get RegionModel.
Returns:
RegionModel object.