[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: luasoap element addressing
- From: Tomás Guisasola <tomasguisasola@...>
- Date: Fri, 22 Nov 2019 09:15:16 -0300
> Does anybody use luasoap?
> In their examples here https://tomasguisasola.github.io/luasoap/examples.html they are addressing to elements by index, for example ent. Is it possible to address by tag?
You have to convert the structure (which comes from LuaExpat's LOM) or
implement a search function. There are many ways to do it, depending
on your case. For example, sometimes you are dealing with some kind
of structure such as a tree, then it seems reasonable to produce a
table with string entries for each tag. But sometimes you have a
sequence of equal tags; then you'd prefer some form of an array. I
have a suite of functions that combine all of these in a general form.
If you are interested, I can pack it and share...