mirror of
https://gitlab.com/oeffi/public-transport-enabler.git
synced 2025-07-16 09:29:49 +00:00
ignore irrelevant stations
git-svn-id: https://public-transport-enabler.googlecode.com/svn/trunk@639 0924bc21-9374-b0fa-ee44-9ff1593b38f0
This commit is contained in:
parent
c9fe1daa86
commit
8b9ed1bcbc
1 changed files with 6 additions and 2 deletions
|
@ -1040,11 +1040,15 @@ public abstract class AbstractHafasProvider implements NetworkProvider
|
||||||
final String name = ParserUtils.resolveEntities(stop.getString("name"));
|
final String name = ParserUtils.resolveEntities(stop.getString("name"));
|
||||||
final int lat = stop.getInt("y");
|
final int lat = stop.getInt("y");
|
||||||
final int lon = stop.getInt("x");
|
final int lon = stop.getInt("x");
|
||||||
|
final int stopWeight = stop.optInt("stopweight", -1);
|
||||||
|
|
||||||
|
if (stopWeight != 0)
|
||||||
|
{
|
||||||
final String[] nameAndPlace = splitNameAndPlace(name);
|
final String[] nameAndPlace = splitNameAndPlace(name);
|
||||||
stations.add(new Location(LocationType.STATION, id, lat, lon, nameAndPlace[0], nameAndPlace[1]));
|
stations.add(new Location(LocationType.STATION, id, lat, lon, nameAndPlace[0], nameAndPlace[1]));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
catch (final JSONException x)
|
catch (final JSONException x)
|
||||||
{
|
{
|
||||||
x.printStackTrace();
|
x.printStackTrace();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue