[Laszlo-user] XML to Lazslo Object Mapping

jamesr circlecycle at gmail.com
Thu Apr 5 08:05:53 PDT 2007


Is it that you are looking for object notation to access dataset nodes?

something like:

	<dataset name="one">
		<entry name="a">
		<entry name="b">	
	</dataset>

	....

	dp = canvas.datasets.one.getPointer();
	//should write "a":
	Debug.write(dp.entry[0].name);

Without looking it up further, i was just curious if this is what you  
mean. Sometimes the selectNext/selectChild entries make a less  
compact looping structure in code. I'm sorta set-and-forget about  
this particular thing, myself.

James.

On Apr 5, 2007, at 5:35 AM, Tiago Cardoso wrote:

> Hello Francisco,
>
> I think that the dataset is evaluated and transformed in objects  
> since it has data.
>
> If you notice, they are all LzNodes.
> What do you want really to do ? Instantiate directly dataset nodes  
> to specific classes ?
>
> Take care,
>
> Tiago Cardoso
>
> On 4/4/07, Francisco Jose Peredo <fperedo at sefintab.gob.mx> wrote:
> Hi!
> Is there a way to "hide" the dataset, and present the XML inside the
> dataset as a collection of Laszlo "objects"?
> some kind of Object / DataSet Mapping? Can it be built? Is there an
> example somewhere?
> Thanks
> bye
>
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.openlaszlo.org/pipermail/laszlo-user/attachments/20070405/5385dfaa/attachment-0001.html


More information about the Laszlo-user mailing list