Re: Supporting JSTL functions as well in FreemarkerServlet?

Daniel Dekany <[email protected]> Sun, 10 Aug 2014 13:39:02 +0200
Newsgroups gmane.comp.web.freemarker.devel
Message-ID <[email protected]>
Note that the up-to-date FreeMarker source code is on GitHub
(https://github.com/freemarker/freemarker), and you should develop
against the "2.3-gae" branch there (note the "gae" in the name). You
may also find that working with Git pull requests is easier than with
traditional diffs.

I will send the CLA shortly.

-- 
Thanks,
 Daniel Dekany


Saturday, August 9, 2014, 5:36:48 PM, Woonsan Ko wrote:

> Hi Daniel,
>
> Thank you very much for your quick response!
>
> I've just checked again what JSP 2.1 Specification says in section
> JSP.2.10. It says "functions are mapped to public static methods in Java
> classes. In JSP, the map is specified in the TLD.", "the specified
> method must be a public static method in the specified class, and must
> be specified using a fully-qualified return type followed by the method
> name, followed by the fully-qualified argument types in parenthesis,
> separated by commas", and "the resulting value is the value returned by
> the method evaluation, or null if the Java method is declared to return
> void." [1]
>
> So, yes, they are just static methods and there's no other additional
> requirements.
>
> Also, thanks for the tips on where to look for contribution. I'll  try
> to create a patch keeping BC. I'll create a ticket and attach my patch
> later in https://sourceforge.net/p/freemarker/bugs/ for reviews.
>
> Kind regards,
>
> Woonsan
>
> [1] https://jcp.org/aboutJava/communityprocess/final/jsr245/
>
> On 8/9/14 9:21 AM, Daniel Dekany wrote:
>> Hi,
>> 
>> Are JSTL functions always just plain static methods, or do some of
>> them have some additional requirements? Because if they are just
>> static methods, then FreeMarker could certainly easily support them.
>> It should be implemented inside freemarker.ext.jsp. Contributions that
>> keep backward compatibility are highly welcome (will need to sign a
>> typical Contributor License Agreement)!
>> 
>
>


------------------------------------------------------------------------------