RE: [FreeMarker-user] FW: crud screens and null.
Generates text that depends on changing data (like dynamic HTML).
Brought to you by:
revusky
|
From: Joe H. <jh...@my...> - 2006-05-09 14:11:50
|
> -----Original Message-----
> From: fre...@li... =
[mailto:freemarker-user-
> ad...@li...] On Behalf Of Daniel Dekany
> Sent: Tuesday, May 09, 2006 9:58 AM
> To: Payne, Matthew
> Cc: fre...@li...
> Subject: Re: [FreeMarker-user] FW: crud screens and null.
>=20
> Tuesday, May 9, 2006, 3:16:12 PM, Payne, Matthew wrote:
>=20
> > +1
> >
> > Support the !.
>=20
> I disagree. The ! of Velocity doesn't let you specify the default
> value, so what should the template language do with the "suppressed"
> null then?
I disagre. I think that if you evaluated all the FreeMarker templates =
out
there you would see a lot of ${something?if_exists} or
${something?default("")}. The easy syntax isn't meant to address
${something?default("something else")}.
I like Daniel's idea of shorter syntax for =
${something?default("something
else")} but I certainly think that it doesn't mean that $!{something} =
isn't
useful.
Joe
>=20
> But, I agree that ?default(exp) needs a shorter form. Say, let it be:
> exp!theDefaultExp and (exp)!theDefaultExp. With examples:
>=20
> ${maidenName!'N/A'}
>=20
> ${(user.name)!'anonymous'}
>=20
> Also ?string needs a shorter form, like ${x~#.000}.
>=20
> --
> Best regards,
> Daniel Dekany
>=20
>=20
>=20
> -------------------------------------------------------
> Using Tomcat but need to do more? Need to support web services, =
security?
> Get stuff done quickly with pre-integrated technology to make your job
> easier
> Download IBM WebSphere Application Server v.1.0.1 based on Apache =
Geronimo
> http://sel.as-us.falkag.net/sel?cmd=3Dk&kid=120709&bid&3057&dat=121642
> _______________________________________________
> FreeMarker-user mailing list
> Fre...@li...
> https://lists.sourceforge.net/lists/listinfo/freemarker-user
|