Mercurial > hg > tema
changeset 17:5ebf123f3486
Documentation update and code cleanup.
author | Mikhail Kryshen <mikhail@kryshen.net> |
---|---|
date | Tue, 24 Mar 2009 19:36:09 +0300 |
parents | 5a38106d7a21 |
children | d53cd4995bd4 |
files | doc/manual/manual.tema src/kryshen/tema/FunctionDataParser.java |
diffstat | 2 files changed, 27 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/doc/manual/manual.tema Tue Mar 24 18:58:28 2009 +0300 +++ b/doc/manual/manual.tema Tue Mar 24 19:36:09 2009 +0300 @@ -107,7 +107,26 @@ output <%:name%> %> -[%!\ TODO: next_arg, data, has_more_data %]\\ +<%function:next_arg + description <%:\\ + Works in context of <%code:define%> function. + Parses the next argument from the calling function input.%> + output <%:next argument text%> +%> + +<%function:data + description <%:\\ + Works in context of <%code:define%> function. + Outputs remaining text passed to the calling function.%> + output <%:next argument text%> +%> + +<%function:has_more_data + description <%:\\ + Works in context of <%code:define%> function. Returns non-zero value if + the calling function has more input data available. + %> +%> <%function:export arguments <%:definition name%> @@ -192,7 +211,13 @@ <%function:while input_data <%:code%> - description <%:Repeatedly outputs it's evaluated data while it has non-zero value.%> + description <%:Repeatedly outputs it's evaluated data while parses with non-zero value.%> +%> + +<%function:if + arguments <%:condition%> + input_data <%:text%> + description <%:Outputs the input text if the condition parses with non-zero value.%> %> [%!\ TODO: all functions defined in Control.java %]\\
--- a/src/kryshen/tema/FunctionDataParser.java Tue Mar 24 18:58:28 2009 +0300 +++ b/src/kryshen/tema/FunctionDataParser.java Tue Mar 24 19:36:09 2009 +0300 @@ -26,8 +26,6 @@ import java.io.Writer; import java.util.ArrayList; import java.util.List; -import static kryshen.tema.TemplateParser.Result; -import static kryshen.tema.TemplateParser.DataFormat; import kryshen.tema.TemplateParser.DataFormat; import static kryshen.tema.TemplateParser.Terminator; import kryshen.tema.io.CopyWriter;