Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android HOW TO #189

Open
savejeff opened this issue Feb 11, 2025 · 0 comments
Open

Android HOW TO #189

savejeff opened this issue Feb 11, 2025 · 0 comments

Comments

@savejeff
Copy link

savejeff commented Feb 11, 2025

For everybody struggling with getting it in Android to run/compile

build.gradle:



    compileOptions {
        // Enable support for the new language APIs
        coreLibraryDesugaringEnabled true

        sourceCompatibility JavaVersion.VERSION_17
        targetCompatibility JavaVersion.VERSION_17

    [...]

dependencies {
    [...]
    // GPX Library
    implementation 'io.jenetics:jpx:3.2.1'
    implementation 'javax.xml.stream:stax-api:1.0-2' // adds javax.xml.stream with XMLStreamWriter etc
    implementation 'com.fasterxml.woodstox:woodstox-core:6.4.0' // actual implementation of a XMLOutputFactory etc

}

	GPX gpx = GPX.builder()
			.addWayPoint(WayPoint.of(48.208174, 16.373819)) // Vienna
			.build();

	String gpxString = GPX.Writer.DEFAULT.toString(gpx);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant