Can I create a simulated route with a GPX file in android like you can with the IOS SDK? I don't see a GPXLocationDataSource like what is in ios SDK.
Solved! Go to Solution.
You are correct Android doesn't have the GPXLocationDataSource class yet, but there is an easy way of achieving the same.
The GPX file is just an XML file, so if you can open it to get your coordinates you can pass these into a SimulatedDataSource which will show the positions on your LocationDisplay.
There isn't a specific Android sample for using the SimulatedLocationSource class, but you can take a look at the JavaFX (ArcGIS Runtime for Java) sample and you will see how to use it. Under the covers the Android and Java APIs share quite a lot of the same codebase.
Does this help?
You are correct Android doesn't have the GPXLocationDataSource class yet, but there is an easy way of achieving the same.
The GPX file is just an XML file, so if you can open it to get your coordinates you can pass these into a SimulatedDataSource which will show the positions on your LocationDisplay.
There isn't a specific Android sample for using the SimulatedLocationSource class, but you can take a look at the JavaFX (ArcGIS Runtime for Java) sample and you will see how to use it. Under the covers the Android and Java APIs share quite a lot of the same codebase.
Does this help?