Latest Questions tagged Xml

Browse all latest questions tagged Xml

36
Votes
Published 15 Sep, 2022
Java - Marshalling and Unmarshalling with XML and Java

I am trying to marshall Java to XML and unmarshall that file back into Java. I am working with an ArrayList and still quite new at programming. Any guidance would be much appreciated. Here is my save...

99
Votes
Published 10 Jun, 2022
Python - No module named urllib3

I wrote a script to call an API and ran it successfully last week. This week, it won't run. I get back the following error message: Traceback (most recent call last): File "user_audit.py", line 2,...

45
Votes
Published 15 Sep, 2022
Java - Binary XML file line #7: You must supply a layout_width attribute

<?xml version="1.0" encoding="utf-8"?> <FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent"...

80
Votes
Published 14 Sep, 2022
Java - Java error: Unable to initialize main class

I am trying to run this code but I get the following error. package practicaXML; import javax.xml.xquery.*; import org.w3c.dom.Node; import net.xqj.basex.BaseXXQDataSource; public class App { pu...

51
Votes
Published 19 Sep, 2022
Java - DrawerLayout and NavigationView - attribute 'menu' not found

I'm trying to add a Navigation Menu to an existing project in Android Studio. However, while following the instructions on the official website, I added a <android.support.v4.widget.DrawerLayout .....

35
Votes
Published 18 Sep, 2022
Java - How to know if a tag contains a value or another tag?

I am using DOM representations in java how can I distinguish if an xml tag has a value inside it or has another embedded tag ? For example, I can have : <item> 2 </item> or <item&g...

18
Votes
Published 28 Jun, 2022
Python - Python - Convert Very Large (6.4GB) XML files to JSON

Essentially, I have a 6.4GB XML file that I'd like to convert to JSON then save it to disk. I'm currently running OSX 10.8.4 with an i7 2700k and 16GBs of ram, and running Python 64bit (double checked...

122
Votes
Published 15 Sep, 2022
Java - Maven adding mainClass in pom.xml with the right folder path

I want to get a working jar file with my maven project. The build part is: <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId&gt...

45
Votes
Published 26 Apr, 2022
Python - How to convert an XML file to nice pandas dataframe?

Let's assume that I have an XML like this: <author type="XXX" language="EN" gender="xx" feature="xx" web="foobar.com"> <documents count=&...

67
Votes
Published 31 Aug, 2022
Java - how to create an InputStream from a Document or Node

How can I create an InputStream object from a XML Document or Node object to be used in xstream? I need to replace the ??? with some meaningful code. Thanks. Document doc = getDocument(); InputStre...

10
Votes
Published 24 Apr, 2022
Python - How to search and replace text in an XML file using Python?

How do I search an entire xml file for a specific text pattern and then replace each occurrence of that text with new text pattern in Python 3.5? Everything else (format, attributes, comments, etc....

24
Votes
Published 11 Apr, 2022
Python - How to convert XML to JSON in Python?

Possible Duplicate: Converting XML to JSON using Python? I'm doing some work on App Engine and I need to convert an XML document being retrieved from a remote server into an equivalent JSON...

90
Votes
Published 12 Sep, 2022
Java - JAXB: How to ignore namespace during unmarshalling XML document?

My schema specifies a namespace, but the documents don't. What's the simplest way to ignore namespace during JAXB unmarshalling (XML -> object)? In other words, I have <foo><bar></bar...

128
Votes
Published 10 Jun, 2022
Python - Write xml file using lxml library in Python

I'm using lxml to create an XML file from scratch; having a code like this: from lxml import etree root = etree.Element("root") root.set("interesting", "somewhat") child1 = etree.SubElement(root, "t...

76
Votes
Published 25 Aug, 2022
Python - How to extract elements by tagName from XML URL using Selenium Python

I'm trying to find elements by tag name like Titles from this XML URL http://www.rssmix.com/u/8287461/rss.xml but unable it's not working please help It is just printing a blank page and nothing else...