Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to resolve javax.xml.bind.JAXBContext in Eclipse?

In my Android app I use:

import javax.xml.bind.JAXBContext;

But I get:

The import javax.xml.bind cannot be resolved

I do have com.viewstreet.java.eclipse.jaxbplugin.JAXBPlugin in my plugins list.

like image 209
MarcoS Avatar asked May 01 '11 16:05

MarcoS


1 Answers

@commonsware is correct , just add respctive JAXB API jars in lib folder of your projet or in case of maven project add dependency in pom file

<!-- https://mvnrepository.com/artifact/javax.xml.bind/jaxb-api -->
<dependency>
    <groupId>javax.xml.bind</groupId>
    <artifactId>jaxb-api</artifactId>
    <version>2.3.1</version>
</dependency>

viz in my case on linux, solved the issue

like image 161
shreeramaute Avatar answered Nov 06 '22 20:11

shreeramaute