diff options
22 files changed, 4783 insertions, 85 deletions
diff --git a/src/plugins/geoservices/nokia/qgeoroutexmlparser.cpp b/src/plugins/geoservices/nokia/qgeoroutexmlparser.cpp index f331c229..9eabc593 100644 --- a/src/plugins/geoservices/nokia/qgeoroutexmlparser.cpp +++ b/src/plugins/geoservices/nokia/qgeoroutexmlparser.cpp @@ -55,6 +55,13 @@ QT_BEGIN_NAMESPACE +QGeoDynamicSpeedInfoContainer::QGeoDynamicSpeedInfoContainer() +: trafficSpeed(0) +, baseSpeed(0) +, trafficTime(0) +, baseTime(0) +{} + QGeoRouteXmlParser::QGeoRouteXmlParser(const QGeoRouteRequest &request) : m_request(request), m_reader(0) @@ -122,10 +129,8 @@ bool QGeoRouteXmlParser::parseRootElement() } } - while (m_reader->readNextStartElement()) { - if (m_reader->name() == "MetaInfo") { - m_reader->skipCurrentElement(); - } else if (m_reader->name() == "Route") { + while (m_reader->readNextStartElement() && !m_reader->hasError()) { + if (m_reader->name() == "Route") { QGeoRoute route; route.setRequest(m_request); if (updateroute) @@ -137,25 +142,23 @@ bool QGeoRouteXmlParser::parseRootElement() //TODO: updated route progress m_reader->skipCurrentElement(); } else { - m_reader->raiseError(QString("Did not expect a child element named \"%1\".").arg( - m_reader->name().toString())); - return false; + m_reader->skipCurrentElement(); } } - return true; + return !m_reader->hasError(); } bool QGeoRouteXmlParser::parseRoute(QGeoRoute *route) { Q_ASSERT(m_reader->isStartElement() && m_reader->name() == "Route"); - maneuvers.clear(); - segments.clear(); + m_maneuvers.clear(); + m_segments.clear(); m_reader->readNext(); - bool succeeded = true; - while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == "Route")) { - if (m_reader->tokenType() == QXmlStreamReader::StartElement && succeeded) { + while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == "Route") && + !m_reader->hasError()) { + if (m_reader->tokenType() == QXmlStreamReader::StartElement) { if (m_reader->name() == "RouteId") { route->setRouteId(m_reader->readElementText()); } @@ -163,32 +166,36 @@ bool QGeoRouteXmlParser::parseRoute(QGeoRoute *route) // succeeded = parseWaypoint(route); //} else if (m_reader->name() == "Mode") { - succeeded = parseMode(route); + if (!parseMode(route)) + return false; } else if (m_reader->name() == "Shape") { QString elementName = m_reader->name().toString(); QList<QGeoCoordinate> path; - succeeded = parseGeoPoints(m_reader->readElementText(), &path, elementName); - if (succeeded) - route->setPath(path); + if (!parseGeoPoints(m_reader->readElementText(), &path, elementName)) + return false; + route->setPath(path); } else if (m_reader->name() == "BoundingBox") { QGeoBoundingBox bounds; - succeeded = parseBoundingBox(bounds); - if (succeeded) - route->setBounds(bounds); + if (!parseBoundingBox(bounds)) + return false; + route->setBounds(bounds); } else if (m_reader->name() == "Leg") { - succeeded = parseLeg(); + if (!parseLeg()) + return false; } else if (m_reader->name() == "Summary") { - succeeded = parseSummary(route); + if (!parseSummary(route)) + return false; } else { m_reader->skipCurrentElement(); } } m_reader->readNext(); } - if (succeeded) - succeeded = postProcessRoute(route); - return succeeded; + if (m_reader->hasError()) + return false; + + return postProcessRoute(route); } bool QGeoRouteXmlParser::parseLeg() @@ -196,13 +203,15 @@ bool QGeoRouteXmlParser::parseLeg() Q_ASSERT(m_reader->isStartElement() && m_reader->name() == "Leg"); m_reader->readNext(); - bool succeeded = true; - while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == "Leg")) { - if (m_reader->tokenType() == QXmlStreamReader::StartElement && succeeded) { + while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == "Leg") && + !m_reader->hasError()) { + if (m_reader->tokenType() == QXmlStreamReader::StartElement) { if (m_reader->name() == "Maneuver") { - succeeded = parseManeuver(); + if (!parseManeuver()) + return false; } else if (m_reader->name() == "Link") { - succeeded = parseLink(); + if (!parseLink()) + return false; } else { m_reader->skipCurrentElement(); } @@ -210,7 +219,7 @@ bool QGeoRouteXmlParser::parseLeg() m_reader->readNext(); } - return succeeded; + return !m_reader->hasError(); } bool QGeoRouteXmlParser::postProcessRoute(QGeoRoute *route) @@ -218,22 +227,22 @@ bool QGeoRouteXmlParser::postProcessRoute(QGeoRoute *route) QList<QGeoRouteSegment> routeSegments; int maneuverIndex = 0; - for (int i = 0; i < segments.count(); ++i) { + for (int i = 0; i < m_segments.count(); ++i) { // In case there is a maneuver in the middle of the list with no // link ID attached, attach it to the next available segment - while ((maneuverIndex < maneuvers.size() - 1) && maneuvers.at(maneuverIndex).toId.isEmpty()) { + while ((maneuverIndex < m_maneuvers.size() - 1) && m_maneuvers.at(maneuverIndex).toId.isEmpty()) { QGeoRouteSegment segment; - segment.setManeuver(maneuvers.at(maneuverIndex).maneuver); + segment.setManeuver(m_maneuvers.at(maneuverIndex).maneuver); QList<QGeoCoordinate> path; // use instruction position as one point segment path - path.append(maneuvers.at(maneuverIndex).maneuver.position()); + path.append(m_maneuvers.at(maneuverIndex).maneuver.position()); segment.setPath(path); routeSegments.append(segment); ++maneuverIndex; } - QGeoRouteSegment segment = segments.at(i).segment; - if ((maneuverIndex < maneuvers.size()) && segments.at(i).id == maneuvers.at(maneuverIndex).toId) { - segment.setManeuver(maneuvers.at(maneuverIndex).maneuver); + QGeoRouteSegment segment = m_segments.at(i).segment; + if ((maneuverIndex < m_maneuvers.size()) && m_segments.at(i).id == m_maneuvers.at(maneuverIndex).toId) { + segment.setManeuver(m_maneuvers.at(maneuverIndex).maneuver); ++maneuverIndex; } routeSegments.append(segment); @@ -242,11 +251,11 @@ bool QGeoRouteXmlParser::postProcessRoute(QGeoRoute *route) // For the final maneuver in the list, make sure to attach it to the very // last segment on the path, this is why we don't process the last // maneuver in the loop above - while (maneuverIndex < maneuvers.size()) { + while (maneuverIndex < m_maneuvers.size()) { QGeoRouteSegment segment; - segment.setManeuver(maneuvers.at(maneuverIndex).maneuver); + segment.setManeuver(m_maneuvers.at(maneuverIndex).maneuver); QList<QGeoCoordinate> path; // use instruction position as one point segment path - path.append(maneuvers.at(maneuverIndex).maneuver.position()); + path.append(m_maneuvers.at(maneuverIndex).maneuver.position()); segment.setPath(path); routeSegments.append(segment); @@ -283,8 +292,8 @@ bool QGeoRouteXmlParser::postProcessRoute(QGeoRoute *route) compactedRouteSegments[i].setNextRouteSegment(compactedRouteSegments.at(i + 1)); } - maneuvers.clear(); - segments.clear(); + m_maneuvers.clear(); + m_segments.clear(); return true; } @@ -319,7 +328,8 @@ bool QGeoRouteXmlParser::parseMode(QGeoRoute *route) Q_ASSERT(m_reader->isStartElement() && m_reader->name() == "Mode"); m_reader->readNext(); - while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == "Mode")) { + while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == "Mode") && + !m_reader->hasError()) { if (m_reader->tokenType() == QXmlStreamReader::StartElement) { if (m_reader->name() == "TransportModes") { QString value = m_reader->readElementText(); @@ -344,20 +354,26 @@ bool QGeoRouteXmlParser::parseMode(QGeoRoute *route) } m_reader->readNext(); } - return true; + return !m_reader->hasError(); } bool QGeoRouteXmlParser::parseSummary(QGeoRoute *route) { + Q_ASSERT(route); Q_ASSERT(m_reader->isStartElement() && m_reader->name() == "Summary"); m_reader->readNext(); - while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == "Summary")) { + double baseTime = -1, trafficTime = -1; + + while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == "Summary") && + !m_reader->hasError()) { if (m_reader->tokenType() == QXmlStreamReader::StartElement) { if (m_reader->name() == "Distance") { route->setDistance(m_reader->readElementText().toDouble()); } else if (m_reader->name() == "TrafficTime") { - route->setTravelTime(m_reader->readElementText().toDouble()); + trafficTime = m_reader->readElementText().toDouble(); + } else if (m_reader->name() == "BaseTime") { + baseTime = m_reader->readElementText().toDouble(); } else { m_reader->skipCurrentElement(); } @@ -365,6 +381,14 @@ bool QGeoRouteXmlParser::parseSummary(QGeoRoute *route) m_reader->readNext(); } + if (m_reader->hasError()) + return false; + + if (trafficTime >= 0) + route->setTravelTime(trafficTime); + else if (baseTime >= 0) + route->setTravelTime(baseTime); + return true; } @@ -373,7 +397,8 @@ bool QGeoRouteXmlParser::parseCoordinates(QGeoCoordinate &coord) QString currentElement = m_reader->name().toString(); m_reader->readNext(); - while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == currentElement)) { + while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == currentElement) && + !m_reader->hasError()) { if (m_reader->tokenType() == QXmlStreamReader::StartElement) { QString name = m_reader->name().toString(); QString value = m_reader->readElementText(); @@ -385,7 +410,7 @@ bool QGeoRouteXmlParser::parseCoordinates(QGeoCoordinate &coord) m_reader->readNext(); } - return true; + return !m_reader->hasError(); } bool QGeoRouteXmlParser::parseManeuver() @@ -400,7 +425,8 @@ bool QGeoRouteXmlParser::parseManeuver() maneuverContainter.id = m_reader->attributes().value("id").toString(); m_reader->readNext(); - while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == "Maneuver")) { + while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == "Maneuver") && + !m_reader->hasError()) { if (m_reader->tokenType() == QXmlStreamReader::StartElement) { if (m_reader->name() == "Position") { QGeoCoordinate coordinates; @@ -447,37 +473,52 @@ bool QGeoRouteXmlParser::parseManeuver() m_reader->readNext(); } - maneuvers.append(maneuverContainter); + if (m_reader->hasError()) + return false; + + m_maneuvers.append(maneuverContainter); return true; } bool QGeoRouteXmlParser::parseLink() { - Q_ASSERT(m_reader->isStartElement() && m_reader->name() == "Link"); + Q_ASSERT(m_reader->isStartElement() && m_reader->name() == QStringLiteral("Link")); m_reader->readNext(); QGeoRouteSegmentContainer segmentContainer; - while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == "Link")) { + while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == QStringLiteral("Link")) && + !m_reader->hasError()) { if (m_reader->tokenType() == QXmlStreamReader::StartElement) { - if (m_reader->name() == "LinkId") { + if (m_reader->name() == QStringLiteral("LinkId")) { segmentContainer.id = m_reader->readElementText(); - } else if (m_reader->name() == "Shape") { + } else if (m_reader->name() == QStringLiteral("Shape")) { QString elementName = m_reader->name().toString(); QList<QGeoCoordinate> path; parseGeoPoints(m_reader->readElementText(), &path, elementName); segmentContainer.segment.setPath(path); - } else if (m_reader->name() == "Length") { + } else if (m_reader->name() == QStringLiteral("Length")) { segmentContainer.segment.setDistance(m_reader->readElementText().toDouble()); - } else if (m_reader->name() == "Maneuver") { + } else if (m_reader->name() == QStringLiteral("Maneuver")) { segmentContainer.maneuverId = m_reader->readElementText(); + } else if (m_reader->name() == QStringLiteral("DynamicSpeedInfo")) { + QGeoDynamicSpeedInfoContainer speedInfo; + if (!parseDynamicSpeedInfo(speedInfo)) + return false; + const double time = speedInfo.trafficTime >= 0 ? speedInfo.trafficTime : speedInfo.baseTime; + if (time >= 0) + segmentContainer.segment.setTravelTime(time); } else { m_reader->skipCurrentElement(); } } m_reader->readNext(); } - segments.append(segmentContainer); + + if (m_reader->hasError()) + return false; + + m_segments.append(segmentContainer); return true; } @@ -525,7 +566,8 @@ bool QGeoRouteXmlParser::parseBoundingBox(QGeoBoundingBox &bounds) QGeoCoordinate br; m_reader->readNext(); - while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == "BoundingBox")) { + while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == "BoundingBox") && + !m_reader->hasError()) { if (m_reader->tokenType() == QXmlStreamReader::StartElement) { if (m_reader->name() == "TopLeft") { QGeoCoordinate coordinates; @@ -542,6 +584,9 @@ bool QGeoRouteXmlParser::parseBoundingBox(QGeoBoundingBox &bounds) m_reader->readNext(); } + if (m_reader->hasError()) + return false; + if (tl.isValid() && br.isValid()) { bounds = QGeoBoundingBox(tl, br); return true; @@ -550,4 +595,30 @@ bool QGeoRouteXmlParser::parseBoundingBox(QGeoBoundingBox &bounds) return false; } +bool QGeoRouteXmlParser::parseDynamicSpeedInfo(QGeoDynamicSpeedInfoContainer &speedInfo) +{ + Q_ASSERT(m_reader->isStartElement() && m_reader->name() == QStringLiteral("DynamicSpeedInfo")); + + m_reader->readNext(); + while (!(m_reader->tokenType() == QXmlStreamReader::EndElement && m_reader->name() == QStringLiteral("DynamicSpeedInfo")) && + !m_reader->hasError()) { + if (m_reader->tokenType() == QXmlStreamReader::StartElement) { + if (m_reader->name() == QStringLiteral("TrafficSpeed")) { + speedInfo.trafficSpeed = m_reader->readElementText().toDouble(); + } else if (m_reader->name() == QStringLiteral("TrafficTime")) { + speedInfo.trafficTime = qRound(m_reader->readElementText().toDouble()); + } else if (m_reader->name() == QStringLiteral("BaseSpeed")) { + speedInfo.baseSpeed = m_reader->readElementText().toDouble(); + } else if (m_reader->name() == QStringLiteral("BaseTime")) { + speedInfo.baseTime = qRound(m_reader->readElementText().toDouble()); + } else { + m_reader->skipCurrentElement(); + } + } + m_reader->readNext(); + } + + return !m_reader->hasError(); +} + QT_END_NAMESPACE diff --git a/src/plugins/geoservices/nokia/qgeoroutexmlparser.h b/src/plugins/geoservices/nokia/qgeoroutexmlparser.h index bc8059d2..c798b233 100644 --- a/src/plugins/geoservices/nokia/qgeoroutexmlparser.h +++ b/src/plugins/geoservices/nokia/qgeoroutexmlparser.h @@ -81,6 +81,18 @@ public: QString maneuverId; }; +class QGeoDynamicSpeedInfoContainer +{ +public: + QGeoDynamicSpeedInfoContainer(); + +public: + double trafficSpeed; + double baseSpeed; + int trafficTime; + int baseTime; +}; + class QGeoRouteXmlParser { public: @@ -105,13 +117,14 @@ private: bool postProcessRoute(QGeoRoute *route); bool parseBoundingBox(QGeoBoundingBox &bounds); + bool parseDynamicSpeedInfo(QGeoDynamicSpeedInfoContainer &speedInfo); QGeoRouteRequest m_request; QXmlStreamReader *m_reader; QList<QGeoRoute> m_results; QString m_errorString; - QList<QGeoManeuverContainer> maneuvers; - QList<QGeoRouteSegmentContainer> segments; + QList<QGeoManeuverContainer> m_maneuvers; + QList<QGeoRouteSegmentContainer> m_segments; }; QT_END_NAMESPACE diff --git a/src/plugins/geoservices/nokia/qgeoserviceproviderplugin_nokia.cpp b/src/plugins/geoservices/nokia/qgeoserviceproviderplugin_nokia.cpp index 43cbb8fc..d061e118 100644 --- a/src/plugins/geoservices/nokia/qgeoserviceproviderplugin_nokia.cpp +++ b/src/plugins/geoservices/nokia/qgeoserviceproviderplugin_nokia.cpp @@ -67,53 +67,85 @@ QGeoServiceProviderFactoryNokia::QGeoServiceProviderFactoryNokia() QGeoServiceProviderFactoryNokia::~QGeoServiceProviderFactoryNokia() {} -QGeocodingManagerEngine* QGeoServiceProviderFactoryNokia::createGeocodingManagerEngine(const QMap<QString, QVariant> ¶meters, +QGeocodingManagerEngine* QGeoServiceProviderFactoryNokia::createGeocodingManagerEngine( + const QVariantMap ¶meters, QGeoServiceProvider::Error *error, QString *errorString) const { informOnceAboutUsageTermsIfNecessary(parameters); - QGeoIntrinsicNetworkAccessManager* networkManager = new QGeoIntrinsicNetworkAccessManager(); - networkManager->configure(parameters); + QGeoNetworkAccessManager* networkManager = 0; + + if (!tryGetNetworkAccessManager(networkManager, parameters)) + { + QGeoIntrinsicNetworkAccessManager* intrinsicNetworkManager = new QGeoIntrinsicNetworkAccessManager(); + intrinsicNetworkManager->configure(parameters); + + networkManager = intrinsicNetworkManager; + } return new QGeocodingManagerEngineNokia(networkManager, parameters, error, errorString); } -QGeoMappingManagerEngine* QGeoServiceProviderFactoryNokia::createMappingManagerEngine(const QMap<QString, QVariant> ¶meters, +QGeoMappingManagerEngine* QGeoServiceProviderFactoryNokia::createMappingManagerEngine( + const QVariantMap ¶meters, QGeoServiceProvider::Error *error, QString *errorString) const { informOnceAboutUsageTermsIfNecessary(parameters); - QGeoIntrinsicNetworkAccessManager* networkManager = new QGeoIntrinsicNetworkAccessManager(); - networkManager->setCustomProxyToken(QStringLiteral("mapping.proxy")); - networkManager->configure(parameters); + QGeoNetworkAccessManager* networkManager = 0; + + if (!tryGetNetworkAccessManager(networkManager, parameters)) + { + QGeoIntrinsicNetworkAccessManager* intrinsicNetworkManager = new QGeoIntrinsicNetworkAccessManager(); + intrinsicNetworkManager->setCustomProxyToken(QStringLiteral("mapping.proxy")); + intrinsicNetworkManager->configure(parameters); + + networkManager = intrinsicNetworkManager; + } return new QGeoTiledMappingManagerEngineNokia(networkManager, parameters, error, errorString); } -QGeoRoutingManagerEngine* QGeoServiceProviderFactoryNokia::createRoutingManagerEngine(const QMap<QString, QVariant> ¶meters, +QGeoRoutingManagerEngine* QGeoServiceProviderFactoryNokia::createRoutingManagerEngine( + const QVariantMap ¶meters, QGeoServiceProvider::Error *error, QString *errorString) const { informOnceAboutUsageTermsIfNecessary(parameters); - QGeoIntrinsicNetworkAccessManager* networkManager = new QGeoIntrinsicNetworkAccessManager(); - networkManager->setCustomProxyToken(QStringLiteral("routing.proxy")); - networkManager->configure(parameters); + QGeoNetworkAccessManager* networkManager = 0; + + if (!tryGetNetworkAccessManager(networkManager, parameters)) + { + QGeoIntrinsicNetworkAccessManager* intrinsicNetworkManager = new QGeoIntrinsicNetworkAccessManager(); + intrinsicNetworkManager->setCustomProxyToken(QStringLiteral("routing.proxy")); + intrinsicNetworkManager->configure(parameters); + + networkManager = intrinsicNetworkManager; + } return new QGeoRoutingManagerEngineNokia(networkManager, parameters, error, errorString); } -QPlaceManagerEngine *QGeoServiceProviderFactoryNokia::createPlaceManagerEngine(const QMap<QString, QVariant> ¶meters, - QGeoServiceProvider::Error *error, - QString *errorString) const +QPlaceManagerEngine *QGeoServiceProviderFactoryNokia::createPlaceManagerEngine( + const QVariantMap ¶meters, + QGeoServiceProvider::Error *error, + QString *errorString) const { informOnceAboutUsageTermsIfNecessary(parameters); - QGeoIntrinsicNetworkAccessManager* networkManager = new QGeoIntrinsicNetworkAccessManager(); - networkManager->setCustomProxyToken(QStringLiteral("places.proxy")); - networkManager->configure(parameters); + QGeoNetworkAccessManager* networkManager = 0; + + if (!tryGetNetworkAccessManager(networkManager, parameters)) + { + QGeoIntrinsicNetworkAccessManager* intrinsicNetworkManager = new QGeoIntrinsicNetworkAccessManager(); + intrinsicNetworkManager->setCustomProxyToken(QStringLiteral("places.proxy")); + intrinsicNetworkManager->configure(parameters); + + networkManager = intrinsicNetworkManager; + } switch (parameters.value(QLatin1String("places.api_version"), 2).toUInt()) { case 1: @@ -126,7 +158,7 @@ QPlaceManagerEngine *QGeoServiceProviderFactoryNokia::createPlaceManagerEngine(c } void QGeoServiceProviderFactoryNokia::informOnceAboutUsageTermsIfNecessary( - const QMap<QString, QVariant> ¶meters) const + const QVariantMap ¶meters) const { if (m_informedAboutUsageTerms) return; @@ -161,6 +193,15 @@ bool QGeoServiceProviderFactoryNokia::isValidParameter(const QString ¶m) return true; } +bool QGeoServiceProviderFactoryNokia::tryGetNetworkAccessManager( + QGeoNetworkAccessManager*& networkManager, + const QVariantMap ¶meters) +{ + networkManager = static_cast<QGeoNetworkAccessManager*>(qvariant_cast<void*>(parameters.value(QStringLiteral("nam")))); + + return networkManager != 0; +} + const QString QGeoServiceProviderFactoryNokia::defaultToken("152022572f0e44e07489c35cd46fa246"); const QString QGeoServiceProviderFactoryNokia::defaultReferer("qtlocationapi"); diff --git a/src/plugins/geoservices/nokia/qgeoserviceproviderplugin_nokia.h b/src/plugins/geoservices/nokia/qgeoserviceproviderplugin_nokia.h index a0ce069d..29f77781 100644 --- a/src/plugins/geoservices/nokia/qgeoserviceproviderplugin_nokia.h +++ b/src/plugins/geoservices/nokia/qgeoserviceproviderplugin_nokia.h @@ -54,6 +54,8 @@ QT_BEGIN_NAMESPACE +class QGeoNetworkAccessManager; + class QGeoServiceProviderFactoryNokia : public QObject, public QGeoServiceProviderFactory { Q_OBJECT @@ -65,16 +67,16 @@ public: QGeoServiceProviderFactoryNokia(); ~QGeoServiceProviderFactoryNokia(); - QGeocodingManagerEngine* createGeocodingManagerEngine(const QMap<QString, QVariant> ¶meters, + QGeocodingManagerEngine* createGeocodingManagerEngine(const QVariantMap ¶meters, QGeoServiceProvider::Error *error, QString *errorString) const; - QGeoMappingManagerEngine* createMappingManagerEngine(const QMap<QString, QVariant> ¶meters, + QGeoMappingManagerEngine* createMappingManagerEngine(const QVariantMap ¶meters, QGeoServiceProvider::Error *error, QString *errorString) const; - QGeoRoutingManagerEngine* createRoutingManagerEngine(const QMap<QString, QVariant> ¶meters, + QGeoRoutingManagerEngine* createRoutingManagerEngine(const QVariantMap ¶meters, QGeoServiceProvider::Error *error, QString *errorString) const; - QPlaceManagerEngine *createPlaceManagerEngine(const QMap<QString, QVariant> ¶meters, + QPlaceManagerEngine *createPlaceManagerEngine(const QVariantMap ¶meters, QGeoServiceProvider::Error *error, QString *errorString) const; @@ -82,8 +84,9 @@ public: static const QString defaultReferer; private: - void informOnceAboutUsageTermsIfNecessary(const QMap<QString, QVariant> ¶meters) const; + void informOnceAboutUsageTermsIfNecessary(const QVariantMap ¶meters) const; static bool isValidParameter(const QString ¶m); + static bool tryGetNetworkAccessManager(QGeoNetworkAccessManager*&, const QVariantMap ¶meters); private: mutable bool m_informedAboutUsageTerms; diff --git a/tests/auto/auto.pro b/tests/auto/auto.pro index 1221f056..cf898848 100644 --- a/tests/auto/auto.pro +++ b/tests/auto/auto.pro @@ -59,7 +59,8 @@ SUBDIRS += geotestplugin \ declarative_core \ qgeoroutexmlparser \ qgeomapcontroller \ - maptype + maptype \ + nokia_services !mac: SUBDIRS += declarative_ui diff --git a/tests/auto/nokia_services/nokia_services.pro b/tests/auto/nokia_services/nokia_services.pro new file mode 100644 index 00000000..2438c30a --- /dev/null +++ b/tests/auto/nokia_services/nokia_services.pro @@ -0,0 +1,2 @@ +TEMPLATE = subdirs +SUBDIRS += routing diff --git a/tests/auto/nokia_services/routing/error-no-route.xml b/tests/auto/nokia_services/routing/error-no-route.xml new file mode 100644 index 00000000..1e1560ae --- /dev/null +++ b/tests/auto/nokia_services/routing/error-no-route.xml @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes"?><ns2:Error xmlns:ns2="http://www.navteq.com/lbsp/Errors/1" type="ApplicationError" subtype="NoRouteFound"><Details>NOROUTE: Request failed</Details></ns2:Error>
\ No newline at end of file diff --git a/tests/auto/nokia_services/routing/invalid-response-half-way-through.xml b/tests/auto/nokia_services/routing/invalid-response-half-way-through.xml new file mode 100644 index 00000000..545954af --- /dev/null +++ b/tests/auto/nokia_services/routing/invalid-response-half-way-through.xml @@ -0,0 +1,150 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes"?> +<rtcr:CalculateRoute xmlns:rtcr="http://www.navteq.com/lbsp/Routing-CalculateRoute/4"> + <Response> + <MetaInfo> + <Timestamp>2012-04-26T14:49:24.451Z</Timestamp> + <AdditionalData key="CurrentTrafficLastUpdate">2012-04-26T14:47:00.025+0000</AdditionalData> + <AdditionalData key="CurrentTrafficElementsCount">5094886</AdditionalData> + <AdditionalData key="LongTermClosureLastUpdate">2012-04-26T14:47:02.481+0000</AdditionalData> + <AdditionalData key="LongTermClosureElementsCount">12015</AdditionalData> + <AdditionalData key="ShortTermClosureLastUpdate">2012-04-26T14:47:02.481+0000</AdditionalData> + <AdditionalData key="ShortTermClosureElementsCount">857</AdditionalData> + <AdditionalData key="Map0">2011Q3</AdditionalData> + <AdditionalData key="Module0">routeserver,9.2-2012.02.20-hotfix6.2.13.1</AdditionalData> + <AdditionalData key="Module0ExecTime">22</AdditionalData> + <AdditionalData key="Service">routing-route-service,6.2.13.1</AdditionalData> + </MetaInfo> + <Route> + <RouteId>REMvaQUAAAB4tdyZCURKQJROJJhqxipAAAAAYAlESkAAAADAasYqQAAAAAAAAPB_AAAAAAAA8H9pqM_8V_SHZp4MKQHNgLOULCerAAEAAICiDCkBAQAAADAnqwABAAAAAADA_wEAAAAAAMD_HY0-82dwsAoDCQ</RouteId> + <Waypoint> + <LinkId>-53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Waypoint> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Mode> + <Type>fastestNow</Type> + <TransportModes>car</TransportModes> + <TrafficMode>enabled</TrafficMode> + </Mode> + <Shape>52.5315361,13.3875332 52.5315094,13.3872204 52.5314484,13.3868303 52.5308685,13.3871498 52.5304298,13.3873901 52.5303993,13.3872299 52.5303612,13.3871202 52.5293198,13.3846502 52.5289383,13.3851404 52.5288315,13.3852901 52.5287399,13.3853998 52.5285416,13.3856297 52.5283089,13.38591 52.5281982,13.3860397 52.5280991,13.3861103 52.5274811,13.3867598 52.5271416,13.3869896 52.5270386,13.3870201 52.5262985,13.3871603 52.5262985,13.38727 52.5262489,13.3874302 52.5261917,13.3877001 52.5260506,13.3882999 52.5259895,13.38873 52.5257187,13.3898802 52.5249786,13.3928604 52.5246773,13.3941345</Shape> + <BoundingBox> + <TopLeft> + <Latitude>52.5315361</Latitude> + <Longitude>13.3846502</Longitude> + </TopLeft> + <BottomRight> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </BottomRight> + </BoundingBox> + <Leg> + <Start> + <LinkId>-53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Start> + <End> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </End> + <Length>1271.0</Length> + <TravelTime>273.9</TravelTime> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M1"> + <Position> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </Position> + <Instruction>Head toward Eichendorffstraße on Invalidenstraße. Go for 150 feet.</Instruction> + <TravelTime>5.2</TravelTime> + <Length>48.0</Length> + <ToLink>-53499799</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M2"> + <Position> + <Latitude>52.5314484</Latitude> + <Longitude>13.3868303</Longitude> + </Position> + <Instruction>Turn left onto Eichendorffstraße. Go for 400 feet.</Instruction> + <TravelTime>47.1</TravelTime> + <Length>119.0</Length> + <ToLink>-780236888</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M3"> + <Position> + <Latitude>52.5304298</Latitude> + <Longitude>13.3873901</Longitude> + </Position> + <Instruction>Turn right onto Schlegelstraße. Go for 0.1 miles.</Instruction> + <TravelTime>55.9</TravelTime> + <Length>223.0</Length> + <ToLink>-53499914</ToLink> + <Direction>right</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M4"> + <Position> + <Latitude>52.5293198</Latitude> + <Longitude>13.3846502</Longitude> + </Position> + <Instruction>Turn left onto Chausseestraße. Go for 0.2 miles.</Instruction> + <TravelTime>68.0</TravelTime> + <Length>286.0</Length> + <ToLink>-749446557</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M5"> + <Position> + <Latitude>52.5271416</Latitude> + <Longitude>13.3869896</Longitude> + </Position> + <Instruction>Continue on Friedrichstraße, Oranienburger Tor. Go for 300 feet.</Instruction> + <TravelTime>20.1</TravelTime> + <Length>93.0</Length> + <ToLink>-572708773</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M6"> + <Position> + <Latitude>52.5262985</Latitude> + <Longitude>13.3871603</Longitude> + </Position> + <Instruction>Turn left onto Oranienburger Straße. Go for 0.3 miles.</Instruction> + <TravelTime>77.6</TravelTime> + <Length>502.0</Length> + <ToLink>+812293299</ToLink> + <Direction>left</Direc
\ No newline at end of file diff --git a/tests/auto/nokia_services/routing/invalid-response-no-calculateroute-tag.xml b/tests/auto/nokia_services/routing/invalid-response-no-calculateroute-tag.xml new file mode 100644 index 00000000..5e3e55e1 --- /dev/null +++ b/tests/auto/nokia_services/routing/invalid-response-no-calculateroute-tag.xml @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes"?> diff --git a/tests/auto/nokia_services/routing/invalid-response-no-route-tag.xml b/tests/auto/nokia_services/routing/invalid-response-no-route-tag.xml new file mode 100644 index 00000000..322f1a17 --- /dev/null +++ b/tests/auto/nokia_services/routing/invalid-response-no-route-tag.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes"?> +<rtcr:CalculateRoute xmlns:rtcr="http://www.navteq.com/lbsp/Routing-CalculateRoute/4"> + <Response> + <MetaInfo> + <Timestamp>2012-04-26T14:49:24.451Z</Timestamp> + <AdditionalData key="CurrentTrafficLastUpdate">2012-04-26T14:47:00.025+0000</AdditionalData> + <AdditionalData key="CurrentTrafficElementsCount">5094886</AdditionalData> + <AdditionalData key="LongTermClosureLastUpdate">2012-04-26T14:47:02.481+0000</AdditionalData> + <AdditionalData key="LongTermClosureElementsCount">12015</AdditionalData> + <AdditionalData key="ShortTermClosureLastUpdate">2012-04-26T14:47:02.481+0000</AdditionalData> + <AdditionalData key="ShortTermClosureElementsCount">857</AdditionalData> + <AdditionalData key="Map0">2011Q3</AdditionalData> + <AdditionalData key="Module0">routeserver,9.2-2012.02.20-hotfix6.2.13.1</AdditionalData> + <AdditionalData key="Module0ExecTime">22</AdditionalData> + <AdditionalData key="Service">routing-route-service,6.2.13.1</AdditionalData> + </MetaInfo> + </Response> +</rtcr:CalculateRoute>
\ No newline at end of file diff --git a/tests/auto/nokia_services/routing/invalid-response-trash.xml b/tests/auto/nokia_services/routing/invalid-response-trash.xml Binary files differnew file mode 100644 index 00000000..ec6a3ae4 --- /dev/null +++ b/tests/auto/nokia_services/routing/invalid-response-trash.xml diff --git a/tests/auto/nokia_services/routing/littered-with-new-tags.xml b/tests/auto/nokia_services/routing/littered-with-new-tags.xml new file mode 100644 index 00000000..40e83887 --- /dev/null +++ b/tests/auto/nokia_services/routing/littered-with-new-tags.xml @@ -0,0 +1,648 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes"?> +<rtcr:CalculateRoute xmlns:rtcr="http://www.navteq.com/lbsp/Routing-CalculateRoute/4"> + <!-- don't put anything before Response tag --> + <Response> + <RandomNew2 /> + <MetaInfo> + <RandomNew3 /> + <Timestamp>2012-04-26T14:49:24.451Z</Timestamp> + <RandomNew3 /> + <AdditionalData key="CurrentTrafficLastUpdate">2012-04-26T14:47:00.025+0000</AdditionalData> + <AdditionalData key="CurrentTrafficElementsCount">5094886</AdditionalData> + <AdditionalData key="LongTermClosureLastUpdate">2012-04-26T14:47:02.481+0000</AdditionalData> + <AdditionalData key="LongTermClosureElementsCount">12015</AdditionalData> + <AdditionalData key="ShortTermClosureLastUpdate">2012-04-26T14:47:02.481+0000</AdditionalData> + <AdditionalData key="ShortTermClosureElementsCount">857</AdditionalData> + <AdditionalData key="Map0">2011Q3</AdditionalData> + <AdditionalData key="Module0">routeserver,9.2-2012.02.20-hotfix6.2.13.1</AdditionalData> + <AdditionalData key="Module0ExecTime">22</AdditionalData> + <AdditionalData key="Service">routing-route-service,6.2.13.1</AdditionalData> + </MetaInfo> + <FooooooBaaaaaarrr> + <Karl> + <Heinz /> + </Karl> + </FooooooBaaaaaarrr> + <Route> + <RandomNasdfasdfew2 /> + <RouteId>REMvaQUAAAB4tdyZCURKQJROJJhqxipAAAAAYAlESkAAAADAasYqQAAAAAAAAPB_AAAAAAAA8H9pqM_8V_SHZp4MKQHNgLOULCerAAEAAICiDCkBAQAAADAnqwABAAAAAADA_wEAAAAAAMD_HY0-82dwsAoDCQ</RouteId> + <Waypoint> + <BlinkId></BlinkId> + <LinkId>-53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + <Altitude>32</Altitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Waypoint> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Mode> + <Type>fastestNow</Type> + <TransportModes>car</TransportModes> + <TrafficMode>enabled</TrafficMode> + </Mode> + <Shape>52.5315361,13.3875332 52.5315094,13.3872204 52.5314484,13.3868303 52.5308685,13.3871498 52.5304298,13.3873901 52.5303993,13.3872299 52.5303612,13.3871202 52.5293198,13.3846502 52.5289383,13.3851404 52.5288315,13.3852901 52.5287399,13.3853998 52.5285416,13.3856297 52.5283089,13.38591 52.5281982,13.3860397 52.5280991,13.3861103 52.5274811,13.3867598 52.5271416,13.3869896 52.5270386,13.3870201 52.5262985,13.3871603 52.5262985,13.38727 52.5262489,13.3874302 52.5261917,13.3877001 52.5260506,13.3882999 52.5259895,13.38873 52.5257187,13.3898802 52.5249786,13.3928604 52.5246773,13.3941345</Shape> + <BoundingBox> + <TopLeft> + <Latitude>52.5315361</Latitude> + <Longitude>13.3846502</Longitude> + </TopLeft> + <BottomRight> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </BottomRight> + </BoundingBox> + <Arm> + <Hand> + <Length value="232" /> + </Hand> + </Arm> + <Leg> + <Start> + <LinkId>-53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Start> + <End> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </End> + <Length>1271.0</Length> + <TravelTime>273.9</TravelTime> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M1"> + <Id>232</Id> + <Position> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </Position> + <Instruction>Head toward Eichendorffstraße on Invalidenstraße. Go for 150 feet.</Instruction> + <TravelTime>5.2</TravelTime> + <Length>48.0</Length> + <ToLink>-53499799</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M2"> + <Position> + <Latitude>52.5314484</Latitude> + <Longitude>13.3868303</Longitude> + </Position> + <Instruction>Turn left onto Eichendorffstraße. Go for 400 feet.</Instruction> + <TravelTime>47.1</TravelTime> + <Length>119.0</Length> + <ToLink>-780236888</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M3"> + <Position> + <Latitude>52.5304298</Latitude> + <Longitude>13.3873901</Longitude> + </Position> + <Instruction>Turn right onto Schlegelstraße. Go for 0.1 miles.</Instruction> + <TravelTime>55.9</TravelTime> + <Length>223.0</Length> + <ToLink>-53499914</ToLink> + <Direction>right</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M4"> + <Position> + <Latitude>52.5293198</Latitude> + <Longitude>13.3846502</Longitude> + </Position> + <Instruction>Turn left onto Chausseestraße. Go for 0.2 miles.</Instruction> + <TravelTime>68.0</TravelTime> + <Length>286.0</Length> + <ToLink>-749446557</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M5"> + <Position> + <Latitude>52.5271416</Latitude> + <Longitude>13.3869896</Longitude> + </Position> + <Instruction>Continue on Friedrichstraße, Oranienburger Tor. Go for 300 feet.</Instruction> + <TravelTime>20.1</TravelTime> + <Length>93.0</Length> + <ToLink>-572708773</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M6"> + <Position> + <Latitude>52.5262985</Latitude> + <Longitude>13.3871603</Longitude> + </Position> + <Instruction>Turn left onto Oranienburger Straße. Go for 0.3 miles.</Instruction> + <TravelTime>77.6</TravelTime> + <Length>502.0</Length> + <ToLink>+812293299</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M7"> + <Position> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </Position> + <Instruction>Your destination on Oranienburger Straße is on the right. The trip takes 0.8 miles and 5 mins.</Instruction> + <TravelTime>0.0</TravelTime> + <Length>0.0</Length> + <Direction>forward</Direction> + </Maneuver> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499799</LinkId> + <Shape>52.5315361,13.3875332 52.5315094,13.3872204 52.5314484,13.3868303</Shape> + <Length>48.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>9.17</TrafficSpeed> + <TrafficTime>5.2</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>4.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Invalidenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Invalidenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-780236888</LinkId> + <Shape>52.5314484,13.3868303 52.5308685,13.3871498</Shape> + <Length>68.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.0</TrafficSpeed> + <TrafficTime>13.6</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>9.8</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Eichendorffstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Eichendorffstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-780236887</LinkId> + <Shape>52.5308685,13.3871498 52.5304298,13.3873901</Shape> + <Length>51.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.28</TrafficSpeed> + <TrafficTime>9.7</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>7.3</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Eichendorffstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Eichendorffstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499914</LinkId> + <Shape>52.5304298,13.3873901 52.5303993,13.3872299 52.5303612,13.3871202 52.5293198,13.3846502</Shape> + <Length>223.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.28</TrafficSpeed> + <TrafficTime>42.3</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>32.1</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Schlegelstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Schlegelstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-749446557</LinkId> + <Shape>52.5293198,13.3846502 52.5289383,13.3851404</Shape> + <Length>53.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>4.9</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>5.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-781763170</LinkId> + <Shape>52.5289383,13.3851404 52.5288315,13.3852901</Shape> + <Length>15.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>1.4</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>1.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-781763169</LinkId> + <Shape>52.5288315,13.3852901 52.5287399,13.3853998</Shape> + <Length>12.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>1.1</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>1.2</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-781763164</LinkId> + <Shape>52.5287399,13.3853998 52.5285416,13.3856297</Shape> + <Length>26.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>2.4</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>2.7</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-781763163</LinkId> + <Shape>52.5285416,13.3856297 52.5283089,13.38591</Shape> + <Length>32.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>3.0</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>3.3</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-749446551</LinkId> + <Shape>52.5283089,13.38591 52.5281982,13.3860397</Shape> + <Length>15.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>1.4</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>1.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572708771</LinkId> + <Shape>52.5281982,13.3860397 52.5280991,13.3861103 52.5274811,13.3867598</Shape> + <Length>93.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>8.6</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>9.6</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53500039</LinkId> + <Shape>52.5274811,13.3867598 52.5271416,13.3869896</Shape> + <Length>40.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>3.7</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>4.1</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572708773</LinkId> + <Shape>52.5271416,13.3869896 52.5270386,13.3870201</Shape> + <Length>11.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.28</TrafficSpeed> + <TrafficTime>1.1</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>1.1</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Friedrichstraße, Oranienburger Tor</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Friedrichstraße, Oranienburger Tor</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572708772</LinkId> + <Shape>52.5270386,13.3870201 52.5262985,13.3871603</Shape> + <Length>82.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.28</TrafficSpeed> + <TrafficTime>8.0</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>8.4</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Friedrichstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Friedrichstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+812293299</LinkId> + <Shape>52.5262985,13.3871603 52.5262985,13.38727</Shape> + <Length>7.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>3.61</TrafficSpeed> + <TrafficTime>1.9</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>0.7</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-733054082</LinkId> + <Shape>52.5262985,13.38727 52.5262489,13.3874302</Shape> + <Length>12.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>11.39</TrafficSpeed> + <TrafficTime>1.1</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>1.2</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-733054081</LinkId> + <Shape>52.5262489,13.3874302 52.5261917,13.3877001</Shape> + <Length>19.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>11.39</TrafficSpeed> + <TrafficTime>1.7</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>2.0</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572680644</LinkId> + <Shape>52.5261917,13.3877001 52.5260506,13.3882999</Shape> + <Length>43.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.0</TrafficSpeed> + <TrafficTime>4.3</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>4.4</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572680642</LinkId> + <Shape>52.5260506,13.3882999 52.5259895,13.38873</Shape> + <Length>29.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>11.39</TrafficSpeed> + <TrafficTime>2.5</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>3.0</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572680640</LinkId> + <Shape>52.5259895,13.38873 52.5257187,13.3898802</Shape> + <Length>83.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>11.11</TrafficSpeed> + <TrafficTime>7.5</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>8.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53501098</LinkId> + <Shape>52.5257187,13.3898802 52.5249786,13.3928604</Shape> + <Length>217.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>8.33</TrafficSpeed> + <TrafficTime>26.0</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>22.3</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53501113</LinkId> + <Shape>52.5249786,13.3928604 52.5246773,13.3941345</Shape> + <Length>92.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>8.61</TrafficSpeed> + <TrafficTime>10.7</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>9.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + </Leg> + <Summary> + <Xyz>1271.0</Xyz> + <Distance>1271.0</Distance> + <BaseTime>243.0</BaseTime> + <RandoasdfasfmNew2 /> + </Summary> + </Route> + </Response> +</rtcr:CalculateRoute>
\ No newline at end of file diff --git a/tests/auto/nokia_services/routing/multiple-routes-in-response.xml b/tests/auto/nokia_services/routing/multiple-routes-in-response.xml new file mode 100644 index 00000000..12a4d214 --- /dev/null +++ b/tests/auto/nokia_services/routing/multiple-routes-in-response.xml @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes"?><rtcr:CalculateRoute xmlns:rtcr="http://www.navteq.com/lbsp/Routing-CalculateRoute/4"><Response><MetaInfo><Timestamp>2012-04-26T15:01:07.170Z</Timestamp><AdditionalData key="CurrentTrafficLastUpdate">2012-04-26T14:59:00.073+0000</AdditionalData><AdditionalData key="CurrentTrafficElementsCount">5094982</AdditionalData><AdditionalData key="LongTermClosureLastUpdate">2012-04-26T14:59:02.647+0000</AdditionalData><AdditionalData key="LongTermClosureElementsCount">12223</AdditionalData><AdditionalData key="ShortTermClosureLastUpdate">2012-04-26T14:59:02.647+0000</AdditionalData><AdditionalData key="ShortTermClosureElementsCount">703</AdditionalData><AdditionalData key="Map0">2011Q3</AdditionalData><AdditionalData key="Module0">routeserver,9.2-2012.02.20-hotfix6.2.13.1</AdditionalData><AdditionalData key="Module0ExecTime">20</AdditionalData><AdditionalData key="Service">routing-route-service,6.2.13.1</AdditionalData></MetaInfo><Route><RouteId>REMvFQUAAAB4tdyZCURKQJROJJhqxipAAAAAYAlESkAAAADAasYqQAAAAAAAAPB_AAAAAAAA8H-XVzADV_SHZp4MKQHNgLOULCerAAEAAICiDCkBAQAAADAnqwABAAAAAADA_wEAAAAAAMD_HY0-83dwYQCu</RouteId><Waypoint><LinkId>+53499799</LinkId><MappedPosition><Latitude>52.5315361</Latitude><Longitude>13.3875332</Longitude></MappedPosition><OriginalPosition><Latitude>52.531543</Latitude><Longitude>13.387532</Longitude></OriginalPosition><Type>stopOver</Type></Waypoint><Waypoint><LinkId>-53501113</LinkId><MappedPosition><Latitude>52.5246773</Latitude><Longitude>13.3941345</Longitude></MappedPosition><OriginalPosition><Latitude>52.524646</Latitude><Longitude>13.394128</Longitude></OriginalPosition><Type>stopOver</Type></Waypoint><Mode><Type>scenic</Type><TransportModes>car</TransportModes></Mode><Shape>52.5315361,13.3875332 52.5315819,13.3880997 52.5316582,13.3889303 52.5317612,13.3896999 52.5316315,13.3899002 52.5302505,13.3916502 52.5300598,13.3919001 52.5286217,13.3937197 52.5285416,13.3938799 52.5282288,13.3924398 52.5276604,13.3927898 52.5274887,13.39293 52.5264091,13.3935404 52.5262985,13.3935604 52.5254402,13.3931103 52.5249786,13.3928604 52.5246773,13.3941345</Shape><BoundingBox><TopLeft><Latitude>52.5317612</Latitude><Longitude>13.3875332</Longitude></TopLeft><BottomRight><Latitude>52.5246773</Latitude><Longitude>13.3941345</Longitude></BottomRight></BoundingBox><Leg><Start><LinkId>+53499799</LinkId><MappedPosition><Latitude>52.5315361</Latitude><Longitude>13.3875332</Longitude></MappedPosition><OriginalPosition><Latitude>52.531543</Latitude><Longitude>13.387532</Longitude></OriginalPosition><Type>stopOver</Type></Start><End><LinkId>-53501113</LinkId><MappedPosition><Latitude>52.5246773</Latitude><Longitude>13.3941345</Longitude></MappedPosition><OriginalPosition><Latitude>52.524646</Latitude><Longitude>13.394128</Longitude></OriginalPosition><Type>stopOver</Type></End><Length>1177.0</Length><TravelTime>237.7</TravelTime><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M1"><Position><Latitude>52.5315361</Latitude><Longitude>13.3875332</Longitude></Position><Instruction>Head toward Borsigstraße on Invalidenstraße. Go for 500 feet.</Instruction><TravelTime>15.2</TravelTime><Length>148.0</Length><ToLink>+53499799</ToLink><Direction>forward</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M2"><Position><Latitude>52.5317612</Latitude><Longitude>13.3896999</Longitude></Position><Instruction>Turn right onto Gartenstraße. Go for 0.3 miles.</Instruction><TravelTime>90.8</TravelTime><Length>454.0</Length><ToLink>-811854188</ToLink><Direction>right</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M3"><Position><Latitude>52.5285416</Latitude><Longitude>13.3938799</Longitude></Position><Instruction>Turn right onto Torstraße. Go for 350 feet.</Instruction><TravelTime>28.4</TravelTime><Length>103.0</Length><ToLink>-53499981</ToLink><Direction>right</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M4"><Position><Latitude>52.5282288</Latitude><Longitude>13.3924398</Longitude></Position><Instruction>Turn left onto Tucholskystraße. Go for 0.2 miles.</Instruction><TravelTime>72.4</TravelTime><Length>380.0</Length><ToLink>-53500024</ToLink><Direction>left</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M5"><Position><Latitude>52.5249786</Latitude><Longitude>13.3928604</Longitude></Position><Instruction>Turn left onto Oranienburger Straße. Go for 300 feet.</Instruction><TravelTime>30.9</TravelTime><Length>92.0</Length><ToLink>-53501113</ToLink><Direction>left</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M6"><Position><Latitude>52.5246773</Latitude><Longitude>13.3941345</Longitude></Position><Instruction>Your destination on Oranienburger Straße is on the right. The trip takes 0.7 miles and 4 mins.</Instruction><TravelTime>0.0</TravelTime><Length>0.0</Length><Direction>forward</Direction></Maneuver><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>+53499799</LinkId><Shape>52.5315361,13.3875332 52.5315819,13.3880997</Shape><Length>38.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>7.77</TrafficSpeed><TrafficTime>4.9</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>3.9</BaseTime></DynamicSpeedInfo><Address><Label>Invalidenstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Invalidenstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>+53499788</LinkId><Shape>52.5315819,13.3880997 52.5316582,13.3889303 52.5317612,13.3896999</Shape><Length>110.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>7.77</TrafficSpeed><TrafficTime>14.1</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>11.3</BaseTime></DynamicSpeedInfo><Address><Label>Invalidenstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Invalidenstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-811854188</LinkId><Shape>52.5317612,13.3896999 52.5316315,13.3899002</Shape><Length>19.0</Length><DynamicSpeedInfo><TrafficSpeed>5.0</TrafficSpeed><TrafficTime>3.8</TrafficTime><BaseSpeed>6.94</BaseSpeed><BaseTime>2.7</BaseTime></DynamicSpeedInfo><Address><Label>Gartenstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Gartenstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-811854187</LinkId><Shape>52.5316315,13.3899002 52.5302505,13.3916502</Shape><Length>193.0</Length><DynamicSpeedInfo><TrafficSpeed>5.28</TrafficSpeed><TrafficTime>36.6</TrafficTime><BaseSpeed>6.94</BaseSpeed><BaseTime>27.8</BaseTime></DynamicSpeedInfo><Address><Label>Gartenstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Gartenstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53499878</LinkId><Shape>52.5302505,13.3916502 52.5300598,13.3919001</Shape><Length>27.0</Length><DynamicSpeedInfo><TrafficSpeed>5.28</TrafficSpeed><TrafficTime>5.1</TrafficTime><BaseSpeed>6.94</BaseSpeed><BaseTime>3.9</BaseTime></DynamicSpeedInfo><Address><Label>Gartenstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Gartenstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53499960</LinkId><Shape>52.5300598,13.3919001 52.5286217,13.3937197 52.5285416,13.3938799</Shape><Length>215.0</Length><DynamicSpeedInfo><TrafficSpeed>5.28</TrafficSpeed><TrafficTime>40.7</TrafficTime><BaseSpeed>6.94</BaseSpeed><BaseTime>31.0</BaseTime></DynamicSpeedInfo><Address><Label>Gartenstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Gartenstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53499981</LinkId><Shape>52.5285416,13.3938799 52.5282288,13.3924398</Shape><Length>103.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>8.33</TrafficSpeed><TrafficTime>12.4</TrafficTime><BaseSpeed>6.94</BaseSpeed><BaseTime>14.8</BaseTime></DynamicSpeedInfo><Address><Label>Torstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Torstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53500024</LinkId><Shape>52.5282288,13.3924398 52.5276604,13.3927898 52.5274887,13.39293</Shape><Length>88.0</Length><DynamicSpeedInfo><TrafficSpeed>4.72</TrafficSpeed><TrafficTime>18.6</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>9.1</BaseTime></DynamicSpeedInfo><Address><Label>Tucholskystraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Tucholskystraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53500091</LinkId><Shape>52.5274887,13.39293 52.5264091,13.3935404</Shape><Length>126.0</Length><DynamicSpeedInfo><TrafficSpeed>4.72</TrafficSpeed><TrafficTime>26.7</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>13.0</BaseTime></DynamicSpeedInfo><Address><Label>Tucholskystraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Tucholskystraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-844906239</LinkId><Shape>52.5264091,13.3935404 52.5262985,13.3935604 52.5254402,13.3931103</Shape><Length>112.0</Length><DynamicSpeedInfo><TrafficSpeed>4.17</TrafficSpeed><TrafficTime>26.9</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>11.5</BaseTime></DynamicSpeedInfo><Address><Label>Tucholskystraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Tucholskystraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-844906238</LinkId><Shape>52.5254402,13.3931103 52.5249786,13.3928604</Shape><Length>54.0</Length><DynamicSpeedInfo><TrafficSpeed>3.89</TrafficSpeed><TrafficTime>13.9</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>5.6</BaseTime></DynamicSpeedInfo><Address><Label>Tucholskystraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Tucholskystraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53501113</LinkId><Shape>52.5249786,13.3928604 52.5246773,13.3941345</Shape><Length>92.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>8.61</TrafficSpeed><TrafficTime>10.7</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>9.5</BaseTime></DynamicSpeedInfo><Address><Label>Oranienburger Straße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Oranienburger Straße</Street></Address></Link></Leg><Summary><Distance>1177.0</Distance><TrafficTime>309.0</TrafficTime><BaseTime>237.0</BaseTime></Summary></Route><Route><RouteId>REMvaQUAAAB4tdyZCURKQJROJJhqxipAAAAAYAlESkAAAADAasYqQAAAAAAAAPB_AAAAAAAA8H9pqM_8V_SHZp4MKQHNgLOULCerAAEAAICiDCkBAQAAADAnqwABAAAAAADA_wEAAAAAAMD_HY0-82dwsAoDCQ</RouteId><Waypoint><LinkId>-53499799</LinkId><MappedPosition><Latitude>52.5315361</Latitude><Longitude>13.3875332</Longitude></MappedPosition><OriginalPosition><Latitude>52.531543</Latitude><Longitude>13.387532</Longitude></OriginalPosition><Type>stopOver</Type></Waypoint><Waypoint><LinkId>-53501113</LinkId><MappedPosition><Latitude>52.5246773</Latitude><Longitude>13.3941345</Longitude></MappedPosition><OriginalPosition><Latitude>52.524646</Latitude><Longitude>13.394128</Longitude></OriginalPosition><Type>stopOver</Type></Waypoint><Mode><Type>fastestNow</Type><TransportModes>car</TransportModes><TrafficMode>enabled</TrafficMode></Mode><Shape>52.5315361,13.3875332 52.5315094,13.3872204 52.5314484,13.3868303 52.5308685,13.3871498 52.5304298,13.3873901 52.5303993,13.3872299 52.5303612,13.3871202 52.5293198,13.3846502 52.5289383,13.3851404 52.5288315,13.3852901 52.5287399,13.3853998 52.5285416,13.3856297 52.5283089,13.38591 52.5281982,13.3860397 52.5280991,13.3861103 52.5274811,13.3867598 52.5271416,13.3869896 52.5270386,13.3870201 52.5262985,13.3871603 52.5262985,13.38727 52.5262489,13.3874302 52.5261917,13.3877001 52.5260506,13.3882999 52.5259895,13.38873 52.5257187,13.3898802 52.5249786,13.3928604 52.5246773,13.3941345</Shape><BoundingBox><TopLeft><Latitude>52.5315361</Latitude><Longitude>13.3846502</Longitude></TopLeft><BottomRight><Latitude>52.5246773</Latitude><Longitude>13.3941345</Longitude></BottomRight></BoundingBox><Leg><Start><LinkId>-53499799</LinkId><MappedPosition><Latitude>52.5315361</Latitude><Longitude>13.3875332</Longitude></MappedPosition><OriginalPosition><Latitude>52.531543</Latitude><Longitude>13.387532</Longitude></OriginalPosition><Type>stopOver</Type></Start><End><LinkId>-53501113</LinkId><MappedPosition><Latitude>52.5246773</Latitude><Longitude>13.3941345</Longitude></MappedPosition><OriginalPosition><Latitude>52.524646</Latitude><Longitude>13.394128</Longitude></OriginalPosition><Type>stopOver</Type></End><Length>1271.0</Length><TravelTime>270.0</TravelTime><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M7"><Position><Latitude>52.5315361</Latitude><Longitude>13.3875332</Longitude></Position><Instruction>Head toward Eichendorffstraße on Invalidenstraße. Go for 150 feet.</Instruction><TravelTime>5.2</TravelTime><Length>48.0</Length><ToLink>-53499799</ToLink><Direction>forward</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M8"><Position><Latitude>52.5314484</Latitude><Longitude>13.3868303</Longitude></Position><Instruction>Turn left onto Eichendorffstraße. Go for 400 feet.</Instruction><TravelTime>47.1</TravelTime><Length>119.0</Length><ToLink>-780236888</ToLink><Direction>left</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M9"><Position><Latitude>52.5304298</Latitude><Longitude>13.3873901</Longitude></Position><Instruction>Turn right onto Schlegelstraße. Go for 0.1 miles.</Instruction><TravelTime>55.9</TravelTime><Length>223.0</Length><ToLink>-53499914</ToLink><Direction>right</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M10"><Position><Latitude>52.5293198</Latitude><Longitude>13.3846502</Longitude></Position><Instruction>Turn left onto Chausseestraße. Go for 0.2 miles.</Instruction><TravelTime>64.9</TravelTime><Length>286.0</Length><ToLink>-749446557</ToLink><Direction>left</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M11"><Position><Latitude>52.5271416</Latitude><Longitude>13.3869896</Longitude></Position><Instruction>Continue on Friedrichstraße, Oranienburger Tor. Go for 300 feet.</Instruction><TravelTime>19.3</TravelTime><Length>93.0</Length><ToLink>-572708773</ToLink><Direction>forward</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M12"><Position><Latitude>52.5262985</Latitude><Longitude>13.3871603</Longitude></Position><Instruction>Turn left onto Oranienburger Straße. Go for 0.3 miles.</Instruction><TravelTime>77.6</TravelTime><Length>502.0</Length><ToLink>+812293299</ToLink><Direction>left</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M13"><Position><Latitude>52.5246773</Latitude><Longitude>13.3941345</Longitude></Position><Instruction>Your destination on Oranienburger Straße is on the right. The trip takes 0.8 miles and 5 mins.</Instruction><TravelTime>0.0</TravelTime><Length>0.0</Length><Direction>forward</Direction></Maneuver><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53499799</LinkId><Shape>52.5315361,13.3875332 52.5315094,13.3872204 52.5314484,13.3868303</Shape><Length>48.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>9.17</TrafficSpeed><TrafficTime>5.2</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>4.9</BaseTime></DynamicSpeedInfo><Address><Label>Invalidenstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Invalidenstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-780236888</LinkId><Shape>52.5314484,13.3868303 52.5308685,13.3871498</Shape><Length>68.0</Length><DynamicSpeedInfo><TrafficSpeed>5.0</TrafficSpeed><TrafficTime>13.6</TrafficTime><BaseSpeed>6.94</BaseSpeed><BaseTime>9.8</BaseTime></DynamicSpeedInfo><Address><Label>Eichendorffstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Eichendorffstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-780236887</LinkId><Shape>52.5308685,13.3871498 52.5304298,13.3873901</Shape><Length>51.0</Length><DynamicSpeedInfo><TrafficSpeed>5.28</TrafficSpeed><TrafficTime>9.7</TrafficTime><BaseSpeed>6.94</BaseSpeed><BaseTime>7.3</BaseTime></DynamicSpeedInfo><Address><Label>Eichendorffstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Eichendorffstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53499914</LinkId><Shape>52.5304298,13.3873901 52.5303993,13.3872299 52.5303612,13.3871202 52.5293198,13.3846502</Shape><Length>223.0</Length><DynamicSpeedInfo><TrafficSpeed>5.28</TrafficSpeed><TrafficTime>42.3</TrafficTime><BaseSpeed>6.94</BaseSpeed><BaseTime>32.1</BaseTime></DynamicSpeedInfo><Address><Label>Schlegelstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Schlegelstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-749446557</LinkId><Shape>52.5293198,13.3846502 52.5289383,13.3851404</Shape><Length>53.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>10.83</TrafficSpeed><TrafficTime>4.9</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>5.5</BaseTime></DynamicSpeedInfo><Address><Label>Chausseestraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Chausseestraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-781763170</LinkId><Shape>52.5289383,13.3851404 52.5288315,13.3852901</Shape><Length>15.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>10.83</TrafficSpeed><TrafficTime>1.4</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>1.5</BaseTime></DynamicSpeedInfo><Address><Label>Chausseestraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Chausseestraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-781763169</LinkId><Shape>52.5288315,13.3852901 52.5287399,13.3853998</Shape><Length>12.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>10.83</TrafficSpeed><TrafficTime>1.1</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>1.2</BaseTime></DynamicSpeedInfo><Address><Label>Chausseestraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Chausseestraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-781763164</LinkId><Shape>52.5287399,13.3853998 52.5285416,13.3856297</Shape><Length>26.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>10.83</TrafficSpeed><TrafficTime>2.4</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>2.7</BaseTime></DynamicSpeedInfo><Address><Label>Chausseestraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Chausseestraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-781763163</LinkId><Shape>52.5285416,13.3856297 52.5283089,13.38591</Shape><Length>32.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>10.83</TrafficSpeed><TrafficTime>3.0</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>3.3</BaseTime></DynamicSpeedInfo><Address><Label>Chausseestraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Chausseestraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-749446551</LinkId><Shape>52.5283089,13.38591 52.5281982,13.3860397</Shape><Length>15.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>10.83</TrafficSpeed><TrafficTime>1.4</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>1.5</BaseTime></DynamicSpeedInfo><Address><Label>Chausseestraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Chausseestraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-572708771</LinkId><Shape>52.5281982,13.3860397 52.5280991,13.3861103 52.5274811,13.3867598</Shape><Length>93.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>10.83</TrafficSpeed><TrafficTime>8.6</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>9.6</BaseTime></DynamicSpeedInfo><Address><Label>Chausseestraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Chausseestraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53500039</LinkId><Shape>52.5274811,13.3867598 52.5271416,13.3869896</Shape><Length>40.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>10.83</TrafficSpeed><TrafficTime>3.7</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>4.1</BaseTime></DynamicSpeedInfo><Address><Label>Chausseestraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Chausseestraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-572708773</LinkId><Shape>52.5271416,13.3869896 52.5270386,13.3870201</Shape><Length>11.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>10.28</TrafficSpeed><TrafficTime>1.1</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>1.1</BaseTime></DynamicSpeedInfo><Address><Label>Friedrichstraße, Oranienburger Tor</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Friedrichstraße, Oranienburger Tor</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-572708772</LinkId><Shape>52.5270386,13.3870201 52.5262985,13.3871603</Shape><Length>82.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>10.28</TrafficSpeed><TrafficTime>8.0</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>8.4</BaseTime></DynamicSpeedInfo><Address><Label>Friedrichstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Friedrichstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>+812293299</LinkId><Shape>52.5262985,13.3871603 52.5262985,13.38727</Shape><Length>7.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>3.61</TrafficSpeed><TrafficTime>1.9</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>0.7</BaseTime></DynamicSpeedInfo><Address><Label>Oranienburger Straße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Oranienburger Straße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-733054082</LinkId><Shape>52.5262985,13.38727 52.5262489,13.3874302</Shape><Length>12.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>11.39</TrafficSpeed><TrafficTime>1.1</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>1.2</BaseTime></DynamicSpeedInfo><Address><Label>Oranienburger Straße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Oranienburger Straße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-733054081</LinkId><Shape>52.5262489,13.3874302 52.5261917,13.3877001</Shape><Length>19.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>11.39</TrafficSpeed><TrafficTime>1.7</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>2.0</BaseTime></DynamicSpeedInfo><Address><Label>Oranienburger Straße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Oranienburger Straße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-572680644</LinkId><Shape>52.5261917,13.3877001 52.5260506,13.3882999</Shape><Length>43.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>10.0</TrafficSpeed><TrafficTime>4.3</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>4.4</BaseTime></DynamicSpeedInfo><Address><Label>Oranienburger Straße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Oranienburger Straße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-572680642</LinkId><Shape>52.5260506,13.3882999 52.5259895,13.38873</Shape><Length>29.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>11.39</TrafficSpeed><TrafficTime>2.5</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>3.0</BaseTime></DynamicSpeedInfo><Address><Label>Oranienburger Straße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Oranienburger Straße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-572680640</LinkId><Shape>52.5259895,13.38873 52.5257187,13.3898802</Shape><Length>83.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>11.11</TrafficSpeed><TrafficTime>7.5</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>8.5</BaseTime></DynamicSpeedInfo><Address><Label>Oranienburger Straße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Oranienburger Straße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53501098</LinkId><Shape>52.5257187,13.3898802 52.5249786,13.3928604</Shape><Length>217.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>8.33</TrafficSpeed><TrafficTime>26.0</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>22.3</BaseTime></DynamicSpeedInfo><Address><Label>Oranienburger Straße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Oranienburger Straße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53501113</LinkId><Shape>52.5249786,13.3928604 52.5246773,13.3941345</Shape><Length>92.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>8.61</TrafficSpeed><TrafficTime>10.7</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>9.5</BaseTime></DynamicSpeedInfo><Address><Label>Oranienburger Straße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Oranienburger Straße</Street></Address></Link></Leg><Summary><Distance>1271.0</Distance><BaseTime>243.0</BaseTime></Summary></Route></Response></rtcr:CalculateRoute>
\ No newline at end of file diff --git a/tests/auto/nokia_services/routing/optim-economic.xml b/tests/auto/nokia_services/routing/optim-economic.xml new file mode 100644 index 00000000..4e61fec8 --- /dev/null +++ b/tests/auto/nokia_services/routing/optim-economic.xml @@ -0,0 +1,402 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes"?> +<rtcr:CalculateRoute xmlns:rtcr="http://www.navteq.com/lbsp/Routing-CalculateRoute/4"> + <Response> + <MetaInfo> + <Timestamp>2012-04-26T14:57:55.085Z</Timestamp> + <AdditionalData key="CurrentTrafficLastUpdate">2012-04-26T14:56:01.116+0000</AdditionalData> + <AdditionalData key="CurrentTrafficElementsCount">5094983</AdditionalData> + <AdditionalData key="LongTermClosureLastUpdate">2012-04-26T14:56:03.396+0000</AdditionalData> + <AdditionalData key="LongTermClosureElementsCount">12223</AdditionalData> + <AdditionalData key="ShortTermClosureLastUpdate">2012-04-26T14:56:03.396+0000</AdditionalData> + <AdditionalData key="ShortTermClosureElementsCount">506</AdditionalData> + <AdditionalData key="Map0">2011Q3</AdditionalData> + <AdditionalData key="Module0">routeserver,9.2-2012.02.20-hotfix6.2.13.1</AdditionalData> + <AdditionalData key="Module0ExecTime">17</AdditionalData> + <AdditionalData key="Service">routing-route-service,6.2.13.1</AdditionalData> + </MetaInfo> + <Route> + <RouteId>REMvFQUAAAB4tdyZCURKQJROJJhqxipAAAAAYAlESkAAAADAasYqQAAAAAAAAPB_AAAAAAAA8H-XVzADV_SHZp4MKQHNgLOULCerAAEAAICiDCkBAQAAADAnqwABAAAAAADA_wEAAAAAAMD_HY0-83dwYQCu</RouteId> + <Waypoint> + <LinkId>+53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Waypoint> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Mode> + <Type>economic</Type> + <TransportModes>car</TransportModes> + </Mode> + <Shape>52.5315361,13.3875332 52.5315819,13.3880997 52.5316582,13.3889303 52.5317612,13.3896999 52.5316315,13.3899002 52.5302505,13.3916502 52.5300598,13.3919001 52.5286217,13.3937197 52.5285416,13.3938799 52.5282288,13.3924398 52.5276604,13.3927898 52.5274887,13.39293 52.5264091,13.3935404 52.5262985,13.3935604 52.5254402,13.3931103 52.5249786,13.3928604 52.5246773,13.3941345</Shape> + <BoundingBox> + <TopLeft> + <Latitude>52.5317612</Latitude> + <Longitude>13.3875332</Longitude> + </TopLeft> + <BottomRight> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </BottomRight> + </BoundingBox> + <Leg> + <Start> + <LinkId>+53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Start> + <End> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </End> + <Length>1177.0</Length> + <TravelTime>237.7</TravelTime> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M1"> + <Position> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </Position> + <Instruction>Head toward Borsigstraße on Invalidenstraße. Go for 500 feet.</Instruction> + <TravelTime>15.2</TravelTime> + <Length>148.0</Length> + <ToLink>+53499799</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M2"> + <Position> + <Latitude>52.5317612</Latitude> + <Longitude>13.3896999</Longitude> + </Position> + <Instruction>Turn right onto Gartenstraße. Go for 0.3 miles.</Instruction> + <TravelTime>90.8</TravelTime> + <Length>454.0</Length> + <ToLink>-811854188</ToLink> + <Direction>right</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M3"> + <Position> + <Latitude>52.5285416</Latitude> + <Longitude>13.3938799</Longitude> + </Position> + <Instruction>Turn right onto Torstraße. Go for 350 feet.</Instruction> + <TravelTime>28.4</TravelTime> + <Length>103.0</Length> + <ToLink>-53499981</ToLink> + <Direction>right</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M4"> + <Position> + <Latitude>52.5282288</Latitude> + <Longitude>13.3924398</Longitude> + </Position> + <Instruction>Turn left onto Tucholskystraße. Go for 0.2 miles.</Instruction> + <TravelTime>72.4</TravelTime> + <Length>380.0</Length> + <ToLink>-53500024</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M5"> + <Position> + <Latitude>52.5249786</Latitude> + <Longitude>13.3928604</Longitude> + </Position> + <Instruction>Turn left onto Oranienburger Straße. Go for 300 feet.</Instruction> + <TravelTime>30.9</TravelTime> + <Length>92.0</Length> + <ToLink>-53501113</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M6"> + <Position> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </Position> + <Instruction>Your destination on Oranienburger Straße is on the right. The trip takes 0.7 miles and 4 mins.</Instruction> + <TravelTime>0.0</TravelTime> + <Length>0.0</Length> + <Direction>forward</Direction> + </Maneuver> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+53499799</LinkId> + <Shape>52.5315361,13.3875332 52.5315819,13.3880997</Shape> + <Length>38.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>7.77</TrafficSpeed> + <TrafficTime>4.9</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>3.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Invalidenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Invalidenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+53499788</LinkId> + <Shape>52.5315819,13.3880997 52.5316582,13.3889303 52.5317612,13.3896999</Shape> + <Length>110.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>7.77</TrafficSpeed> + <TrafficTime>14.1</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>11.3</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Invalidenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Invalidenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-811854188</LinkId> + <Shape>52.5317612,13.3896999 52.5316315,13.3899002</Shape> + <Length>19.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.0</TrafficSpeed> + <TrafficTime>3.8</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>2.7</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Gartenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Gartenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-811854187</LinkId> + <Shape>52.5316315,13.3899002 52.5302505,13.3916502</Shape> + <Length>193.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.28</TrafficSpeed> + <TrafficTime>36.6</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>27.8</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Gartenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Gartenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499878</LinkId> + <Shape>52.5302505,13.3916502 52.5300598,13.3919001</Shape> + <Length>27.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.28</TrafficSpeed> + <TrafficTime>5.1</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>3.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Gartenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Gartenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499960</LinkId> + <Shape>52.5300598,13.3919001 52.5286217,13.3937197 52.5285416,13.3938799</Shape> + <Length>215.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.28</TrafficSpeed> + <TrafficTime>40.7</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>31.0</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Gartenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Gartenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499981</LinkId> + <Shape>52.5285416,13.3938799 52.5282288,13.3924398</Shape> + <Length>103.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>8.33</TrafficSpeed> + <TrafficTime>12.4</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>14.8</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Torstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Torstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53500024</LinkId> + <Shape>52.5282288,13.3924398 52.5276604,13.3927898 52.5274887,13.39293</Shape> + <Length>88.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>4.72</TrafficSpeed> + <TrafficTime>18.6</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>9.1</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53500091</LinkId> + <Shape>52.5274887,13.39293 52.5264091,13.3935404</Shape> + <Length>126.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>4.72</TrafficSpeed> + <TrafficTime>26.7</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>13.0</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-844906239</LinkId> + <Shape>52.5264091,13.3935404 52.5262985,13.3935604 52.5254402,13.3931103</Shape> + <Length>112.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>4.17</TrafficSpeed> + <TrafficTime>26.9</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>11.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-844906238</LinkId> + <Shape>52.5254402,13.3931103 52.5249786,13.3928604</Shape> + <Length>54.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>3.89</TrafficSpeed> + <TrafficTime>13.9</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>5.6</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53501113</LinkId> + <Shape>52.5249786,13.3928604 52.5246773,13.3941345</Shape> + <Length>92.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>8.61</TrafficSpeed> + <TrafficTime>10.7</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>9.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + </Leg> + <Summary> + <Distance>1177.0</Distance> + <TrafficTime>309.0</TrafficTime> + <BaseTime>237.0</BaseTime> + </Summary> + </Route> + </Response> +</rtcr:CalculateRoute>
\ No newline at end of file diff --git a/tests/auto/nokia_services/routing/optim-fastest.xml b/tests/auto/nokia_services/routing/optim-fastest.xml new file mode 100644 index 00000000..43a7a77b --- /dev/null +++ b/tests/auto/nokia_services/routing/optim-fastest.xml @@ -0,0 +1,628 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes"?> +<rtcr:CalculateRoute xmlns:rtcr="http://www.navteq.com/lbsp/Routing-CalculateRoute/4"> + <Response> + <MetaInfo> + <Timestamp>2012-04-26T14:49:24.451Z</Timestamp> + <AdditionalData key="CurrentTrafficLastUpdate">2012-04-26T14:47:00.025+0000</AdditionalData> + <AdditionalData key="CurrentTrafficElementsCount">5094886</AdditionalData> + <AdditionalData key="LongTermClosureLastUpdate">2012-04-26T14:47:02.481+0000</AdditionalData> + <AdditionalData key="LongTermClosureElementsCount">12015</AdditionalData> + <AdditionalData key="ShortTermClosureLastUpdate">2012-04-26T14:47:02.481+0000</AdditionalData> + <AdditionalData key="ShortTermClosureElementsCount">857</AdditionalData> + <AdditionalData key="Map0">2011Q3</AdditionalData> + <AdditionalData key="Module0">routeserver,9.2-2012.02.20-hotfix6.2.13.1</AdditionalData> + <AdditionalData key="Module0ExecTime">22</AdditionalData> + <AdditionalData key="Service">routing-route-service,6.2.13.1</AdditionalData> + </MetaInfo> + <Route> + <RouteId>REMvaQUAAAB4tdyZCURKQJROJJhqxipAAAAAYAlESkAAAADAasYqQAAAAAAAAPB_AAAAAAAA8H9pqM_8V_SHZp4MKQHNgLOULCerAAEAAICiDCkBAQAAADAnqwABAAAAAADA_wEAAAAAAMD_HY0-82dwsAoDCQ</RouteId> + <Waypoint> + <LinkId>-53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Waypoint> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Mode> + <Type>fastestNow</Type> + <TransportModes>car</TransportModes> + <TrafficMode>enabled</TrafficMode> + </Mode> + <Shape>52.5315361,13.3875332 52.5315094,13.3872204 52.5314484,13.3868303 52.5308685,13.3871498 52.5304298,13.3873901 52.5303993,13.3872299 52.5303612,13.3871202 52.5293198,13.3846502 52.5289383,13.3851404 52.5288315,13.3852901 52.5287399,13.3853998 52.5285416,13.3856297 52.5283089,13.38591 52.5281982,13.3860397 52.5280991,13.3861103 52.5274811,13.3867598 52.5271416,13.3869896 52.5270386,13.3870201 52.5262985,13.3871603 52.5262985,13.38727 52.5262489,13.3874302 52.5261917,13.3877001 52.5260506,13.3882999 52.5259895,13.38873 52.5257187,13.3898802 52.5249786,13.3928604 52.5246773,13.3941345</Shape> + <BoundingBox> + <TopLeft> + <Latitude>52.5315361</Latitude> + <Longitude>13.3846502</Longitude> + </TopLeft> + <BottomRight> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </BottomRight> + </BoundingBox> + <Leg> + <Start> + <LinkId>-53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Start> + <End> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </End> + <Length>1271.0</Length> + <TravelTime>273.9</TravelTime> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M1"> + <Position> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </Position> + <Instruction>Head toward Eichendorffstraße on Invalidenstraße. Go for 150 feet.</Instruction> + <TravelTime>5.2</TravelTime> + <Length>48.0</Length> + <ToLink>-53499799</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M2"> + <Position> + <Latitude>52.5314484</Latitude> + <Longitude>13.3868303</Longitude> + </Position> + <Instruction>Turn left onto Eichendorffstraße. Go for 400 feet.</Instruction> + <TravelTime>47.1</TravelTime> + <Length>119.0</Length> + <ToLink>-780236888</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M3"> + <Position> + <Latitude>52.5304298</Latitude> + <Longitude>13.3873901</Longitude> + </Position> + <Instruction>Turn right onto Schlegelstraße. Go for 0.1 miles.</Instruction> + <TravelTime>55.9</TravelTime> + <Length>223.0</Length> + <ToLink>-53499914</ToLink> + <Direction>right</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M4"> + <Position> + <Latitude>52.5293198</Latitude> + <Longitude>13.3846502</Longitude> + </Position> + <Instruction>Turn left onto Chausseestraße. Go for 0.2 miles.</Instruction> + <TravelTime>68.0</TravelTime> + <Length>286.0</Length> + <ToLink>-749446557</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M5"> + <Position> + <Latitude>52.5271416</Latitude> + <Longitude>13.3869896</Longitude> + </Position> + <Instruction>Continue on Friedrichstraße, Oranienburger Tor. Go for 300 feet.</Instruction> + <TravelTime>20.1</TravelTime> + <Length>93.0</Length> + <ToLink>-572708773</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M6"> + <Position> + <Latitude>52.5262985</Latitude> + <Longitude>13.3871603</Longitude> + </Position> + <Instruction>Turn left onto Oranienburger Straße. Go for 0.3 miles.</Instruction> + <TravelTime>77.6</TravelTime> + <Length>502.0</Length> + <ToLink>+812293299</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M7"> + <Position> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </Position> + <Instruction>Your destination on Oranienburger Straße is on the right. The trip takes 0.8 miles and 5 mins.</Instruction> + <TravelTime>0.0</TravelTime> + <Length>0.0</Length> + <Direction>forward</Direction> + </Maneuver> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499799</LinkId> + <Shape>52.5315361,13.3875332 52.5315094,13.3872204 52.5314484,13.3868303</Shape> + <Length>48.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>9.17</TrafficSpeed> + <TrafficTime>5.2</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>4.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Invalidenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Invalidenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-780236888</LinkId> + <Shape>52.5314484,13.3868303 52.5308685,13.3871498</Shape> + <Length>68.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.0</TrafficSpeed> + <TrafficTime>13.6</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>9.8</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Eichendorffstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Eichendorffstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-780236887</LinkId> + <Shape>52.5308685,13.3871498 52.5304298,13.3873901</Shape> + <Length>51.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.28</TrafficSpeed> + <TrafficTime>9.7</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>7.3</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Eichendorffstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Eichendorffstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499914</LinkId> + <Shape>52.5304298,13.3873901 52.5303993,13.3872299 52.5303612,13.3871202 52.5293198,13.3846502</Shape> + <Length>223.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.28</TrafficSpeed> + <TrafficTime>42.3</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>32.1</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Schlegelstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Schlegelstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-749446557</LinkId> + <Shape>52.5293198,13.3846502 52.5289383,13.3851404</Shape> + <Length>53.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>4.9</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>5.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-781763170</LinkId> + <Shape>52.5289383,13.3851404 52.5288315,13.3852901</Shape> + <Length>15.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>1.4</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>1.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-781763169</LinkId> + <Shape>52.5288315,13.3852901 52.5287399,13.3853998</Shape> + <Length>12.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>1.1</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>1.2</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-781763164</LinkId> + <Shape>52.5287399,13.3853998 52.5285416,13.3856297</Shape> + <Length>26.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>2.4</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>2.7</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-781763163</LinkId> + <Shape>52.5285416,13.3856297 52.5283089,13.38591</Shape> + <Length>32.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>3.0</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>3.3</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-749446551</LinkId> + <Shape>52.5283089,13.38591 52.5281982,13.3860397</Shape> + <Length>15.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>1.4</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>1.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572708771</LinkId> + <Shape>52.5281982,13.3860397 52.5280991,13.3861103 52.5274811,13.3867598</Shape> + <Length>93.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>8.6</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>9.6</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53500039</LinkId> + <Shape>52.5274811,13.3867598 52.5271416,13.3869896</Shape> + <Length>40.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>3.7</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>4.1</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572708773</LinkId> + <Shape>52.5271416,13.3869896 52.5270386,13.3870201</Shape> + <Length>11.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.28</TrafficSpeed> + <TrafficTime>1.1</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>1.1</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Friedrichstraße, Oranienburger Tor</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Friedrichstraße, Oranienburger Tor</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572708772</LinkId> + <Shape>52.5270386,13.3870201 52.5262985,13.3871603</Shape> + <Length>82.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.28</TrafficSpeed> + <TrafficTime>8.0</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>8.4</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Friedrichstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Friedrichstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+812293299</LinkId> + <Shape>52.5262985,13.3871603 52.5262985,13.38727</Shape> + <Length>7.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>3.61</TrafficSpeed> + <TrafficTime>1.9</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>0.7</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-733054082</LinkId> + <Shape>52.5262985,13.38727 52.5262489,13.3874302</Shape> + <Length>12.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>11.39</TrafficSpeed> + <TrafficTime>1.1</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>1.2</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-733054081</LinkId> + <Shape>52.5262489,13.3874302 52.5261917,13.3877001</Shape> + <Length>19.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>11.39</TrafficSpeed> + <TrafficTime>1.7</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>2.0</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572680644</LinkId> + <Shape>52.5261917,13.3877001 52.5260506,13.3882999</Shape> + <Length>43.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.0</TrafficSpeed> + <TrafficTime>4.3</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>4.4</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572680642</LinkId> + <Shape>52.5260506,13.3882999 52.5259895,13.38873</Shape> + <Length>29.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>11.39</TrafficSpeed> + <TrafficTime>2.5</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>3.0</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572680640</LinkId> + <Shape>52.5259895,13.38873 52.5257187,13.3898802</Shape> + <Length>83.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>11.11</TrafficSpeed> + <TrafficTime>7.5</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>8.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53501098</LinkId> + <Shape>52.5257187,13.3898802 52.5249786,13.3928604</Shape> + <Length>217.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>8.33</TrafficSpeed> + <TrafficTime>26.0</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>22.3</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53501113</LinkId> + <Shape>52.5249786,13.3928604 52.5246773,13.3941345</Shape> + <Length>92.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>8.61</TrafficSpeed> + <TrafficTime>10.7</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>9.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + </Leg> + <Summary> + <Distance>1271.0</Distance> + <BaseTime>243.0</BaseTime> + </Summary> + </Route> + </Response> +</rtcr:CalculateRoute>
\ No newline at end of file diff --git a/tests/auto/nokia_services/routing/optim-scenic.xml b/tests/auto/nokia_services/routing/optim-scenic.xml new file mode 100644 index 00000000..af4ca6f7 --- /dev/null +++ b/tests/auto/nokia_services/routing/optim-scenic.xml @@ -0,0 +1,402 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes"?> +<rtcr:CalculateRoute xmlns:rtcr="http://www.navteq.com/lbsp/Routing-CalculateRoute/4"> + <Response> + <MetaInfo> + <Timestamp>2012-04-26T14:58:19.456Z</Timestamp> + <AdditionalData key="CurrentTrafficLastUpdate">2012-04-26T14:56:00.026+0000</AdditionalData> + <AdditionalData key="CurrentTrafficElementsCount">5094983</AdditionalData> + <AdditionalData key="LongTermClosureLastUpdate">2012-04-26T14:56:02.404+0000</AdditionalData> + <AdditionalData key="LongTermClosureElementsCount">12223</AdditionalData> + <AdditionalData key="ShortTermClosureLastUpdate">2012-04-26T14:56:02.404+0000</AdditionalData> + <AdditionalData key="ShortTermClosureElementsCount">506</AdditionalData> + <AdditionalData key="Map0">2011Q3</AdditionalData> + <AdditionalData key="Module0">routeserver,9.2-2012.02.20-hotfix6.2.13.1</AdditionalData> + <AdditionalData key="Module0ExecTime">31</AdditionalData> + <AdditionalData key="Service">routing-route-service,6.2.13.1</AdditionalData> + </MetaInfo> + <Route> + <RouteId>REMvFQUAAAB4tdyZCURKQJROJJhqxipAAAAAYAlESkAAAADAasYqQAAAAAAAAPB_AAAAAAAA8H-XVzADV_SHZp4MKQHNgLOULCerAAEAAICiDCkBAQAAADAnqwABAAAAAADA_wEAAAAAAMD_HY0-83dwYQCu</RouteId> + <Waypoint> + <LinkId>+53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Waypoint> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Mode> + <Type>scenic</Type> + <TransportModes>car</TransportModes> + </Mode> + <Shape>52.5315361,13.3875332 52.5315819,13.3880997 52.5316582,13.3889303 52.5317612,13.3896999 52.5316315,13.3899002 52.5302505,13.3916502 52.5300598,13.3919001 52.5286217,13.3937197 52.5285416,13.3938799 52.5282288,13.3924398 52.5276604,13.3927898 52.5274887,13.39293 52.5264091,13.3935404 52.5262985,13.3935604 52.5254402,13.3931103 52.5249786,13.3928604 52.5246773,13.3941345</Shape> + <BoundingBox> + <TopLeft> + <Latitude>52.5317612</Latitude> + <Longitude>13.3875332</Longitude> + </TopLeft> + <BottomRight> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </BottomRight> + </BoundingBox> + <Leg> + <Start> + <LinkId>+53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Start> + <End> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </End> + <Length>1177.0</Length> + <TravelTime>237.7</TravelTime> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M1"> + <Position> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </Position> + <Instruction>Head toward Borsigstraße on Invalidenstraße. Go for 500 feet.</Instruction> + <TravelTime>15.2</TravelTime> + <Length>148.0</Length> + <ToLink>+53499799</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M2"> + <Position> + <Latitude>52.5317612</Latitude> + <Longitude>13.3896999</Longitude> + </Position> + <Instruction>Turn right onto Gartenstraße. Go for 0.3 miles.</Instruction> + <TravelTime>90.8</TravelTime> + <Length>454.0</Length> + <ToLink>-811854188</ToLink> + <Direction>right</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M3"> + <Position> + <Latitude>52.5285416</Latitude> + <Longitude>13.3938799</Longitude> + </Position> + <Instruction>Turn right onto Torstraße. Go for 350 feet.</Instruction> + <TravelTime>28.4</TravelTime> + <Length>103.0</Length> + <ToLink>-53499981</ToLink> + <Direction>right</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M4"> + <Position> + <Latitude>52.5282288</Latitude> + <Longitude>13.3924398</Longitude> + </Position> + <Instruction>Turn left onto Tucholskystraße. Go for 0.2 miles.</Instruction> + <TravelTime>72.4</TravelTime> + <Length>380.0</Length> + <ToLink>-53500024</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M5"> + <Position> + <Latitude>52.5249786</Latitude> + <Longitude>13.3928604</Longitude> + </Position> + <Instruction>Turn left onto Oranienburger Straße. Go for 300 feet.</Instruction> + <TravelTime>30.9</TravelTime> + <Length>92.0</Length> + <ToLink>-53501113</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M6"> + <Position> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </Position> + <Instruction>Your destination on Oranienburger Straße is on the right. The trip takes 0.7 miles and 4 mins.</Instruction> + <TravelTime>0.0</TravelTime> + <Length>0.0</Length> + <Direction>forward</Direction> + </Maneuver> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+53499799</LinkId> + <Shape>52.5315361,13.3875332 52.5315819,13.3880997</Shape> + <Length>38.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>7.77</TrafficSpeed> + <TrafficTime>4.9</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>3.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Invalidenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Invalidenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+53499788</LinkId> + <Shape>52.5315819,13.3880997 52.5316582,13.3889303 52.5317612,13.3896999</Shape> + <Length>110.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>7.77</TrafficSpeed> + <TrafficTime>14.1</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>11.3</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Invalidenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Invalidenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-811854188</LinkId> + <Shape>52.5317612,13.3896999 52.5316315,13.3899002</Shape> + <Length>19.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.0</TrafficSpeed> + <TrafficTime>3.8</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>2.7</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Gartenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Gartenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-811854187</LinkId> + <Shape>52.5316315,13.3899002 52.5302505,13.3916502</Shape> + <Length>193.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.28</TrafficSpeed> + <TrafficTime>36.6</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>27.8</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Gartenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Gartenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499878</LinkId> + <Shape>52.5302505,13.3916502 52.5300598,13.3919001</Shape> + <Length>27.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.28</TrafficSpeed> + <TrafficTime>5.1</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>3.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Gartenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Gartenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499960</LinkId> + <Shape>52.5300598,13.3919001 52.5286217,13.3937197 52.5285416,13.3938799</Shape> + <Length>215.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.28</TrafficSpeed> + <TrafficTime>40.7</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>31.0</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Gartenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Gartenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499981</LinkId> + <Shape>52.5285416,13.3938799 52.5282288,13.3924398</Shape> + <Length>103.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>8.33</TrafficSpeed> + <TrafficTime>12.4</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>14.8</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Torstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Torstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53500024</LinkId> + <Shape>52.5282288,13.3924398 52.5276604,13.3927898 52.5274887,13.39293</Shape> + <Length>88.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>4.72</TrafficSpeed> + <TrafficTime>18.6</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>9.1</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53500091</LinkId> + <Shape>52.5274887,13.39293 52.5264091,13.3935404</Shape> + <Length>126.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>4.72</TrafficSpeed> + <TrafficTime>26.7</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>13.0</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-844906239</LinkId> + <Shape>52.5264091,13.3935404 52.5262985,13.3935604 52.5254402,13.3931103</Shape> + <Length>112.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>4.17</TrafficSpeed> + <TrafficTime>26.9</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>11.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-844906238</LinkId> + <Shape>52.5254402,13.3931103 52.5249786,13.3928604</Shape> + <Length>54.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>3.89</TrafficSpeed> + <TrafficTime>13.9</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>5.6</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53501113</LinkId> + <Shape>52.5249786,13.3928604 52.5246773,13.3941345</Shape> + <Length>92.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>8.61</TrafficSpeed> + <TrafficTime>10.7</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>9.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + </Leg> + <Summary> + <Distance>1177.0</Distance> + <TrafficTime>309.0</TrafficTime> + <BaseTime>237.0</BaseTime> + </Summary> + </Route> + </Response> +</rtcr:CalculateRoute>
\ No newline at end of file diff --git a/tests/auto/nokia_services/routing/optim-shortest.xml b/tests/auto/nokia_services/routing/optim-shortest.xml new file mode 100644 index 00000000..5aa8679d --- /dev/null +++ b/tests/auto/nokia_services/routing/optim-shortest.xml @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes"?><rtcr:CalculateRoute xmlns:rtcr="http://www.navteq.com/lbsp/Routing-CalculateRoute/4"><Response><MetaInfo><Timestamp>2012-04-26T14:57:30.304Z</Timestamp><AdditionalData key="CurrentTrafficLastUpdate">2012-04-26T14:56:00.027+0000</AdditionalData><AdditionalData key="CurrentTrafficElementsCount">5094983</AdditionalData><AdditionalData key="LongTermClosureLastUpdate">2012-04-26T14:56:02.406+0000</AdditionalData><AdditionalData key="LongTermClosureElementsCount">12223</AdditionalData><AdditionalData key="ShortTermClosureLastUpdate">2012-04-26T14:56:02.406+0000</AdditionalData><AdditionalData key="ShortTermClosureElementsCount">506</AdditionalData><AdditionalData key="Map0">2011Q3</AdditionalData><AdditionalData key="Module0">routeserver,9.2-2012.02.20-hotfix6.2.13.1</AdditionalData><AdditionalData key="Module0ExecTime">41</AdditionalData><AdditionalData key="Service">routing-route-service,6.2.13.1</AdditionalData></MetaInfo><Route><RouteId>REMvFQUAAAB4tdyZCURKQJROJJhqxipAAAAAYAlESkAAAADAasYqQAAAAAAAAPB_AAAAAAAA8H-XVzADV_SHZp4MKQHNgLOULCerAAEAAICiDCkBAQAAADAnqwABAAAAAADA_wEAAAAAAMD_HY0-83dwYQCu</RouteId><Waypoint><LinkId>+53499799</LinkId><MappedPosition><Latitude>52.5315361</Latitude><Longitude>13.3875332</Longitude></MappedPosition><OriginalPosition><Latitude>52.531543</Latitude><Longitude>13.387532</Longitude></OriginalPosition><Type>stopOver</Type></Waypoint><Waypoint><LinkId>-53501113</LinkId><MappedPosition><Latitude>52.5246773</Latitude><Longitude>13.3941345</Longitude></MappedPosition><OriginalPosition><Latitude>52.524646</Latitude><Longitude>13.394128</Longitude></OriginalPosition><Type>stopOver</Type></Waypoint><Mode><Type>shortest</Type><TransportModes>car</TransportModes></Mode><Shape>52.5315361,13.3875332 52.5315819,13.3880997 52.5316582,13.3889303 52.5317612,13.3896999 52.5316315,13.3899002 52.5302505,13.3916502 52.5300598,13.3919001 52.5286217,13.3937197 52.5285416,13.3938799 52.5282288,13.3924398 52.5276604,13.3927898 52.5274887,13.39293 52.5264091,13.3935404 52.5262985,13.3935604 52.5254402,13.3931103 52.5249786,13.3928604 52.5246773,13.3941345</Shape><BoundingBox><TopLeft><Latitude>52.5317612</Latitude><Longitude>13.3875332</Longitude></TopLeft><BottomRight><Latitude>52.5246773</Latitude><Longitude>13.3941345</Longitude></BottomRight></BoundingBox><Leg><Start><LinkId>+53499799</LinkId><MappedPosition><Latitude>52.5315361</Latitude><Longitude>13.3875332</Longitude></MappedPosition><OriginalPosition><Latitude>52.531543</Latitude><Longitude>13.387532</Longitude></OriginalPosition><Type>stopOver</Type></Start><End><LinkId>-53501113</LinkId><MappedPosition><Latitude>52.5246773</Latitude><Longitude>13.3941345</Longitude></MappedPosition><OriginalPosition><Latitude>52.524646</Latitude><Longitude>13.394128</Longitude></OriginalPosition><Type>stopOver</Type></End><Length>1177.0</Length><TravelTime>237.7</TravelTime><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M1"><Position><Latitude>52.5315361</Latitude><Longitude>13.3875332</Longitude></Position><Instruction>Head toward Borsigstraße on Invalidenstraße. Go for 500 feet.</Instruction><TravelTime>15.2</TravelTime><Length>148.0</Length><ToLink>+53499799</ToLink><Direction>forward</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M2"><Position><Latitude>52.5317612</Latitude><Longitude>13.3896999</Longitude></Position><Instruction>Turn right onto Gartenstraße. Go for 0.3 miles.</Instruction><TravelTime>90.8</TravelTime><Length>454.0</Length><ToLink>-811854188</ToLink><Direction>right</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M3"><Position><Latitude>52.5285416</Latitude><Longitude>13.3938799</Longitude></Position><Instruction>Turn right onto Torstraße. Go for 350 feet.</Instruction><TravelTime>28.4</TravelTime><Length>103.0</Length><ToLink>-53499981</ToLink><Direction>right</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M4"><Position><Latitude>52.5282288</Latitude><Longitude>13.3924398</Longitude></Position><Instruction>Turn left onto Tucholskystraße. Go for 0.2 miles.</Instruction><TravelTime>72.4</TravelTime><Length>380.0</Length><ToLink>-53500024</ToLink><Direction>left</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M5"><Position><Latitude>52.5249786</Latitude><Longitude>13.3928604</Longitude></Position><Instruction>Turn left onto Oranienburger Straße. Go for 300 feet.</Instruction><TravelTime>30.9</TravelTime><Length>92.0</Length><ToLink>-53501113</ToLink><Direction>left</Direction></Maneuver><Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M6"><Position><Latitude>52.5246773</Latitude><Longitude>13.3941345</Longitude></Position><Instruction>Your destination on Oranienburger Straße is on the right. The trip takes 0.7 miles and 4 mins.</Instruction><TravelTime>0.0</TravelTime><Length>0.0</Length><Direction>forward</Direction></Maneuver><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>+53499799</LinkId><Shape>52.5315361,13.3875332 52.5315819,13.3880997</Shape><Length>38.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>7.77</TrafficSpeed><TrafficTime>4.9</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>3.9</BaseTime></DynamicSpeedInfo><Address><Label>Invalidenstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Invalidenstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>+53499788</LinkId><Shape>52.5315819,13.3880997 52.5316582,13.3889303 52.5317612,13.3896999</Shape><Length>110.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>7.77</TrafficSpeed><TrafficTime>14.1</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>11.3</BaseTime></DynamicSpeedInfo><Address><Label>Invalidenstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Invalidenstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-811854188</LinkId><Shape>52.5317612,13.3896999 52.5316315,13.3899002</Shape><Length>19.0</Length><DynamicSpeedInfo><TrafficSpeed>5.0</TrafficSpeed><TrafficTime>3.8</TrafficTime><BaseSpeed>6.94</BaseSpeed><BaseTime>2.7</BaseTime></DynamicSpeedInfo><Address><Label>Gartenstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Gartenstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-811854187</LinkId><Shape>52.5316315,13.3899002 52.5302505,13.3916502</Shape><Length>193.0</Length><DynamicSpeedInfo><TrafficSpeed>5.28</TrafficSpeed><TrafficTime>36.6</TrafficTime><BaseSpeed>6.94</BaseSpeed><BaseTime>27.8</BaseTime></DynamicSpeedInfo><Address><Label>Gartenstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Gartenstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53499878</LinkId><Shape>52.5302505,13.3916502 52.5300598,13.3919001</Shape><Length>27.0</Length><DynamicSpeedInfo><TrafficSpeed>5.28</TrafficSpeed><TrafficTime>5.1</TrafficTime><BaseSpeed>6.94</BaseSpeed><BaseTime>3.9</BaseTime></DynamicSpeedInfo><Address><Label>Gartenstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Gartenstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53499960</LinkId><Shape>52.5300598,13.3919001 52.5286217,13.3937197 52.5285416,13.3938799</Shape><Length>215.0</Length><DynamicSpeedInfo><TrafficSpeed>5.28</TrafficSpeed><TrafficTime>40.7</TrafficTime><BaseSpeed>6.94</BaseSpeed><BaseTime>31.0</BaseTime></DynamicSpeedInfo><Address><Label>Gartenstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Gartenstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53499981</LinkId><Shape>52.5285416,13.3938799 52.5282288,13.3924398</Shape><Length>103.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>8.33</TrafficSpeed><TrafficTime>12.4</TrafficTime><BaseSpeed>6.94</BaseSpeed><BaseTime>14.8</BaseTime></DynamicSpeedInfo><Address><Label>Torstraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Torstraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53500024</LinkId><Shape>52.5282288,13.3924398 52.5276604,13.3927898 52.5274887,13.39293</Shape><Length>88.0</Length><DynamicSpeedInfo><TrafficSpeed>4.72</TrafficSpeed><TrafficTime>18.6</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>9.1</BaseTime></DynamicSpeedInfo><Address><Label>Tucholskystraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Tucholskystraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53500091</LinkId><Shape>52.5274887,13.39293 52.5264091,13.3935404</Shape><Length>126.0</Length><DynamicSpeedInfo><TrafficSpeed>4.72</TrafficSpeed><TrafficTime>26.7</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>13.0</BaseTime></DynamicSpeedInfo><Address><Label>Tucholskystraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Tucholskystraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-844906239</LinkId><Shape>52.5264091,13.3935404 52.5262985,13.3935604 52.5254402,13.3931103</Shape><Length>112.0</Length><DynamicSpeedInfo><TrafficSpeed>4.17</TrafficSpeed><TrafficTime>26.9</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>11.5</BaseTime></DynamicSpeedInfo><Address><Label>Tucholskystraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Tucholskystraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-844906238</LinkId><Shape>52.5254402,13.3931103 52.5249786,13.3928604</Shape><Length>54.0</Length><DynamicSpeedInfo><TrafficSpeed>3.89</TrafficSpeed><TrafficTime>13.9</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>5.6</BaseTime></DynamicSpeedInfo><Address><Label>Tucholskystraße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Tucholskystraße</Street></Address></Link><Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"><LinkId>-53501113</LinkId><Shape>52.5249786,13.3928604 52.5246773,13.3941345</Shape><Length>92.0</Length><SpeedLimit>13.89</SpeedLimit><DynamicSpeedInfo><TrafficSpeed>8.61</TrafficSpeed><TrafficTime>10.7</TrafficTime><BaseSpeed>9.72</BaseSpeed><BaseTime>9.5</BaseTime></DynamicSpeedInfo><Address><Label>Oranienburger Straße</Label><Country>DE</Country><State>Berlin</State><County>Berlin</County><City>Berlin</City><District>Mitte</District><Street>Oranienburger Straße</Street></Address></Link></Leg><Summary><Distance>1177.0</Distance><TrafficTime>309.0</TrafficTime><BaseTime>237.0</BaseTime></Summary></Route></Response></rtcr:CalculateRoute>
\ No newline at end of file diff --git a/tests/auto/nokia_services/routing/routing.pro b/tests/auto/nokia_services/routing/routing.pro new file mode 100644 index 00000000..78788e0b --- /dev/null +++ b/tests/auto/nokia_services/routing/routing.pro @@ -0,0 +1,13 @@ +TEMPLATE = app +CONFIG += testcase +TARGET = tst_routing + +QT += location testlib +INCLUDEPATH += $$PWD/../../../../src/plugins/geoservices/nokia + +HEADERS += $$PWD/../../../../src/plugins/geoservices/nokia/qgeonetworkaccessmanager.h +SOURCES += tst_routing.cpp + +OTHER_FILES += *.xml + +TESTDATA = $$OTHER_FILES diff --git a/tests/auto/nokia_services/routing/travelmode-car.xml b/tests/auto/nokia_services/routing/travelmode-car.xml new file mode 100644 index 00000000..43a7a77b --- /dev/null +++ b/tests/auto/nokia_services/routing/travelmode-car.xml @@ -0,0 +1,628 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes"?> +<rtcr:CalculateRoute xmlns:rtcr="http://www.navteq.com/lbsp/Routing-CalculateRoute/4"> + <Response> + <MetaInfo> + <Timestamp>2012-04-26T14:49:24.451Z</Timestamp> + <AdditionalData key="CurrentTrafficLastUpdate">2012-04-26T14:47:00.025+0000</AdditionalData> + <AdditionalData key="CurrentTrafficElementsCount">5094886</AdditionalData> + <AdditionalData key="LongTermClosureLastUpdate">2012-04-26T14:47:02.481+0000</AdditionalData> + <AdditionalData key="LongTermClosureElementsCount">12015</AdditionalData> + <AdditionalData key="ShortTermClosureLastUpdate">2012-04-26T14:47:02.481+0000</AdditionalData> + <AdditionalData key="ShortTermClosureElementsCount">857</AdditionalData> + <AdditionalData key="Map0">2011Q3</AdditionalData> + <AdditionalData key="Module0">routeserver,9.2-2012.02.20-hotfix6.2.13.1</AdditionalData> + <AdditionalData key="Module0ExecTime">22</AdditionalData> + <AdditionalData key="Service">routing-route-service,6.2.13.1</AdditionalData> + </MetaInfo> + <Route> + <RouteId>REMvaQUAAAB4tdyZCURKQJROJJhqxipAAAAAYAlESkAAAADAasYqQAAAAAAAAPB_AAAAAAAA8H9pqM_8V_SHZp4MKQHNgLOULCerAAEAAICiDCkBAQAAADAnqwABAAAAAADA_wEAAAAAAMD_HY0-82dwsAoDCQ</RouteId> + <Waypoint> + <LinkId>-53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Waypoint> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Mode> + <Type>fastestNow</Type> + <TransportModes>car</TransportModes> + <TrafficMode>enabled</TrafficMode> + </Mode> + <Shape>52.5315361,13.3875332 52.5315094,13.3872204 52.5314484,13.3868303 52.5308685,13.3871498 52.5304298,13.3873901 52.5303993,13.3872299 52.5303612,13.3871202 52.5293198,13.3846502 52.5289383,13.3851404 52.5288315,13.3852901 52.5287399,13.3853998 52.5285416,13.3856297 52.5283089,13.38591 52.5281982,13.3860397 52.5280991,13.3861103 52.5274811,13.3867598 52.5271416,13.3869896 52.5270386,13.3870201 52.5262985,13.3871603 52.5262985,13.38727 52.5262489,13.3874302 52.5261917,13.3877001 52.5260506,13.3882999 52.5259895,13.38873 52.5257187,13.3898802 52.5249786,13.3928604 52.5246773,13.3941345</Shape> + <BoundingBox> + <TopLeft> + <Latitude>52.5315361</Latitude> + <Longitude>13.3846502</Longitude> + </TopLeft> + <BottomRight> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </BottomRight> + </BoundingBox> + <Leg> + <Start> + <LinkId>-53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Start> + <End> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </End> + <Length>1271.0</Length> + <TravelTime>273.9</TravelTime> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M1"> + <Position> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </Position> + <Instruction>Head toward Eichendorffstraße on Invalidenstraße. Go for 150 feet.</Instruction> + <TravelTime>5.2</TravelTime> + <Length>48.0</Length> + <ToLink>-53499799</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M2"> + <Position> + <Latitude>52.5314484</Latitude> + <Longitude>13.3868303</Longitude> + </Position> + <Instruction>Turn left onto Eichendorffstraße. Go for 400 feet.</Instruction> + <TravelTime>47.1</TravelTime> + <Length>119.0</Length> + <ToLink>-780236888</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M3"> + <Position> + <Latitude>52.5304298</Latitude> + <Longitude>13.3873901</Longitude> + </Position> + <Instruction>Turn right onto Schlegelstraße. Go for 0.1 miles.</Instruction> + <TravelTime>55.9</TravelTime> + <Length>223.0</Length> + <ToLink>-53499914</ToLink> + <Direction>right</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M4"> + <Position> + <Latitude>52.5293198</Latitude> + <Longitude>13.3846502</Longitude> + </Position> + <Instruction>Turn left onto Chausseestraße. Go for 0.2 miles.</Instruction> + <TravelTime>68.0</TravelTime> + <Length>286.0</Length> + <ToLink>-749446557</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M5"> + <Position> + <Latitude>52.5271416</Latitude> + <Longitude>13.3869896</Longitude> + </Position> + <Instruction>Continue on Friedrichstraße, Oranienburger Tor. Go for 300 feet.</Instruction> + <TravelTime>20.1</TravelTime> + <Length>93.0</Length> + <ToLink>-572708773</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M6"> + <Position> + <Latitude>52.5262985</Latitude> + <Longitude>13.3871603</Longitude> + </Position> + <Instruction>Turn left onto Oranienburger Straße. Go for 0.3 miles.</Instruction> + <TravelTime>77.6</TravelTime> + <Length>502.0</Length> + <ToLink>+812293299</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M7"> + <Position> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </Position> + <Instruction>Your destination on Oranienburger Straße is on the right. The trip takes 0.8 miles and 5 mins.</Instruction> + <TravelTime>0.0</TravelTime> + <Length>0.0</Length> + <Direction>forward</Direction> + </Maneuver> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499799</LinkId> + <Shape>52.5315361,13.3875332 52.5315094,13.3872204 52.5314484,13.3868303</Shape> + <Length>48.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>9.17</TrafficSpeed> + <TrafficTime>5.2</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>4.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Invalidenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Invalidenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-780236888</LinkId> + <Shape>52.5314484,13.3868303 52.5308685,13.3871498</Shape> + <Length>68.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.0</TrafficSpeed> + <TrafficTime>13.6</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>9.8</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Eichendorffstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Eichendorffstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-780236887</LinkId> + <Shape>52.5308685,13.3871498 52.5304298,13.3873901</Shape> + <Length>51.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.28</TrafficSpeed> + <TrafficTime>9.7</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>7.3</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Eichendorffstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Eichendorffstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499914</LinkId> + <Shape>52.5304298,13.3873901 52.5303993,13.3872299 52.5303612,13.3871202 52.5293198,13.3846502</Shape> + <Length>223.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>5.28</TrafficSpeed> + <TrafficTime>42.3</TrafficTime> + <BaseSpeed>6.94</BaseSpeed> + <BaseTime>32.1</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Schlegelstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Schlegelstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-749446557</LinkId> + <Shape>52.5293198,13.3846502 52.5289383,13.3851404</Shape> + <Length>53.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>4.9</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>5.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-781763170</LinkId> + <Shape>52.5289383,13.3851404 52.5288315,13.3852901</Shape> + <Length>15.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>1.4</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>1.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-781763169</LinkId> + <Shape>52.5288315,13.3852901 52.5287399,13.3853998</Shape> + <Length>12.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>1.1</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>1.2</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-781763164</LinkId> + <Shape>52.5287399,13.3853998 52.5285416,13.3856297</Shape> + <Length>26.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>2.4</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>2.7</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-781763163</LinkId> + <Shape>52.5285416,13.3856297 52.5283089,13.38591</Shape> + <Length>32.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>3.0</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>3.3</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-749446551</LinkId> + <Shape>52.5283089,13.38591 52.5281982,13.3860397</Shape> + <Length>15.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>1.4</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>1.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572708771</LinkId> + <Shape>52.5281982,13.3860397 52.5280991,13.3861103 52.5274811,13.3867598</Shape> + <Length>93.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>8.6</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>9.6</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53500039</LinkId> + <Shape>52.5274811,13.3867598 52.5271416,13.3869896</Shape> + <Length>40.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.83</TrafficSpeed> + <TrafficTime>3.7</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>4.1</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Chausseestraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Chausseestraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572708773</LinkId> + <Shape>52.5271416,13.3869896 52.5270386,13.3870201</Shape> + <Length>11.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.28</TrafficSpeed> + <TrafficTime>1.1</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>1.1</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Friedrichstraße, Oranienburger Tor</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Friedrichstraße, Oranienburger Tor</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572708772</LinkId> + <Shape>52.5270386,13.3870201 52.5262985,13.3871603</Shape> + <Length>82.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.28</TrafficSpeed> + <TrafficTime>8.0</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>8.4</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Friedrichstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Friedrichstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+812293299</LinkId> + <Shape>52.5262985,13.3871603 52.5262985,13.38727</Shape> + <Length>7.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>3.61</TrafficSpeed> + <TrafficTime>1.9</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>0.7</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-733054082</LinkId> + <Shape>52.5262985,13.38727 52.5262489,13.3874302</Shape> + <Length>12.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>11.39</TrafficSpeed> + <TrafficTime>1.1</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>1.2</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-733054081</LinkId> + <Shape>52.5262489,13.3874302 52.5261917,13.3877001</Shape> + <Length>19.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>11.39</TrafficSpeed> + <TrafficTime>1.7</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>2.0</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572680644</LinkId> + <Shape>52.5261917,13.3877001 52.5260506,13.3882999</Shape> + <Length>43.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>10.0</TrafficSpeed> + <TrafficTime>4.3</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>4.4</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572680642</LinkId> + <Shape>52.5260506,13.3882999 52.5259895,13.38873</Shape> + <Length>29.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>11.39</TrafficSpeed> + <TrafficTime>2.5</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>3.0</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-572680640</LinkId> + <Shape>52.5259895,13.38873 52.5257187,13.3898802</Shape> + <Length>83.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>11.11</TrafficSpeed> + <TrafficTime>7.5</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>8.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53501098</LinkId> + <Shape>52.5257187,13.3898802 52.5249786,13.3928604</Shape> + <Length>217.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>8.33</TrafficSpeed> + <TrafficTime>26.0</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>22.3</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53501113</LinkId> + <Shape>52.5249786,13.3928604 52.5246773,13.3941345</Shape> + <Length>92.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>8.61</TrafficSpeed> + <TrafficTime>10.7</TrafficTime> + <BaseSpeed>9.72</BaseSpeed> + <BaseTime>9.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + </Leg> + <Summary> + <Distance>1271.0</Distance> + <BaseTime>243.0</BaseTime> + </Summary> + </Route> + </Response> +</rtcr:CalculateRoute>
\ No newline at end of file diff --git a/tests/auto/nokia_services/routing/travelmode-pedestrian.xml b/tests/auto/nokia_services/routing/travelmode-pedestrian.xml new file mode 100644 index 00000000..56a79e38 --- /dev/null +++ b/tests/auto/nokia_services/routing/travelmode-pedestrian.xml @@ -0,0 +1,798 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes"?> +<rtcr:CalculateRoute xmlns:rtcr="http://www.navteq.com/lbsp/Routing-CalculateRoute/4"> + <Response> + <MetaInfo> + <Timestamp>2012-04-26T14:48:17.998Z</Timestamp> + <AdditionalData key="CurrentTrafficLastUpdate">2012-04-26T14:47:00.026+0000</AdditionalData> + <AdditionalData key="CurrentTrafficElementsCount">5094886</AdditionalData> + <AdditionalData key="LongTermClosureLastUpdate">2012-04-26T14:47:02.413+0000</AdditionalData> + <AdditionalData key="LongTermClosureElementsCount">12015</AdditionalData> + <AdditionalData key="ShortTermClosureLastUpdate">2012-04-26T14:47:02.413+0000</AdditionalData> + <AdditionalData key="ShortTermClosureElementsCount">857</AdditionalData> + <AdditionalData key="Map0">2011Q3</AdditionalData> + <AdditionalData key="Module0">routeserver,9.2-2012.02.20-hotfix6.2.13.1</AdditionalData> + <AdditionalData key="Module0ExecTime">96</AdditionalData> + <AdditionalData key="Service">routing-route-service,6.2.13.1</AdditionalData> + </MetaInfo> + <Route> + <RouteId>REMvSAkAAAB4tdyZCURKQJROJJhqxipAAAAAYAlESkAAAADAasYqQAAAAAAAAPB_AAAAAAAA8H-XVzADV_SHZp4MKQHNgLOULCerAAEAAICiDCkBAQAAADAnqwABAAAAAADA_wEAAAAAAMD_HY0-84fTC85nlF5wPmO1JsEZpheczwc8AOrpMz9xhQUzcABtrGd-FJ0-86Po9JnfAAHBo80GTA</RouteId> + <Waypoint> + <LinkId>+53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Waypoint> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Mode> + <Type>fastestNow</Type> + <TransportModes>pedestrian</TransportModes> + <TrafficMode>enabled</TrafficMode> + </Mode> + <Shape>52.5314903,13.3875389 52.5315857,13.3881445 52.5315475,13.3880892 52.5310287,13.388505 52.5309753,13.3885479 52.5307274,13.3887367 52.530674,13.3887777 52.5297775,13.3894777 52.5297241,13.3895216 52.5280571,13.3913355 52.5279846,13.3914194 52.5281792,13.3924217 52.5276413,13.392765 52.527504,13.3928776 52.5274544,13.3929157 52.5274773,13.3929968 52.5264435,13.3935556 52.5263863,13.3935757 52.5262947,13.3935919 52.525425,13.393137 52.5249977,13.3929052 52.5249405,13.3928967 52.5246468,13.3941231</Shape> + <BoundingBox> + <TopLeft> + <Latitude>52.5315857</Latitude> + <Longitude>13.3875389</Longitude> + </TopLeft> + <BottomRight> + <Latitude>52.5246468</Latitude> + <Longitude>13.3941231</Longitude> + </BottomRight> + </BoundingBox> + <Leg> + <Start> + <LinkId>+53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Start> + <End> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </End> + <Length>1107.0</Length> + <TravelTime>798.2</TravelTime> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M1"> + <Position> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </Position> + <Instruction>Head toward Borsigstraße on Invalidenstraße. Go for 100 feet.</Instruction> + <TravelTime>27.4</TravelTime> + <Length>38.0</Length> + <ToLink>+53499799</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M2"> + <Position> + <Latitude>52.5315819</Latitude> + <Longitude>13.3880997</Longitude> + </Position> + <Instruction>Turn right and use the crosswalk.</Instruction> + <TravelTime>6.0</TravelTime> + <Length>8.0</Length> + <ToLink>-811853913</ToLink> + <Direction>right</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M3"> + <Position> + <Latitude>52.5315819</Latitude> + <Longitude>13.3880997</Longitude> + </Position> + <Instruction>Continue on Borsigstraße. Go for 0.3 miles.</Instruction> + <TravelTime>343.4</TravelTime> + <Length>476.0</Length> + <ToLink>-811853915</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M4"> + <Position> + <Latitude>52.5280304</Latitude> + <Longitude>13.3914099</Longitude> + </Position> + <Instruction>Cross Torstraße.</Instruction> + <TravelTime>5.0</TravelTime> + <Length>8.0</Length> + <ToLink>-833290988</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M5"> + <Position> + <Latitude>52.5280304</Latitude> + <Longitude>13.3914099</Longitude> + </Position> + <Instruction>Turn left onto Torstraße. Go for 250 feet.</Instruction> + <TravelTime>52.6</TravelTime> + <Length>73.0</Length> + <ToLink>+53499991</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M6"> + <Position> + <Latitude>52.5282288</Latitude> + <Longitude>13.3924398</Longitude> + </Position> + <Instruction>Turn right onto Tucholskystraße. Go for 300 feet.</Instruction> + <TravelTime>63.4</TravelTime> + <Length>88.0</Length> + <ToLink>-53500024</ToLink> + <Direction>right</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M7"> + <Position> + <Latitude>52.5274887</Latitude> + <Longitude>13.39293</Longitude> + </Position> + <Instruction>Cross Linienstraße, Tucholskystraße.</Instruction> + <TravelTime>12.0</TravelTime> + <Length>16.0</Length> + <ToLink>-53520166</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M8"> + <Position> + <Latitude>52.5274887</Latitude> + <Longitude>13.39293</Longitude> + </Position> + <Instruction>Turn right onto Tucholskystraße. Go for 0.2 miles.</Instruction> + <TravelTime>216.2</TravelTime> + <Length>300.0</Length> + <ToLink>-53500091</ToLink> + <Direction>right</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M9"> + <Position> + <Latitude>52.5249786</Latitude> + <Longitude>13.3928604</Longitude> + </Position> + <Instruction>Cross Oranienburger Straße.</Instruction> + <TravelTime>6.0</TravelTime> + <Length>8.0</Length> + <ToLink>-53501113</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M10"> + <Position> + <Latitude>52.5249786</Latitude> + <Longitude>13.3928604</Longitude> + </Position> + <Instruction>Turn left onto Oranienburger Straße. Go for 300 feet.</Instruction> + <TravelTime>66.2</TravelTime> + <Length>92.0</Length> + <ToLink>-53501113</ToLink> + <Direction>left</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M11"> + <Position> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </Position> + <Instruction>Your destination on Oranienburger Straße is on the right. The trip takes 0.7 miles and 13 mins.</Instruction> + <TravelTime>0.0</TravelTime> + <Length>0.0</Length> + <Direction>forward</Direction> + </Maneuver> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+53499799</LinkId> + <Shape>52.5314903,13.3875389 52.5315857,13.3881445</Shape> + <Length>38.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>7.77</TrafficSpeed> + <TrafficTime>4.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>27.4</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Invalidenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Invalidenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-811853913</LinkId> + <Shape>52.5315857,13.3881445 52.5315475,13.3880892</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label></Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+811853913</LinkId> + <Shape>52.5315475,13.3880892</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label></Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-811853915</LinkId> + <Shape>52.5315475,13.3880892 52.5310287,13.388505</Shape> + <Length>70.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>50.4</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>50.4</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Borsigstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Borsigstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-838257237</LinkId> + <Shape>52.5310287,13.388505 52.5309753,13.3885479</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label></Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+838257237</LinkId> + <Shape>52.5309753,13.3885479</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label></Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-811853914</LinkId> + <Shape>52.5309753,13.3885479 52.5307274,13.3887367</Shape> + <Length>36.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>25.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>25.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Borsigstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Borsigstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499858</LinkId> + <Shape>52.5307274,13.3887367 52.530674,13.3887777</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Schlegelstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Schlegelstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+53499858</LinkId> + <Shape>52.530674,13.3887777</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Schlegelstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Schlegelstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499890</LinkId> + <Shape>52.530674,13.3887777 52.5297775,13.3894777</Shape> + <Length>116.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>83.5</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>83.5</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Borsigstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Borsigstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499910</LinkId> + <Shape>52.5297775,13.3894777 52.5297241,13.3895216</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tieckstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tieckstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+53499910</LinkId> + <Shape>52.5297241,13.3895216</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tieckstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tieckstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53499992</LinkId> + <Shape>52.5297241,13.3895216 52.5280571,13.3913355</Shape> + <Length>230.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>165.6</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>165.6</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Borsigstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Borsigstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-833290988</LinkId> + <Shape>52.5280571,13.3913355 52.5279846,13.3914194</Shape> + <Length>4.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>8.33</TrafficSpeed> + <TrafficTime>0.5</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Torstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Torstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+833290988</LinkId> + <Shape>52.5279846,13.3914194</Shape> + <Length>4.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>7.5</TrafficSpeed> + <TrafficTime>0.5</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Torstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Torstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+53499991</LinkId> + <Shape>52.5279846,13.3914194 52.5281792,13.3924217</Shape> + <Length>73.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>7.5</TrafficSpeed> + <TrafficTime>9.7</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>52.6</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Torstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Torstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53500024</LinkId> + <Shape>52.5281792,13.3924217 52.5276413,13.392765 52.527504,13.3928776</Shape> + <Length>88.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>63.4</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>63.4</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53520166</LinkId> + <Shape>52.527504,13.3928776 52.5274544,13.3929157</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Linienstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Linienstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+53520166</LinkId> + <Shape>52.5274544,13.3929157</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Linienstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Linienstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53500091</LinkId> + <Shape>52.5274544,13.3929157 52.5274773,13.3929968</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+53500091</LinkId> + <Shape>52.5274773,13.3929968</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53500091</LinkId> + <Shape>52.5274773,13.3929968 52.5264435,13.3935556</Shape> + <Length>126.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>90.7</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>90.7</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+53500090</LinkId> + <Shape>52.5264435,13.3935556 52.5263863,13.3935757</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Auguststraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Auguststraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53500090</LinkId> + <Shape>52.5263863,13.3935757</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Auguststraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Auguststraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-844906239</LinkId> + <Shape>52.5263863,13.3935757 52.5262947,13.3935919 52.525425,13.393137</Shape> + <Length>112.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>80.6</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>80.6</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-844906238</LinkId> + <Shape>52.525425,13.393137 52.5249977,13.3929052</Shape> + <Length>54.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>38.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>38.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53501113</LinkId> + <Shape>52.5249977,13.3929052 52.5249405,13.3928967</Shape> + <Length>4.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+53501113</LinkId> + <Shape>52.5249405,13.3928967</Shape> + <Length>4.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53501113</LinkId> + <Shape>52.5249405,13.3928967 52.5246468,13.3941231</Shape> + <Length>92.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>66.2</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>66.2</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + </Leg> + <Summary> + <Distance>1107.0</Distance> + <TrafficTime>798.0</TrafficTime> + <BaseTime>798.0</BaseTime> + <Flags>noThroughRoad</Flags> + </Summary> + </Route> + </Response> +</rtcr:CalculateRoute>
\ No newline at end of file diff --git a/tests/auto/nokia_services/routing/travelmode-public-transport.xml b/tests/auto/nokia_services/routing/travelmode-public-transport.xml new file mode 100644 index 00000000..cf146ea5 --- /dev/null +++ b/tests/auto/nokia_services/routing/travelmode-public-transport.xml @@ -0,0 +1,343 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes"?> +<rtcr:CalculateRoute xmlns:rtcr="http://www.navteq.com/lbsp/Routing-CalculateRoute/4"> + <Response> + <MetaInfo> + <Timestamp>2012-04-26T14:49:40.902Z</Timestamp> + <AdditionalData key="CurrentTrafficLastUpdate">2012-04-26T14:47:00.026+0000</AdditionalData> + <AdditionalData key="CurrentTrafficElementsCount">5094886</AdditionalData> + <AdditionalData key="LongTermClosureLastUpdate">2012-04-26T14:47:02.494+0000</AdditionalData> + <AdditionalData key="LongTermClosureElementsCount">12015</AdditionalData> + <AdditionalData key="ShortTermClosureLastUpdate">2012-04-26T14:47:02.494+0000</AdditionalData> + <AdditionalData key="ShortTermClosureElementsCount">857</AdditionalData> + <AdditionalData key="Map0">2011Q3</AdditionalData> + <AdditionalData key="Module0">routeserver,9.2-2012.02.20-hotfix6.2.13.1</AdditionalData> + <AdditionalData key="Module0ExecTime">142</AdditionalData> + <AdditionalData key="Service">routing-route-service,6.2.13.1</AdditionalData> + </MetaInfo> + <Route> + <RouteId>REMvTwUAAAB4tdyZCURKQJROJJhqxipAAAAAYAlESkAAAADAasYqQAAAAAAAAPB_AAAAAAAA8H-XVzADV_SHZp4MKQHNgLOULCerAAEAAICiDCkBAQAAADAnqwABAAAAAADA_wEAAAAAAMD_HY0-84f6AgAAvBcAABjgZf7_Hyzz__8Hkw</RouteId> + <Waypoint> + <LinkId>+53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Waypoint> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Waypoint> + <Mode> + <Type>fastestNow</Type> + <TransportModes>publicTransport</TransportModes> + <TrafficMode>enabled</TrafficMode> + </Mode> + <Shape>52.5315819,13.3875275 52.5315819,13.3880997 52.5316086,13.3882599 52.5323792,13.3873796 52.5251007,13.3922596 52.5251007,13.3922596 52.5249786,13.3928604 52.5249443,13.3928757 52.5246468,13.3941231</Shape> + <BoundingBox> + <TopLeft> + <Latitude>52.5323792</Latitude> + <Longitude>13.3873796</Longitude> + </TopLeft> + <BottomRight> + <Latitude>52.5246468</Latitude> + <Longitude>13.3941231</Longitude> + </BottomRight> + </BoundingBox> + <Leg> + <Start> + <LinkId>+53499799</LinkId> + <MappedPosition> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.531543</Latitude> + <Longitude>13.387532</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </Start> + <End> + <LinkId>-53501113</LinkId> + <MappedPosition> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </MappedPosition> + <OriginalPosition> + <Latitude>52.524646</Latitude> + <Longitude>13.394128</Longitude> + </OriginalPosition> + <Type>stopOver</Type> + </End> + <Length>1388.0</Length> + <TravelTime>641.3</TravelTime> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M1"> + <Position> + <Latitude>52.5315361</Latitude> + <Longitude>13.3875332</Longitude> + </Position> + <Instruction>Head toward Borsigstraße on Invalidenstraße. Go for 100 feet.</Instruction> + <TravelTime>27.4</TravelTime> + <Length>38.0</Length> + <ToLink>+53499799</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M2"> + <Position> + <Latitude>52.5315819</Latitude> + <Longitude>13.3880997</Longitude> + </Position> + <Instruction>Leave Invalidenstraße Go for 400 feet.</Instruction> + <TravelTime>115.7</TravelTime> + <Length>115.0</Length> + <ToLink>+1525</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PublicTransportManeuverType" id="M3"> + <Position> + <Latitude>52.5323792</Latitude> + <Longitude>13.3873796</Longitude> + </Position> + <Instruction>Take REGIONALMETRO "?es "?ains (Deutsche Bahn), departure 18:55.</Instruction> + <TravelTime>378.7</TravelTime> + <Length>1092.0</Length> + <StopName></StopName> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M4"> + <Position> + <Latitude>52.5251007</Latitude> + <Longitude>13.3922596</Longitude> + </Position> + <Instruction>Go through the virtual connection. Go for 150 feet.</Instruction> + <TravelTime>47.4</TravelTime> + <Length>43.0</Length> + <ToLink>-3281</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M5"> + <Position> + <Latitude>52.5249786</Latitude> + <Longitude>13.3928604</Longitude> + </Position> + <Instruction>Turn right and cross Tucholskystraße.</Instruction> + <TravelTime>6.0</TravelTime> + <Length>8.0</Length> + <ToLink>-53501259</ToLink> + <Direction>right</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M6"> + <Position> + <Latitude>52.5249786</Latitude> + <Longitude>13.3928604</Longitude> + </Position> + <Instruction>Continue on Oranienburger Straße. Go for 300 feet.</Instruction> + <TravelTime>66.2</TravelTime> + <Length>92.0</Length> + <ToLink>-53501113</ToLink> + <Direction>forward</Direction> + </Maneuver> + <Maneuver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportManeuverType" id="M7"> + <Position> + <Latitude>52.5246773</Latitude> + <Longitude>13.3941345</Longitude> + </Position> + <Instruction>Your destination on Oranienburger Straße is on the right. The trip takes 0.9 miles and 11 mins.</Instruction> + <TravelTime>0.0</TravelTime> + <Length>0.0</Length> + <Direction>forward</Direction> + </Maneuver> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+53499799</LinkId> + <Shape>52.5315819,13.3875275 52.5315819,13.3880997</Shape> + <Length>38.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>7.77</TrafficSpeed> + <TrafficTime>4.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>27.4</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Invalidenstraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Invalidenstraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+1525</LinkId> + <Shape>52.5315819,13.3880997 52.5316086,13.3882599</Shape> + <Length>11.0</Length> + <SpeedLimit>1.39</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>7.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>7.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Nordbahnhof</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Nordbahnhof</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+1519</LinkId> + <Shape>52.5316086,13.3882599 52.5323792,13.3873796</Shape> + <Length>104.0</Length> + <SpeedLimit>1.39</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>74.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>74.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Nordbahnhof</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Nordbahnhof</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PublicTransportLinkType"> + <LinkId>-8016</LinkId> + <Shape>52.5323792,13.3873796 52.5251007,13.3922596</Shape> + <Length>1092.0</Length> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-3281</LinkId> + <Shape>52.5251007,13.3922596 52.5251007,13.3922596</Shape> + <Length>1.0</Length> + <SpeedLimit>1.39</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>0.7</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>0.7</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-3284</LinkId> + <Shape>52.5251007,13.3922596 52.5249786,13.3928604</Shape> + <Length>42.0</Length> + <SpeedLimit>1.39</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>30.2</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>30.2</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53501259</LinkId> + <Shape>52.5249786,13.3928604 52.5249443,13.3928757</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>+53501259</LinkId> + <Shape>52.5249443,13.3928757</Shape> + <Length>4.0</Length> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>2.9</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>2.9</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Tucholskystraße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Tucholskystraße</Street> + </Address> + </Link> + <Link xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xsi:type="rtc:PrivateTransportLinkType"> + <LinkId>-53501113</LinkId> + <Shape>52.5249443,13.3928757 52.5246468,13.3941231</Shape> + <Length>92.0</Length> + <SpeedLimit>13.89</SpeedLimit> + <DynamicSpeedInfo> + <TrafficSpeed>1.39</TrafficSpeed> + <TrafficTime>66.2</TrafficTime> + <BaseSpeed>1.39</BaseSpeed> + <BaseTime>66.2</BaseTime> + </DynamicSpeedInfo> + <Address> + <Label>Oranienburger Straße</Label> + <Country>DE</Country> + <State>Berlin</State> + <County>Berlin</County> + <City>Berlin</City> + <District>Mitte</District> + <Street>Oranienburger Straße</Street> + </Address> + </Link> + </Leg> + <Summary> + <Distance>1388.0</Distance> + <TrafficTime>641.0</TrafficTime> + <BaseTime>641.0</BaseTime> + <Flags>noThroughRoad</Flags> + <Flags>unpaved</Flags> + <Flags>publicTransport</Flags> + </Summary> + </Route> + </Response> +</rtcr:CalculateRoute>
\ No newline at end of file diff --git a/tests/auto/nokia_services/routing/tst_routing.cpp b/tests/auto/nokia_services/routing/tst_routing.cpp new file mode 100644 index 00000000..7e1ba540 --- /dev/null +++ b/tests/auto/nokia_services/routing/tst_routing.cpp @@ -0,0 +1,533 @@ +/**************************************************************************** +** +** Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies). +** Contact: http://www.qt-project.org/ +** +** This file is part of the test suite of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** GNU Lesser General Public License Usage +** This file may be used under the terms of the GNU Lesser General Public +** License version 2.1 as published by the Free Software Foundation and +** appearing in the file LICENSE.LGPL included in the packaging of this +** file. Please review the following information to ensure the GNU Lesser +** General Public License version 2.1 requirements will be met: +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** In addition, as a special exception, Nokia gives you certain additional +** rights. These rights are described in the Nokia Qt LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU General +** Public License version 3.0 as published by the Free Software Foundation +** and appearing in the file LICENSE.GPL included in the packaging of this +** file. Please review the following information to ensure the GNU General +** Public License version 3.0 requirements will be met: +** http://www.gnu.org/copyleft/gpl.html. +** +** Other Usage +** Alternatively, this file may be used in accordance with the terms and +** conditions contained in a signed written agreement between you and Nokia. +** +** +** +** +** +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#include <qgeonetworkaccessmanager.h> +#include <qgeoroutereply_nokia.h> + +#include <QtTest/QtTest> +#include <QDebug> +#include <QNetworkReply> +#include <QtLocation/QGeoRouteReply> +#include <QtLocation/QGeoServiceProvider> +#include <QtLocation/QGeoRoutingManager> +#include <QtLocation/QGeoBoundingBox> +#include <QtLocation/QGeoManeuver> +#include <QtLocation/QGeoRouteSegment> + +QT_USE_NAMESPACE + +#define CHECK_CLOSE_E(expected, actual, e) QVERIFY((qAbs(actual - expected) <= e)) +#define CHECK_CLOSE(expected, actual) CHECK_CLOSE_E(expected, actual, qreal(1e-6)) + +class MockGeoNetworkReply : public QNetworkReply +{ +public: + MockGeoNetworkReply( QObject* parent = 0); + virtual void abort(); + + void setFile(QFile* file); + void complete(); + using QNetworkReply::setRequest; + using QNetworkReply::setOperation; + using QNetworkReply::setError; + +protected: + virtual qint64 readData(char *data, qint64 maxlen); + virtual qint64 writeData(const char *data, qint64 len); + +private: + QFile* m_file; +}; + +MockGeoNetworkReply::MockGeoNetworkReply(QObject* parent) +: QNetworkReply(parent) +, m_file(0) +{ + setOpenMode(QIODevice::ReadOnly); +} + +void MockGeoNetworkReply::abort() +{} + +qint64 MockGeoNetworkReply::readData(char *data, qint64 maxlen) +{ + if (m_file) { + const qint64 read = m_file->read(data, maxlen); + if (read <= 0) + return -1; + return read; + } + return -1; +} + +qint64 MockGeoNetworkReply::writeData(const char *data, qint64 len) +{ + Q_UNUSED(data); + Q_UNUSED(len); + return -1; +} + +void MockGeoNetworkReply::setFile(QFile* file) +{ + delete m_file; + m_file = file; + if (m_file) + m_file->setParent(this); +} + +void MockGeoNetworkReply::complete() +{ + if (error() != QNetworkReply::NoError) + emit error(error()); + setFinished(true); + emit finished(); +} + +class MockGeoNetworkAccessManager : public QGeoNetworkAccessManager +{ +public: + MockGeoNetworkAccessManager(QObject* parent = 0); + QNetworkReply* get(const QNetworkRequest& request); + QNetworkReply *post(const QNetworkRequest &request, const QByteArray &data); + + void setReply(MockGeoNetworkReply* reply); + +private: + MockGeoNetworkReply* m_reply; +}; + +MockGeoNetworkAccessManager::MockGeoNetworkAccessManager(QObject* parent) +: QGeoNetworkAccessManager(parent) +, m_reply(0) +{} + +QNetworkReply* MockGeoNetworkAccessManager::get(const QNetworkRequest& request) +{ + MockGeoNetworkReply* r = m_reply; + m_reply = 0; + if (r) { + r->setRequest(request); + r->setOperation(QNetworkAccessManager::GetOperation); + r->setParent(0); + } + + return r; +} + +QNetworkReply* MockGeoNetworkAccessManager::post(const QNetworkRequest &request, const QByteArray &data) +{ + Q_UNUSED(request); + Q_UNUSED(data); + QTest::qFail("Not implemented", __FILE__, __LINE__); + return new MockGeoNetworkReply(); +} + +void MockGeoNetworkAccessManager::setReply(MockGeoNetworkReply* reply) +{ + delete m_reply; + m_reply = reply; + if (m_reply) + m_reply->setParent(this); +} + +class tst_routing : public QObject +{ + Q_OBJECT + +public: + tst_routing(); + +private: + void calculateRoute(); + void loadReply(const QString& filename); + void onReply(QGeoRouteReply* reply); + void verifySaneRoute(const QGeoRoute& route); + + // Infrastructure slots +private Q_SLOTS: + void routingFinished(QGeoRouteReply* reply); + void routingError(QGeoRouteReply* reply, QGeoRouteReply::Error error, QString errorString); + + // Test slots +private Q_SLOTS: + void initTestCase(); + void cleanupTestCase(); + void cleanup(); + void can_compute_route_for_all_supported_travel_modes(); + void can_compute_route_for_all_supported_travel_modes_data(); + void can_compute_route_for_all_supported_optimizations(); + void can_compute_route_for_all_supported_optimizations_data(); + void can_handle_multiple_routes_in_response(); + void can_handle_no_route_exists_case(); + void can_handle_invalid_server_responses(); + void can_handle_invalid_server_responses_data(); + void can_handle_additions_to_routing_xml(); + void foobar(); + void foobar_data(); + +private: + QGeoServiceProvider* m_geoServiceProvider; + MockGeoNetworkAccessManager* m_networkManager; + QGeoRoutingManager* m_routingManager; + QGeoRouteReply* m_reply; + MockGeoNetworkReply* m_replyUnowned; + QGeoRouteRequest m_dummyRequest; + bool m_calculationDone; + bool m_expectError; +}; + +tst_routing::tst_routing() +: m_geoServiceProvider(0) +, m_networkManager(0) +, m_routingManager(0) +, m_reply(0) +, m_replyUnowned() +, m_calculationDone(true) +, m_expectError(false) +{ +} + +void tst_routing::loadReply(const QString& filename) +{ + QFile* file = new QFile(filename); + if (!file->open(QIODevice::ReadOnly)) { + delete file; + file = 0; + qDebug() << filename; + QTest::qFail("Failed to open file", __FILE__, __LINE__); + } + + m_replyUnowned = new MockGeoNetworkReply(); + m_replyUnowned->setFile(file); + m_networkManager->setReply(m_replyUnowned); +} + +void tst_routing::calculateRoute() +{ + QVERIFY2(m_replyUnowned, "No reply set"); + m_calculationDone = false; + m_routingManager->calculateRoute(m_dummyRequest); + m_replyUnowned->complete(); + m_replyUnowned = 0; + QTRY_VERIFY_WITH_TIMEOUT(m_calculationDone, 100); +} + +void tst_routing::onReply(QGeoRouteReply* reply) +{ + QVERIFY(reply); + //QVERIFY(0 == m_reply); + m_reply = reply; + if (m_reply) + m_reply->setParent(0); + m_calculationDone = true; +} + +void tst_routing::verifySaneRoute(const QGeoRoute& route) +{ + QVERIFY(route.distance() > 0); + QVERIFY(route.travelTime() > 0); + QVERIFY(route.travelMode() != 0); + + const QGeoBoundingBox bounds = route.bounds(); + QVERIFY(bounds.width() > 0); + QVERIFY(bounds.height() > 0); + + const QList<QGeoCoordinate> path = route.path(); + QVERIFY(path.size() >= 2); + + foreach (const QGeoCoordinate& coord, path) { + QVERIFY(coord.isValid()); + QVERIFY(bounds.contains(coord)); + } + + QGeoRouteSegment segment = route.firstRouteSegment(); + bool first = true, last = false; + + do { + const QGeoRouteSegment next = segment.nextRouteSegment(); + last = next.isValid(); + + QVERIFY(segment.isValid()); + QVERIFY(segment.distance() >= 0); + QVERIFY(segment.travelTime() >= 0); // times are rounded and thus may end up being zero + + const QList<QGeoCoordinate> path = segment.path(); + foreach (const QGeoCoordinate& coord, path) { + QVERIFY(coord.isValid()); + if (!first && !last) { + QVERIFY(bounds.contains(coord)); // on pt and pedestrian + } + } + + const QGeoManeuver maneuver = segment.maneuver(); + + if (maneuver.isValid()) { + QVERIFY(!maneuver.instructionText().isEmpty()); + QVERIFY(maneuver.position().isValid()); + if (!first && !last) { + QVERIFY(bounds.contains(maneuver.position())); // on pt and pedestrian + } + } + + segment = next; + first = false; + } while (!last); +} + +void tst_routing::routingFinished(QGeoRouteReply* reply) +{ + onReply(reply); +} + +void tst_routing::routingError(QGeoRouteReply* reply, QGeoRouteReply::Error error, QString errorString) +{ + Q_UNUSED(error); + + if (!m_expectError) { + QFAIL(qPrintable(errorString)); + } else { + onReply(reply); + } +} + +void tst_routing::initTestCase() +{ + QStringList providers = QGeoServiceProvider::availableServiceProviders(); + QVERIFY(providers.contains(QStringLiteral("nokia"))); + + m_networkManager = new MockGeoNetworkAccessManager(); + + QMap<QString, QVariant> parameters; + parameters.insert(QStringLiteral("nam"), QVariant::fromValue<void*>(m_networkManager)); + + m_geoServiceProvider = new QGeoServiceProvider(QStringLiteral("nokia"), parameters); + QVERIFY(m_geoServiceProvider); + + m_routingManager = m_geoServiceProvider->routingManager(); + QVERIFY(m_routingManager); + + connect(m_routingManager, SIGNAL(finished(QGeoRouteReply*)), + this, SLOT(routingFinished(QGeoRouteReply*))); + connect(m_routingManager, SIGNAL(error(QGeoRouteReply*,QGeoRouteReply::Error,QString)), + this, SLOT(routingError(QGeoRouteReply*,QGeoRouteReply::Error,QString))); + + QList<QGeoCoordinate> waypoints; + waypoints.push_back(QGeoCoordinate(1, 1)); + waypoints.push_back(QGeoCoordinate(2, 2)); + m_dummyRequest.setWaypoints(waypoints); +} + +void tst_routing::cleanupTestCase() +{ + delete m_geoServiceProvider; + + // network access manager will be deleted by plugin + + m_geoServiceProvider = 0; + m_networkManager = 0; + m_routingManager = 0; +} + +void tst_routing::cleanup() +{ + delete m_reply; + m_reply = 0; + m_replyUnowned = 0; + m_expectError = false; +} + +void tst_routing::can_compute_route_for_all_supported_travel_modes() +{ + QFETCH(int, travelMode); + QFETCH(QString, file); + QFETCH(qreal, distance); + QFETCH(int, duration); + + loadReply(file); + calculateRoute(); + + QList<QGeoRoute> routes = m_reply->routes(); + QCOMPARE(1, routes.size()); + QGeoRoute& route = routes[0]; + QCOMPARE(travelMode, (int)route.travelMode()); + CHECK_CLOSE(distance, route.distance()); + QCOMPARE(duration, route.travelTime()); + verifySaneRoute(route); +} + +void tst_routing::can_compute_route_for_all_supported_travel_modes_data() +{ + QTest::addColumn<int>("travelMode"); + QTest::addColumn<QString>("file"); + QTest::addColumn<qreal>("distance"); + QTest::addColumn<int>("duration"); + + QTest::newRow("Car") << (int)QGeoRouteRequest::CarTravel << QString("travelmode-car.xml") << (qreal)1271.0 << 243; + QTest::newRow("Pedestrian") << (int)QGeoRouteRequest::PedestrianTravel << QString("travelmode-pedestrian.xml") << (qreal)1107.0 << 798; + QTest::newRow("Public Transport") << (int)QGeoRouteRequest::PublicTransitTravel << QString("travelmode-public-transport.xml") << (qreal)1388.0 << 641; +} + +void tst_routing::can_compute_route_for_all_supported_optimizations() +{ + QFETCH(int, optimization); + Q_UNUSED(optimization); + QFETCH(QString, file); + QFETCH(qreal, distance); + QFETCH(int, duration); + + loadReply(file); + calculateRoute(); + QList<QGeoRoute> routes = m_reply->routes(); + QCOMPARE(1, routes.size()); + QGeoRoute& route = routes[0]; + CHECK_CLOSE(distance, route.distance()); + QCOMPARE(duration, route.travelTime()); + verifySaneRoute(route); +} + +void tst_routing::can_compute_route_for_all_supported_optimizations_data() +{ + QTest::addColumn<int>("optimization"); + QTest::addColumn<QString>("file"); + QTest::addColumn<qreal>("distance"); + QTest::addColumn<int>("duration"); + + QTest::newRow("Shortest") << (int)QGeoRouteRequest::ShortestRoute << QString("optim-shortest.xml") << qreal(1177.0) << 309; + QTest::newRow("Fastest") << (int)QGeoRouteRequest::FastestRoute << QString("optim-fastest.xml") << qreal(1271.0) << 243; + QTest::newRow("Most Econonic") << (int)QGeoRouteRequest::MostEconomicRoute << QString("optim-economic.xml") << qreal(1177.0) << 309; + QTest::newRow("Most Scenic") << (int)QGeoRouteRequest::MostScenicRoute << QString("optim-scenic.xml") << qreal(1177.0) << 309; +} + + +void tst_routing::can_handle_multiple_routes_in_response() +{ + loadReply(QStringLiteral("multiple-routes-in-response.xml")); + calculateRoute(); + QList<QGeoRoute> routes = m_reply->routes(); + QCOMPARE(2, routes.size()); + + verifySaneRoute(routes[0]); + verifySaneRoute(routes[1]); +} + +void tst_routing::can_handle_no_route_exists_case() +{ + loadReply(QStringLiteral("error-no-route.xml")); + calculateRoute(); + QCOMPARE(QGeoRouteReply::NoError, m_reply->error()); + QList<QGeoRoute> routes = m_reply->routes(); + QCOMPARE(0, routes.size()); +} + +void tst_routing::can_handle_additions_to_routing_xml() +{ + loadReply(QStringLiteral("littered-with-new-tags.xml")); + calculateRoute(); + QCOMPARE(QGeoRouteReply::NoError, m_reply->error()); + QList<QGeoRoute> routes = m_reply->routes(); + QVERIFY(routes.size() > 0); +} + +void tst_routing::can_handle_invalid_server_responses() +{ + QFETCH(QString, file); + + m_expectError = true; + + loadReply(file); + calculateRoute(); + QCOMPARE(QGeoRouteReply::ParseError, m_reply->error()); +} + +void tst_routing::can_handle_invalid_server_responses_data() +{ + QTest::addColumn<QString>("file"); + + QTest::newRow("Trash") << QString("invalid-response-trash.xml"); + QTest::newRow("Half way through") << QString("invalid-response-half-way-through.xml"); + QTest::newRow("No <CalculateRoute> tag") << QString("invalid-response-no-calculateroute-tag.xml"); +} + +void tst_routing::foobar() +{ + QFETCH(int, code); + + m_expectError = true; + m_replyUnowned = new MockGeoNetworkReply(); + m_replyUnowned->setError(static_cast<QNetworkReply::NetworkError>(code), QStringLiteral("Test error")); + m_networkManager->setReply(m_replyUnowned); + calculateRoute(); + QCOMPARE(QGeoRouteReply::CommunicationError, m_reply->error()); +} + +void tst_routing::foobar_data() +{ + QTest::addColumn<int>("code"); + + QTest::newRow("QNetworkReply::ConnectionRefusedError") << int(QNetworkReply::ConnectionRefusedError); + QTest::newRow("QNetworkReply::RemoteHostClosedError") << int(QNetworkReply::RemoteHostClosedError); + QTest::newRow("QNetworkReply::HostNotFoundError") << int(QNetworkReply::HostNotFoundError); + QTest::newRow("QNetworkReply::TimeoutError") << int(QNetworkReply::TimeoutError); + QTest::newRow("QNetworkReply::OperationCanceledError") << int(QNetworkReply::OperationCanceledError); + QTest::newRow("QNetworkReply::SslHandshakeFailedError") << int(QNetworkReply::SslHandshakeFailedError); + QTest::newRow("QNetworkReply::TemporaryNetworkFailureError") << int(QNetworkReply::TemporaryNetworkFailureError); + QTest::newRow("QNetworkReply::ProxyConnectionRefusedError") << int(QNetworkReply::ProxyConnectionRefusedError); + QTest::newRow("QNetworkReply::ProxyConnectionClosedError") << int(QNetworkReply::ProxyConnectionClosedError); + QTest::newRow("QNetworkReply::ProxyNotFoundError") << int(QNetworkReply::ProxyNotFoundError); + QTest::newRow("QNetworkReply::ProxyTimeoutError") << int(QNetworkReply::ProxyTimeoutError); + QTest::newRow("QNetworkReply::ProxyAuthenticationRequiredError") << int(QNetworkReply::ProxyAuthenticationRequiredError); + QTest::newRow("QNetworkReply::ContentAccessDenied") << int(QNetworkReply::ContentAccessDenied); + QTest::newRow("QNetworkReply::ContentOperationNotPermittedError") << int(QNetworkReply::ContentOperationNotPermittedError); + QTest::newRow("QNetworkReply::ContentNotFoundError") << int(QNetworkReply::ContentNotFoundError); + QTest::newRow("QNetworkReply::ContentReSendError") << int(QNetworkReply::ContentReSendError); + QTest::newRow("QNetworkReply::ProtocolUnknownError") << int(QNetworkReply::ProtocolUnknownError); + QTest::newRow("QNetworkReply::ProtocolInvalidOperationError") << int(QNetworkReply::ProtocolInvalidOperationError); + QTest::newRow("QNetworkReply::UnknownNetworkError") << int(QNetworkReply::UnknownNetworkError); + QTest::newRow("QNetworkReply::UnknownProxyError") << int(QNetworkReply::UnknownProxyError); + QTest::newRow("QNetworkReply::ProxyAuthenticationRequiredError") << int(QNetworkReply::ProxyAuthenticationRequiredError); + QTest::newRow("QNetworkReply::UnknownContentError") << int(QNetworkReply::UnknownContentError); + QTest::newRow("QNetworkReply::ProtocolFailure") << int(QNetworkReply::ProtocolFailure); +} + + +QTEST_APPLESS_MAIN(tst_routing) + +#include "tst_routing.moc" |