Re: List all macros defined in an ftl
Daniel Dekany <[email protected]> Sun, 23 Aug 2015 13:50:50 +0200
| Newsgroups | gmane.comp.web.freemarker.user |
|---|---|
| Message-ID | <[email protected]> |
You could use Template.getMacros().keys() for that. Yeah, it's deprecated, but that's because of the Map values it exposes, not the keys, and because it doesn't block modifying that map... you just need the keys. And it's still there in 2.4. Sunday, August 23, 2015, 5:31:52 AM, Albert Kam wrote: > This might sound strange, but i need a mechanism to list all macro names available in an ftl file. > > I wonder whether this is possible to avoid having to list it > manually somewhere and have duplication of maintenance for the list > of macro names and the actual macros. > -- Thanks, Daniel Dekany ------------------------------------------------------------------------------