PickwickSoft / pystreamapi

The Python Stream API Library offering Streams like you know from Java/Kotlin/Scala in Python with some cool extensions
https://pystreamapi.pickwicksoft.org/
GNU General Public License v3.0
30 stars 5 forks source link

Data loader for XML #72

Closed garlontas closed 10 months ago

garlontas commented 1 year ago

XML data loader

Currently, we have a data loader for CSV files. It works by converting each data set (each row) to a namedtuple.

We need sth similar for XML. Note that type conversion should be done as efficient as possible (see issue #63 for more information).

The loader should also handle non-consistent data, such as the XML below:

<employees>
    <employee>
        <name>John Doe</name>
        <position>Software Engineer</position>
        <salary>80000</salary>
        <children>2</children>
    </employee>
    <employee>
        <name>Alice Smith</name>
        <position>Network Administrator</position>
        <salary>75000</salary>
        <children>1</children>
    </employee>
    <employee>
        <name>Bob Johnson</name>
        <experience>Database</experience>
        <wage>82000</wage>
        <car>Audi</car>
    </employee>
</employees>

Here, a LazyFileIterable containing three differently structured namedtuples should be created.

You can view the implementation for CSV here.

You can view the issue for the JSON loader here: #70

You can view the issue for the YAML loader here: #71

Preetraj2002 commented 1 year ago

Hey @garlontas i am new to open source and i am looking for tasks which could help me expand my knowledge. issue #71 #72 and #73 would help understand the formatting in these file types. Kindly assign me the task so i can start working on these