0
Download Sempare Template Engine for Delphi v1.7.3 Retail (Generate Email, HTML, Source Code, XML, and Configuration)

Download Sempare Template Engine for Delphi v1.7.3 Retail (Generate Email, HTML, Source Code, XML, and Configuration)

Version: 1.7.3
Product Release Date: November 17, 2023
Download Sempare Template Engine For Delphi V1.7.3 Retail (Generate Email, Html, Source Code, Xml, And Configuration)
Sempare Template Engine offers a rich development experience, exemplified by its comprehensive set of 180+ unit tests and the Sempare Template Playground demo. This demo provides a practical environment for testing various template language features and exploring the engine's capabilities.
Add to your wishlist or like it:
0

The Sempare Template Engine for Delphi is a powerful and flexible tool designed to facilitate dynamic content generation in various scenarios. Leveraging Run-time Type Information (RTTI) enables the substitution of variables with values from a data source within template scripts. The engine is handy for server-side scripting in web development, code generation, mail merge, and creating notification messages.

Sempare Template Engine

Using a straightforward syntax, the engine allows developers to define scripting statements within templates using markers like ‘<%’ to start and ‘%>’ to end each statement. These scripting statements can involve referencing variables, assigning values, employing conditions, loops (for and while loops), and even including other templates. The use of RTTI allows for the dereferencing of almost any type within the template script.

The primary objective of the Sempare Template Engine is to streamline working with the ‘view’ aspects of templates. While not aiming to be a fully featured general-purpose programming language like PHP, it does encompass essential features. Developers can extend functionality by implementing custom functions in Object Pascal.

Compatibility is a key focus, with Sempare Template Engine supporting modern versions of Delphi, including testing with Delphi XE 4 to Delphi 11.3 Alexandria. Backward compatibility is maintained, and platform-specific restrictions are minimal.

Installation is easy through the Embarcadero GetIt manager, Boss package manager, or Delphinus package manager. The engine’s features include support for statements (if, elif, else), loops, include statements, function/method calls, expressions, variable definitions, and dereferencing of various data structures, including records, classes, arrays, JSON objects, TDataSet descendants, and dynamic arrays.

Safety features include max run-time protection, custom script token replacement, custom functions addition, and the ability to strip recurring spaces and new lines. The engine also allows lazy template resolution, parse-time evaluation of expressions/statements, and custom encodings.

One notable feature in Sempare Template Engine is the extensible RTTI interface, which provides an easy way to dereference classes and interfaces. The engine comes with built-in customizations for ITemplateVariables, TDictionary, and TJsonObject, ensuring a versatile and adaptable solution for diverse template-related tasks.

The Sempare Template Engine offers a rich development experience, exemplified by its comprehensive set of 180+ unit tests and the Sempare Template Playground demo. This demo provides a practical environment for testing various template language features and exploring the engine’s capabilities. With its emphasis on simplicity, flexibility, and compatibility, the Sempare Template Engine is a valuable asset for Delphi developers working on projects involving dynamic content generation and template-based rendering.

Sempare Template Engine for Delphi Features:

  • Scripting Statements:
    • Intuitive syntax using markers like ‘<%’ to start and ‘%>’ to end scripting statements.
    • Supports a variety of statements, including conditions (if, elif, else), loops (for and while), include statements, and more.
  • Variable Handling:
    • Efficient substitution of variables with values from a data source.
    • Variable definition within scripting statements.
  • Expressions:
    • Evaluation of simple expressions, including logical, numerical, and string operations.
  • RTTI Integration:
    • Utilizes Run-time Type Information (RTTI) for dynamic dereferencing of almost any type within the template script.
    • Extensible RTTI interface for easy dereferencing of classes and interfaces.
  • Data Structure Dereferencing:
    • Dereferencing of various data structures, including records, classes, arrays, JSON objects, TDataSet descendants, and dynamic arrays.
  • Control Flow:
    • Conditional statements (if, elif, else) for creating dynamic content based on logical conditions.
    • Looping statements (for and while) for iterative processing.
  • Function and Method Calls:
    • Support for calling functions and methods within the template script.
  • Safety Features:
    • Max run-time protection to ensure safe execution.
    • Custom script token replacement for enhanced customization.
    • Ability to strip recurring spaces and new lines.
  • Customization:
    • Addition of custom functions in Object Pascal to extend functionality.
    • Support for custom encoding, allowing UTF-8 with or without BOM, ASCII, etc.
  • Lazy Template Resolution:
    • Deferred resolution of templates for improved efficiency.
  • Parse-Time Evaluation:
    • Evaluation of expressions and statements during parse time.
  • Compatibility:
    • Supports modern versions of Delphi, including Delphi XE 4 to Delphi 11.3 Alexandria.
    • Backward compatibility focuses on ensuring seamless integration with existing projects.
  • Installation Options:
    • Convenient installation via Embarcadero GetIt manager, Boss package manager, or Delphinus package manager.
  • Extensive Testing:
    • A comprehensive set of 180+ unit tests for ensuring reliability and functionality.
    • Sempare Template Playground demo for practical testing and exploration of template language features.