public class RouteMatcher extends Object implements Cloneable, Serializable
Modifier and Type | Method and Description |
---|---|
String |
asString() |
RouteMatcher |
clone() |
static RouteMatcher |
emptyMatcher()
Return an empty matcher (which match no routes).
|
boolean |
equals(Object another) |
int |
hashCode() |
boolean |
matches(org.onebusaway.gtfs.model.Route route) |
static RouteMatcher |
parse(String routeSpecList)
Build a new RouteMatcher from a string representation.
|
String |
toString() |
public static RouteMatcher emptyMatcher()
public static RouteMatcher parse(String routeSpecList)
routeSpecList
- A comma-separated list of route spec, each of the format
[agencyId]_[routeName]_[routeId] Please note that this format is not really intuitive
as it does not follow the OBA-gtfslib AgencyAndId standard ('agencyID_routeId'). This
was kept for backward-compatibility purposes. If the original routeName contains some
"_" each *must* be replaced by a space. If the agency or route ID contains a "_" they
must be escaped using a backslash.
TODO why do we want to accept route name strings when we have IDs? Break backward compatibility.
FIXME this is the only place we are still using underscores as scope separators. Rethink this from scratch.IllegalArgumentException
- If the string representation is invalid.public boolean matches(org.onebusaway.gtfs.model.Route route)
public String asString()
public RouteMatcher clone()
Copyright © 2018. All rights reserved.