mirror of
https://gitlab.com/oeffi/public-transport-enabler.git
synced 2025-07-15 00:50:31 +00:00
renamed Line to LineDestination
git-svn-id: https://public-transport-enabler.googlecode.com/svn/trunk@523 0924bc21-9374-b0fa-ee44-9ff1593b38f0
This commit is contained in:
parent
13a1680011
commit
11154da61f
3 changed files with 12 additions and 12 deletions
|
@ -42,7 +42,7 @@ import de.schildbach.pte.dto.Departure;
|
|||
import de.schildbach.pte.dto.Fare;
|
||||
import de.schildbach.pte.dto.Fare.Type;
|
||||
import de.schildbach.pte.dto.GetConnectionDetailsResult;
|
||||
import de.schildbach.pte.dto.Line;
|
||||
import de.schildbach.pte.dto.LineDestination;
|
||||
import de.schildbach.pte.dto.Location;
|
||||
import de.schildbach.pte.dto.LocationType;
|
||||
import de.schildbach.pte.dto.NearbyStationsResult;
|
||||
|
@ -892,7 +892,7 @@ public abstract class AbstractEfaProvider implements NetworkProvider
|
|||
final QueryDeparturesResult result = new QueryDeparturesResult();
|
||||
|
||||
final Location location = processOdvNameElem(pp, place);
|
||||
result.stationDepartures.add(new StationDepartures(location, new LinkedList<Departure>(), new LinkedList<Line>()));
|
||||
result.stationDepartures.add(new StationDepartures(location, new LinkedList<Departure>(), new LinkedList<LineDestination>()));
|
||||
|
||||
XmlPullUtil.exit(pp, "itdOdvName");
|
||||
|
||||
|
@ -904,7 +904,7 @@ public abstract class AbstractEfaProvider implements NetworkProvider
|
|||
final Location assignedLocation = processItdOdvAssignedStop(pp);
|
||||
if (findStationDepartures(result.stationDepartures, assignedLocation.id) == null)
|
||||
result.stationDepartures
|
||||
.add(new StationDepartures(assignedLocation, new LinkedList<Departure>(), new LinkedList<Line>()));
|
||||
.add(new StationDepartures(assignedLocation, new LinkedList<Departure>(), new LinkedList<LineDestination>()));
|
||||
}
|
||||
XmlPullUtil.exit(pp, "itdOdvAssignedStops");
|
||||
}
|
||||
|
@ -941,7 +941,7 @@ public abstract class AbstractEfaProvider implements NetworkProvider
|
|||
final int destinationId = destinationIdStr.length() > 0 ? Integer.parseInt(destinationIdStr) : 0;
|
||||
|
||||
final String lineStr = processItdServingLine(pp);
|
||||
final Line line = new Line(lineStr, lineColors(lineStr), destinationId, destination);
|
||||
final LineDestination line = new LineDestination(lineStr, lineColors(lineStr), destinationId, destination);
|
||||
|
||||
StationDepartures assignedStationDepartures;
|
||||
if (assignedStopId == 0)
|
||||
|
@ -951,7 +951,7 @@ public abstract class AbstractEfaProvider implements NetworkProvider
|
|||
|
||||
if (assignedStationDepartures == null)
|
||||
assignedStationDepartures = new StationDepartures(new Location(LocationType.STATION, assignedStopId),
|
||||
new LinkedList<Departure>(), new LinkedList<Line>());
|
||||
new LinkedList<Departure>(), new LinkedList<LineDestination>());
|
||||
|
||||
if (!assignedStationDepartures.lines.contains(line))
|
||||
assignedStationDepartures.lines.add(line);
|
||||
|
@ -982,7 +982,7 @@ public abstract class AbstractEfaProvider implements NetworkProvider
|
|||
// final String name = normalizeLocationName(XmlPullUtil.attr(pp, "nameWO"));
|
||||
|
||||
assignedStationDepartures = new StationDepartures(new Location(LocationType.STATION, assignedStopId, lat, lon),
|
||||
new LinkedList<Departure>(), new LinkedList<Line>());
|
||||
new LinkedList<Departure>(), new LinkedList<LineDestination>());
|
||||
}
|
||||
|
||||
final String position = normalizePlatform(pp.getAttributeValue(null, "platform"), pp.getAttributeValue(null, "platformName"));
|
||||
|
|
|
@ -20,14 +20,14 @@ package de.schildbach.pte.dto;
|
|||
/**
|
||||
* @author Andreas Schildbach
|
||||
*/
|
||||
public final class Line
|
||||
public final class LineDestination
|
||||
{
|
||||
final public String line;
|
||||
final public int[] lineColors;
|
||||
final public int destinationId;
|
||||
final public String destination;
|
||||
|
||||
public Line(final String line, final int[] lineColors, final int destinationId, final String destination)
|
||||
public LineDestination(final String line, final int[] lineColors, final int destinationId, final String destination)
|
||||
{
|
||||
this.line = line;
|
||||
this.lineColors = lineColors;
|
||||
|
@ -53,9 +53,9 @@ public final class Line
|
|||
{
|
||||
if (o == this)
|
||||
return true;
|
||||
if (!(o instanceof Line))
|
||||
if (!(o instanceof LineDestination))
|
||||
return false;
|
||||
final Line other = (Line) o;
|
||||
final LineDestination other = (LineDestination) o;
|
||||
if (!nullSafeEquals(this.line, other.line))
|
||||
return false;
|
||||
if (this.destinationId != other.destinationId)
|
|
@ -26,9 +26,9 @@ public final class StationDepartures
|
|||
{
|
||||
public final Location location;
|
||||
public final List<Departure> departures;
|
||||
public final List<Line> lines;
|
||||
public final List<LineDestination> lines;
|
||||
|
||||
public StationDepartures(final Location location, final List<Departure> departures, final List<Line> lines)
|
||||
public StationDepartures(final Location location, final List<Departure> departures, final List<LineDestination> lines)
|
||||
{
|
||||
this.location = location;
|
||||
this.departures = departures;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue