No need to create a temp file. Unless the resulting code is huge, you can ge=
nerate in memory and eval (once) the whole thing.

Top-posted from my iPad

El 12 May 2011, a les 08:55, Stu <stu / rubyprogrammer.net> va escriure:
> I was going to suggest a creating a tmp file with a generator. create
> a sort of cached methods type thing.
>=20
> This may fix your issue.
>=20
> On Thu, May 12, 2011 at 1:37 AM, Zd Yu <zdyu2000 / gmail.com> wrote:
>> I just came up with an idea: I can parse the XML configuration file and
>> generate a .rb file on the fly then invoke the rb file.
>>=20
>> Although it brings much extra efforts, it can fix the performance issue.
>>=20
>> --
>> Posted via http://www.ruby-forum.com/.
>>=20
>>=20
>=20