mirror of
https://gitlab.com/oeffi/public-transport-enabler.git
synced 2025-07-15 00:50:31 +00:00
product selection for directions
git-svn-id: https://public-transport-enabler.googlecode.com/svn/trunk@241 0924bc21-9374-b0fa-ee44-9ff1593b38f0
This commit is contained in:
parent
89da3a9bba
commit
dcd673d6f7
21 changed files with 172 additions and 59 deletions
|
@ -33,7 +33,8 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
|
|||
public class LinzProviderLiveTest
|
||||
{
|
||||
private LinzProvider provider = new LinzProvider();
|
||||
|
||||
private static final String ALL_PRODUCTS = "IRSUTBFC";
|
||||
|
||||
@Test
|
||||
public void queryDepartures() throws Exception
|
||||
{
|
||||
|
@ -45,48 +46,49 @@ public class LinzProviderLiveTest
|
|||
public void shortConnection() throws Exception
|
||||
{
|
||||
final QueryConnectionsResult result = provider.queryConnections(LocationType.STATION, "Linz Hauptbahnhof", null, null, LocationType.STATION,
|
||||
"Linz Auwiesen", new Date(), true, WalkSpeed.FAST);
|
||||
"Linz Auwiesen", new Date(), true, ALL_PRODUCTS, WalkSpeed.FAST);
|
||||
System.out.println(result);
|
||||
// final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.linkLater);
|
||||
// System.out.println(moreResult);
|
||||
// final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.linkLater);
|
||||
// System.out.println(moreResult);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void longConnection() throws Exception
|
||||
{
|
||||
final QueryConnectionsResult result = provider.queryConnections(LocationType.STATION, "Linz Auwiesen", null, null, LocationType.STATION,
|
||||
"Linz Hafen", new Date(), true, WalkSpeed.SLOW);
|
||||
"Linz Hafen", new Date(), true, ALL_PRODUCTS, WalkSpeed.SLOW);
|
||||
System.out.println(result);
|
||||
// final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.linkLater);
|
||||
// System.out.println(moreResult);
|
||||
// final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.linkLater);
|
||||
// System.out.println(moreResult);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void connectionBetweenCoordinates() throws Exception
|
||||
{
|
||||
final QueryConnectionsResult result = provider.queryConnections(LocationType.WGS84, "48165238,11577473", null, null, LocationType.WGS84,
|
||||
"47987199,11326532", new Date(), true, WalkSpeed.NORMAL);
|
||||
"47987199,11326532", new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
|
||||
System.out.println(result);
|
||||
// final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.linkLater);
|
||||
// System.out.println(moreResult);
|
||||
// final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.linkLater);
|
||||
// System.out.println(moreResult);
|
||||
}
|
||||
|
||||
@Test public void connectionBetweenCoordinateAndStation() throws Exception
|
||||
@Test
|
||||
public void connectionBetweenCoordinateAndStation() throws Exception
|
||||
{
|
||||
final QueryConnectionsResult result = provider.queryConnections(LocationType.WGS84, "48238341,11478230", null, null, LocationType.ANY,
|
||||
"Ostbahnhof", new Date(), true, WalkSpeed.NORMAL);
|
||||
"Ostbahnhof", new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
|
||||
System.out.println(result);
|
||||
// final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.linkLater);
|
||||
// System.out.println(moreResult);
|
||||
// final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.linkLater);
|
||||
// System.out.println(moreResult);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void connectionBetweenAddresses() throws Exception
|
||||
{
|
||||
final QueryConnectionsResult result = provider.queryConnections(LocationType.ADDRESS, "München, Maximilianstr. 1", null, null,
|
||||
LocationType.ADDRESS, "Starnberg, Jahnstraße 50", new Date(), true, WalkSpeed.NORMAL);
|
||||
LocationType.ADDRESS, "Starnberg, Jahnstraße 50", new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
|
||||
System.out.println(result);
|
||||
// final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.linkLater);
|
||||
// System.out.println(moreResult);
|
||||
// final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.linkLater);
|
||||
// System.out.println(moreResult);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue