| |
|
| freemarker.template.TransformControl
TransformControl | public interface TransformControl (Code) | | An interface that can be implemented by writers returned from
TemplateTransformModel.getWriter(java.io.Writerjava.util.Map) . The
methods on this
interfaces are callbacks that will be called by the template engine and that
give the writer a chance to better control the evaluation of the transform
body. The writer can instruct the engine to skip or to repeat body
evaluation, and gets notified about exceptions that are thrown during the
body evaluation.
author: Attila Szegedi version: $Id: TransformControl.java,v 1.11 2005/06/16 18:13:58 ddekany Exp $ |
END_EVALUATION | final public static int END_EVALUATION(Code) | | Constant returned from
TransformControl.afterBody() that tells the
template engine to end the transform and close the writer.
|
REPEAT_EVALUATION | final public static int REPEAT_EVALUATION(Code) | | Constant returned from
TransformControl.afterBody() that tells the
template engine to repeat transform body evaluation and feed
it again to the transform.
|
SKIP_BODY | final public static int SKIP_BODY(Code) | | Constant returned from
TransformControl.onStart() that tells the
template engine to skip evaluation of the body.
|
afterBody | public int afterBody() throws TemplateModelException, IOException(Code) | | Called after the body has been evaluated.
- END_EVALUATION if the transformation should be ended.
- REPEAT_EVALUATION to have the engine re-evaluate the transform body and feed it again to the writer.
|
onStart | public int onStart() throws TemplateModelException, IOException(Code) | | Called before the body is evaluated for the first time.
- SKIP_BODY if the transform wants to ignore the body. In thiscase, only java.io.Writer.close is called next and processing ends.
- EVALUATE_BODY to normally evaluate the body of the transformand feed it to the writer
|
|
|
|