Erik <recon_nospam / dds.nl> writes:

> > > I want to be able to manipulate this data structure like f.i.:
> > >
> > > currentpage.articles[2].elements[5].content = 'Hello world'
> > >
> > > I am not sure if or how I can realise this, could somebody
> > > please give me a hint?
> >
> > You could use the wonderful new PerlValue package (available on
> > the RAA)
> 
> Thank you for your help, but do I really need a module to do
> something simple as this?

No, but if you want to write code in this style, and as PerlValue
already exists, it seemed the Pragmatic thing to do.

In Perl, articles, elements and soon would probably be arrays. In
Ruby, you _could_ use arrays or hashes, but you might also spend the
extra time to use classes dedicated to the job. In this case, you can
define whatever behavior you want for operators such as [].

Dave