I am parsing some hardware format which finally I need to convert in xml.
The intermediate step is dicts.
So, the structure looks like this:
{chip_name:'myChip',chip_clock:'3.07',chip_peripherals:{peripheral1:{mode:'mode1',register:{}},peripheral2:{....},peripheral3:{...}}}

I think this example gives good insight into kind of dict structure I am
having. Now I want to have every dict tag as xml tag with hierarchy
maintained.

Thanks
Abhijeet

On Tue, Jun 15, 2010 at 11:09 PM, Stefan Behnel <stefan...@behnel.de> wrote:

> abhijeet thatte, 16.06.2010 03:05:
>
>  I am a novice Python user. I am using Python to parse some hardware
>> specifications and create xml files from them.
>> I generate dict of really huge sizes. (I am parsing some 10,000 register
>> definitions.)
>>
>
> Why do you need these intermediate dicts?
>
>
>
>  So, it looks like : {elem1,elem2, elem3,dict1,{elem4,elem5, dict2 {elem6,
>> elem7, dict3{.....}}}}.
>>
>
> What is this hierarchy of dicts mapping to what?
>
> It's always best to provide a short extract of a real example rather than
> something you made up.
>
> Stefan
>
>
> --
> http://mail.python.org/mailman/listinfo/python-list
>
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to