File: getstarted.rst

package info (click to toggle)
python-dicttoxml2 2.1.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 196 kB
  • sloc: python: 377; makefile: 10; sh: 5
file content (24 lines) | stat: -rw-r--r-- 612 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
Installation
============

The dicttoxml module is [published on the Python Package Index](https://pypi.python.org/pypi/dicttoxml2), so you can install it using `pip`.

    pip install dicttoxml2

That should be all you need to do.

Basic Usage
===========

Once installed, import the library into your script and convert a dict into xml by running the `dicttoxml` function:

    >>> import dicttoxml2
    >>> xml = dicttoxml2.dicttoxml(some_dict)

Alternately, you can import the `dicttoxml()` function from the library.

    >>> from dicttoxml2 import dicttoxml
    >>> xml = dicttoxml(some_dict)

That's it!