org.apache.tapestry.parse
Interface ITemplateParser

All Known Implementing Classes:
TemplateParser

public interface ITemplateParser

Service interface for the tapestry.TemplateParser service. Note that this requires a threaded service model.

Note: had to use the 'I' prefix, so that TemplateParser could keep its name. Otherwise, it makes Spindle support really, really ugly.

Since:
4.0
Author:
Howard Lewis Ship

Method Summary
 TemplateToken[] parse(char[] templateData, ITemplateParserDelegate delegate, org.apache.hivemind.Resource resourceLocation)
          Parses the template data into an array of TemplateTokens.
 

Method Detail

parse

TemplateToken[] parse(char[] templateData,
                      ITemplateParserDelegate delegate,
                      org.apache.hivemind.Resource resourceLocation)
                      throws TemplateParseException
Parses the template data into an array of TemplateTokens.

The parser is decidedly not threadsafe, so care should be taken that only a single thread accesses it.

Parameters:
templateData - the HTML template to parse. Some tokens will hold a reference to this array.
delegate - object that "knows" about defined components
resourceLocation - a description of where the template originated from, used with error messages.
Throws:
TemplateParseException


Copyright © 2006-2008 Apache Software Foundation. All Rights Reserved.