velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ajay Gondhiya <a...@dset.com>
Subject Re: Str. lit. interpolation and ReferenceInsertionEventHandler
Date Wed, 20 Mar 2002 18:32:46 GMT
"Geir Magnusson Jr." wrote:

> On 3/20/02 1:13 PM, "Victor Salaman" <vsalaman@hotmail.com> wrote:
>
> > I have another idea, why not pass the context in which the event was fired
> > to the event...
>
> Ok - but that's really a different thing.  We can still look at that - but
> independent of that -
>
> Do we want to limit the RIE's to only when inerting into the outputstream?
> (I think we do...)

I agree with Geir on RIE should be fired only when rendering the reference.
In fact that is how I am using RIE to detect null references being rendered
and generate errors in the output.

Ajay


>
>
> >
> >
> >> From: "Geir Magnusson Jr." <geirm@optonline.net>
> >> Reply-To: "Velocity Users List" <velocity-user@jakarta.apache.org>
> >> To: <velocity-user@jakarta.apache.org>
> >> Subject: Re: Str. lit. interpolation and ReferenceInsertionEventHandler
> >> Date: Wed, 20 Mar 2002 12:21:26 -0500
> >>
> >> On 3/20/02 12:16 PM, "Daniel Dekany" <ddekany@freemail.hu> wrote:
> >>
> >>> I use ReferenceInsertionEventHandler to automate the XML-encoding of
> >>> inserted values when they are writen to the output stream. The problem
> >> is
> >>> that I can't find out if the ReferenceInsertionEventHandler was called
> >>> beacuse of a reference insertion in a string literal interpolation (eg:
> >>> #if($foo == "xyz$bar")) or because of "final" reference insertion (eg.:
> >>> Schomoo $foo schomoo). The XML-encoding should hapen in the later case
> >> only
> >>> of course. Any ideas?
> >>>
> >>
> >> Ew.  Yes, I have an idea :)
> >>
> >> The upshot is that we don't want the ReferenceInsertionEvent fired ever for
> >> a string interp, right?
> >>
> >> --
> >> Geir Magnusson Jr.                                      geirm@optonline.net
> >> System and Software Consulting
> >> "Whoever would overthrow the liberty of a nation must begin by subduing the
> >> freeness of speech." - Benjamin Franklin
> >>
> >>
> >>
> >> --
> >> To unsubscribe, e-mail:
> >> <mailto:velocity-user-unsubscribe@jakarta.apache.org>
> >> For additional commands, e-mail:
> >> <mailto:velocity-user-help@jakarta.apache.org>
> >>
> >
> >
> >
> >
> > _________________________________________________________________
> > Join the world?s largest e-mail service with MSN Hotmail.
> > http://www.hotmail.com
> >
> >
> > --
> > To unsubscribe, e-mail:
> > <mailto:velocity-user-unsubscribe@jakarta.apache.org>
> > For additional commands, e-mail:
> > <mailto:velocity-user-help@jakarta.apache.org>
> >
>
> --
> Geir Magnusson Jr.                                     geirm@optonline.net
> System and Software Consulting
> "He who throws mud only loses ground." - Fat Albert
>
> --
> To unsubscribe, e-mail:   <mailto:velocity-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail: <mailto:velocity-user-help@jakarta.apache.org>

--
Ajay Gondhiya
DSET Corporation
(908)526-7500 ext-1306
ajay@dset.com




--
To unsubscribe, e-mail:   <mailto:velocity-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:velocity-user-help@jakarta.apache.org>


Mime
View raw message