XSite has internally two phases. In the first phase it will extract the content of provided HTML files into XSite's model of the site, in the last phase it will provide this content to be used in a template engine for new pages. The default page extractor implementation is based on SiteMesh, the default implementation for the template engine uses FreeMarker. Other implementations for both functionalities are possible (and configurable), but XSite does currently not deliver another one.
The template engine gets as input parameter a mandatory skin file and an instance of the current Page. The page and its elements are exposed in the template engine's context, so that they are available in the template: