I have xml of the format:
<channel>
<games>
<game slot='1'>
<id>Bric A Bloc</id>
<title-text>BricABloc Hoorah</title-text>
<link>Fruit Splat</link>
</game>
</games>
</channel>
I've parsed this xml using lxml.objectify
, via:
tree = objectify.parse(file)
There will potentially be a number of <game>
s underneath <games>
.
I understand that I can generate a list of <game>
objects via:
[ tree.games[0].game[0:4] ]
My question is, what class are those objects and is there a function to print any object of whatever class these objects belong to?