Ticket #231 (closed defect: fixed)
expand the list of default template functions
| Reported by: | karel | Owned by: | jgou |
|---|---|---|---|
| Priority: | minor | Milestone: | 0.4 |
| Component: | modules/kauri-template | Version: | trunk |
| Keywords: | Cc: |
Description
While most of these can be achieved in other ways (certainly if you take groovy into account), it's not always trivial:
math:floor(n). use case: ${math:floor(5/2)} --> 2 (Currently, ${(5/2).intValue()} as a good alternative)
math:ceil(n)
math:random()
math:abs()
math:pow(a,b)
math:tan(n)
math:log(n)
math:log(n,base)
etc.
txt:indexOf(a,b) (not very useful, ${a.indexOf(b)} is quite intuitive)
Change History
Note: See
TracTickets for help on using
tickets.
I suggest adding all java.lang.Math functions.