Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.gisgraphy.domain.repository
Interface IGisFeatureDao

All Superinterfaces:
  IDao<GisFeature,Long>, IGisDao<GisFeature>

All Known Implementing Classes:
  GisFeatureDao

    public interface IGisFeatureDao

extends IGisDao<GisFeature>

Interface of data access object for `GisFeature`

Author:
  David Masclet

Method Summary
`int` | `deleteAllExceptAdmsAndCountries()` Delete all gisFeatures and subclass except Adms and countries (gisFeature with null featureCode will be deleted too). this method is usefull when gisFeature 'belongs' to some adms and we want to delete the gisfeature first and then the adms and countries.
`long` | `getMaxFeatureId()`
`List<com.gisgraphy.domain.valueobject.GisFeatureDistance>` | `getNearestAndDistanceFrom(com.vividsolutions.jts.geom.Point point, double distance, boolean includeDistanceField, Class<? extends GisFeature> requiredClass)`
`List<com.gisgraphy.domain.valueobject.GisFeatureDistance>` | `getNearestAndDistanceFrom(com.vividsolutions.jts.geom.Point point, double distance, int firstResult, int maxResults, boolean includeDistanceField, Class<? extends GisFeature> requiredClass)` tips to search the nearestplace use firstresult=1 and maxResults=1
`List<com.gisgraphy.domain.valueobject.GisFeatureDistance>` | `getNearestAndDistanceFromGisFeature(GisFeature gisFeature, double distance, boolean includeDistanceField, Class<? extends GisFeature> requiredClass)`
`List<com.gisgraphy.domain.valueobject.GisFeatureDistance>` | `getNearestAndDistanceFromGisFeature(GisFeature gisFeature, double distance, int firstResult, int maxResults, boolean includeDistanceField, Class<? extends GisFeature> requiredClass)` tips to search the nearestplace use firstresult=1 and maxResults=1
`List<GisFeature>` | `listAllFeaturesFromText(String name, boolean includeAlternateNames)` Do a full text search for the given name.

Methods inherited from interface com.gisgraphy.domain.repository.IGisDao
`createGISTIndexForLocationColumn, getByFeatureId, getDirties, getEager, getNearestAndDistanceFrom, getNearestAndDistanceFrom, getNearestAndDistanceFromGisFeature, getNearestAndDistanceFromGisFeature, listByFeatureIds, listByName, listFromText`

Methods inherited from interface com.gisgraphy.domain.repository.IDao
`count, deleteAll, deleteAll, exists, flushAndClear, get, getAll, getAllPaginate, getPersistenceClass, remove, save, setFlushMode`

Method Detail

### listAllFeaturesFromText

    List<GisFeature> listAllFeaturesFromText(String name,
                                             boolean includeAlternateNames)

  Do a full text search for the given name. The search will be case, iso-latin, comma-separated insensitive
  search for 'saint-André', 'saint-Andre', 'SaInT-andré', 'st-andré', etc will return the same results. The search is done for all type, independentely of the type

  Parameters:
    `name` - the name or zipcode of the GisFeature to search
    `includeAlternateNames` - wether we search in the alternatenames and names
  Returns:
    a list of gisFeatures of type of the class for the given text. the max list size is `GenericGisDao.MAX_FULLTEXT_RESULTS`;
  See Also:
    `IGisDao.listFromText(String, boolean)`

### getNearestAndDistanceFromGisFeature

    List<com.gisgraphy.domain.valueobject.GisFeatureDistance> getNearestAndDistanceFromGisFeature(GisFeature gisFeature,
                                                                                                  double distance,
                                                                                                  int firstResult,
                                                                                                  int maxResults,
                                                                                                  boolean includeDistanceField,
                                                                                                  Class<? extends GisFeature> requiredClass)

  tips to search the nearestplace use firstresult=1 and maxResults=1

  Parameters:
    `gisFeature` - The GisFeature from which we want to find GIS Object
    `distance` - distance The radius in meters
    `firstResult` - the firstResult index (for pagination), numbered from 1, if < 1 : it will not be taken into account
    `maxResults` - The Maximum number of results to retrieve (for pagination), if <= 0 : it will not be taken into acount
    `requiredClass` - the class of the object to be retireved
  Returns:
    A List of GisFeatureDistance with the nearest elements or an emptylist (never return null), ordered by distance.note the specified gisFeature will not be included into results
  See Also:
    `GisFeatureDistance`

### getNearestAndDistanceFromGisFeature

    List<com.gisgraphy.domain.valueobject.GisFeatureDistance> getNearestAndDistanceFromGisFeature(GisFeature gisFeature,
                                                                                                  double distance,
                                                                                                  boolean includeDistanceField,
                                                                                                  Class<? extends GisFeature> requiredClass)

  Parameters:
    `gisFeature` - The GisFeature from which we want to find GIS Object
    `distance` - distance The radius in meters
    `requiredClass` - the class of the object to be retireved
  Returns:
    A List of GisFeatureDistance with the nearest elements or an emptylist (never return null), ordered by distance.note the specified gisFeature will not be included into results
  See Also:
    `GisFeatureDistance`

### getNearestAndDistanceFrom

    List<com.gisgraphy.domain.valueobject.GisFeatureDistance> getNearestAndDistanceFrom(com.vividsolutions.jts.geom.Point point,
                                                                                        double distance,
                                                                                        int firstResult,
                                                                                        int maxResults,
                                                                                        boolean includeDistanceField,
                                                                                        Class<? extends GisFeature> requiredClass)

  tips to search the nearestplace use firstresult=1 and maxResults=1

  Parameters:
    `point` - The point from which we want to find GIS Object
    `distance` - distance The radius in meters
    `firstResult` - the firstResult index (for pagination), numbered from 1, if < 1 : it will not be taken into account
    `maxResults` - The Maximum number of results to retrieve (for pagination), if <= 0 : it will not be taken into acount
    `requiredClass` - the class of the object to be retireved
  Returns:
    A List of GisFeatureDistance with the nearest elements or an emptylist (never return null), ordered by distance.note the specified gisFeature will not be included into results
  See Also:
    `GisFeatureDistance`

### getNearestAndDistanceFrom

    List<com.gisgraphy.domain.valueobject.GisFeatureDistance> getNearestAndDistanceFrom(com.vividsolutions.jts.geom.Point point,
                                                                                        double distance,
                                                                                        boolean includeDistanceField,
                                                                                        Class<? extends GisFeature> requiredClass)

  Parameters:
    `point` - The point from which we want to find GIS Object
    `distance` - distance The radius in meters
    `requiredClass` - the class of the object to be retireved
  Returns:
    A List of GisFeatureDistance with the nearest elements or an emptylist (never return null), ordered by distance.note the specified gisFeature will not be included into results
  See Also:
    `GisFeatureDistance`

### deleteAllExceptAdmsAndCountries

    int deleteAllExceptAdmsAndCountries()

  Delete all gisFeatures and subclass except Adms and countries (gisFeature with null featureCode will be deleted too). this method is usefull when gisFeature 'belongs' to some adms and we want to delete the gisfeature first and then the adms and countries. We don't control the fact that adms should be delete after all gisFeature due to Primary /foreign key with GenericGisDao.deleteAll()

  Returns:
    the number of deleted elements

### getMaxFeatureId

    long getMaxFeatureId()

  Returns:
    the highest featureId (independant from the placetype)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2012. All Rights Reserved.