org.onebusaway.transit_data_federation.impl
Class StopSearchServiceImpl
java.lang.Object
org.onebusaway.transit_data_federation.impl.StopSearchServiceImpl
- All Implemented Interfaces:
- StopSearchService
@Component
public class StopSearchServiceImpl
- extends Object
- implements StopSearchService
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
StopSearchServiceImpl
public StopSearchServiceImpl()
setBundle
public void setBundle(FederatedTransitDataBundle bundle)
initialize
@PostConstruct
@Refreshable(dependsOn="stopSearchData")
public void initialize()
throws IOException
- Throws:
IOException
searchForStopsByCode
public SearchResult<org.onebusaway.gtfs.model.AgencyAndId> searchForStopsByCode(String id,
int maxResultCount,
double minScoreToKeep)
throws IOException,
org.apache.lucene.queryParser.ParseException
- Description copied from interface:
StopSearchService
- Search for stop ids by stop code (see
Stop.getCode()
). Typically
default to a search against Stop.getId()
if no code is specified
for a stop.
- Specified by:
searchForStopsByCode
in interface StopSearchService
- Parameters:
id
- the stop code querymaxResultCount
- maximum number of results to returnminScoreToKeep
- implementation-specific score cutoff for search
results
- Returns:
- a search result for matching stop ids
- Throws:
IOException
org.apache.lucene.queryParser.ParseException
searchForStopsByName
public SearchResult<org.onebusaway.gtfs.model.AgencyAndId> searchForStopsByName(String name,
int maxResultCount,
double minScoreToKeep)
throws IOException,
org.apache.lucene.queryParser.ParseException
- Description copied from interface:
StopSearchService
- Search for stop ids by stop name (see
Stop.getName()
)
- Specified by:
searchForStopsByName
in interface StopSearchService
maxResultCount
- maximum number of results to returnminScoreToKeep
- implementation-specific score cutoff for search
results
- Returns:
- a search result for matching stop ids
- Throws:
IOException
org.apache.lucene.queryParser.ParseException
Copyright © 2012 OneBusAway. All Rights Reserved.