Unit 'fpTemplate' Package
[Overview][Constants][Types][Classes][Variables][Index] [#fcl]

Reference for unit 'fpTemplate'

Simple template parsing mechanism.

uses

  System,

  sysutils,

  Classes;

Overview

fpTemplate implements a class TTemplateParser which can replace variables in a template text. The template variables are enclosed in delimiters. When a variable is encountered, it can be replaced by a string value. An event is called to get the value for a template variable. It does not contain loops or conditionals, but parametrized templates are possible.

The unit also contains TFPCustomTemplate and its descendant TFPTemplate. Which is a basic implementation that uses the template parser to substitute variables in a text.


Documentation generated on: Dec 15 2025