From b28851a117de5a4a92a5c50b1f9738a6b6181d8d Mon Sep 17 00:00:00 2001 From: Kevin Chabowski Date: Tue, 27 Sep 2011 14:15:37 +0200 Subject: Fixed documentation and excluded NaturalDocs' project data. --- docu/nd/Data/ClassHierarchy.nd | Bin 385 -> 0 bytes docu/nd/Data/ConfigFileInfo.nd | Bin 26 -> 0 bytes docu/nd/Data/FileInfo.nd | 7 -- docu/nd/Data/ImageFileInfo.nd | Bin 8 -> 0 bytes docu/nd/Data/ImageReferenceTable.nd | Bin 165 -> 0 bytes docu/nd/Data/IndexInfo.nd | Bin 226 -> 0 bytes docu/nd/Data/PreviousMenuState.nd | Bin 239 -> 0 bytes docu/nd/Data/PreviousSettings.nd | Bin 127 -> 0 bytes docu/nd/Data/SymbolTable.nd | Bin 6606 -> 0 bytes docu/nd/Languages.txt | 113 -------------------------- docu/nd/Menu.txt | 60 -------------- docu/nd/Topics.txt | 81 ------------------ docu/nd/files/stupid_template_engine-php.html | 32 ++++---- docu/nd/index/Functions.html | 10 +-- docu/nd/index/General.html | 12 +-- docu/nd/javascript/searchdata.js | 20 ++--- docu/nd/search/FunctionsP.html | 2 +- docu/nd/search/FunctionsS.html | 2 +- docu/nd/search/GeneralP.html | 2 +- docu/nd/search/GeneralS.html | 2 +- 20 files changed, 43 insertions(+), 300 deletions(-) delete mode 100644 docu/nd/Data/ClassHierarchy.nd delete mode 100644 docu/nd/Data/ConfigFileInfo.nd delete mode 100644 docu/nd/Data/FileInfo.nd delete mode 100644 docu/nd/Data/ImageFileInfo.nd delete mode 100644 docu/nd/Data/ImageReferenceTable.nd delete mode 100644 docu/nd/Data/IndexInfo.nd delete mode 100644 docu/nd/Data/PreviousMenuState.nd delete mode 100644 docu/nd/Data/PreviousSettings.nd delete mode 100644 docu/nd/Data/SymbolTable.nd delete mode 100644 docu/nd/Languages.txt delete mode 100644 docu/nd/Menu.txt delete mode 100644 docu/nd/Topics.txt (limited to 'docu/nd') diff --git a/docu/nd/Data/ClassHierarchy.nd b/docu/nd/Data/ClassHierarchy.nd deleted file mode 100644 index e4063da..0000000 Binary files a/docu/nd/Data/ClassHierarchy.nd and /dev/null differ diff --git a/docu/nd/Data/ConfigFileInfo.nd b/docu/nd/Data/ConfigFileInfo.nd deleted file mode 100644 index 36e0d8c..0000000 Binary files a/docu/nd/Data/ConfigFileInfo.nd and /dev/null differ diff --git a/docu/nd/Data/FileInfo.nd b/docu/nd/Data/FileInfo.nd deleted file mode 100644 index 696bf2b..0000000 --- a/docu/nd/Data/FileInfo.nd +++ /dev/null @@ -1,7 +0,0 @@ -1.4 -PHP -/home/skadu/public_html/stupid_template_engine/stupid_template_engine.php 1316557025 1 stupid_template_engine.php -/home/skadu/public_html/stupid_template_engine/example/templates/transc/master.html.php 1316556841 0 /home/skadu/public_html/stupid_template_engine/example/templates/transc/master.html.php -/home/skadu/public_html/stupid_template_engine/example/templates/transc/articles.html.php 1316556695 0 /home/skadu/public_html/stupid_template_engine/example/templates/transc/articles.html.php -/home/skadu/public_html/stupid_template_engine/example/index.php 1316556488 0 /home/skadu/public_html/stupid_template_engine/example/index.php -/home/skadu/public_html/stupid_template_engine/example/templates/transc/custom_tags.tpl.php 1316556629 0 /home/skadu/public_html/stupid_template_engine/example/templates/transc/custom_tags.tpl.php diff --git a/docu/nd/Data/ImageFileInfo.nd b/docu/nd/Data/ImageFileInfo.nd deleted file mode 100644 index e6ccf0d..0000000 Binary files a/docu/nd/Data/ImageFileInfo.nd and /dev/null differ diff --git a/docu/nd/Data/ImageReferenceTable.nd b/docu/nd/Data/ImageReferenceTable.nd deleted file mode 100644 index ad9b847..0000000 Binary files a/docu/nd/Data/ImageReferenceTable.nd and /dev/null differ diff --git a/docu/nd/Data/IndexInfo.nd b/docu/nd/Data/IndexInfo.nd deleted file mode 100644 index 79e6270..0000000 Binary files a/docu/nd/Data/IndexInfo.nd and /dev/null differ diff --git a/docu/nd/Data/PreviousMenuState.nd b/docu/nd/Data/PreviousMenuState.nd deleted file mode 100644 index 7c0aeba..0000000 Binary files a/docu/nd/Data/PreviousMenuState.nd and /dev/null differ diff --git a/docu/nd/Data/PreviousSettings.nd b/docu/nd/Data/PreviousSettings.nd deleted file mode 100644 index d319ede..0000000 Binary files a/docu/nd/Data/PreviousSettings.nd and /dev/null differ diff --git a/docu/nd/Data/SymbolTable.nd b/docu/nd/Data/SymbolTable.nd deleted file mode 100644 index 34da931..0000000 Binary files a/docu/nd/Data/SymbolTable.nd and /dev/null differ diff --git a/docu/nd/Languages.txt b/docu/nd/Languages.txt deleted file mode 100644 index be96913..0000000 --- a/docu/nd/Languages.txt +++ /dev/null @@ -1,113 +0,0 @@ -Format: 1.4 - -# This is the Natural Docs languages file for this project. If you change -# anything here, it will apply to THIS PROJECT ONLY. If you'd like to change -# something for all your projects, edit the Languages.txt in Natural Docs' -# Config directory instead. - - -# You can prevent certain file extensions from being scanned like this: -# Ignore Extensions: [extension] [extension] ... - - -#------------------------------------------------------------------------------- -# SYNTAX: -# -# Unlike other Natural Docs configuration files, in this file all comments -# MUST be alone on a line. Some languages deal with the # character, so you -# cannot put comments on the same line as content. -# -# Also, all lists are separated with spaces, not commas, again because some -# languages may need to use them. -# -# Language: [name] -# Alter Language: [name] -# Defines a new language or alters an existing one. Its name can use any -# characters. If any of the properties below have an add/replace form, you -# must use that when using Alter Language. -# -# The language Shebang Script is special. It's entry is only used for -# extensions, and files with those extensions have their shebang (#!) lines -# read to determine the real language of the file. Extensionless files are -# always treated this way. -# -# The language Text File is also special. It's treated as one big comment -# so you can put Natural Docs content in them without special symbols. Also, -# if you don't specify a package separator, ignored prefixes, or enum value -# behavior, it will copy those settings from the language that is used most -# in the source tree. -# -# Extensions: [extension] [extension] ... -# [Add/Replace] Extensions: [extension] [extension] ... -# Defines the file extensions of the language's source files. You can -# redefine extensions found in the main languages file. You can use * to -# mean any undefined extension. -# -# Shebang Strings: [string] [string] ... -# [Add/Replace] Shebang Strings: [string] [string] ... -# Defines a list of strings that can appear in the shebang (#!) line to -# designate that it's part of the language. You can redefine strings found -# in the main languages file. -# -# Ignore Prefixes in Index: [prefix] [prefix] ... -# [Add/Replace] Ignored Prefixes in Index: [prefix] [prefix] ... -# -# Ignore [Topic Type] Prefixes in Index: [prefix] [prefix] ... -# [Add/Replace] Ignored [Topic Type] Prefixes in Index: [prefix] [prefix] ... -# Specifies prefixes that should be ignored when sorting symbols in an -# index. Can be specified in general or for a specific topic type. -# -#------------------------------------------------------------------------------ -# For basic language support only: -# -# Line Comments: [symbol] [symbol] ... -# Defines a space-separated list of symbols that are used for line comments, -# if any. -# -# Block Comments: [opening sym] [closing sym] [opening sym] [closing sym] ... -# Defines a space-separated list of symbol pairs that are used for block -# comments, if any. -# -# Package Separator: [symbol] -# Defines the default package separator symbol. The default is a dot. -# -# [Topic Type] Prototype Enders: [symbol] [symbol] ... -# When defined, Natural Docs will attempt to get a prototype from the code -# immediately following the topic type. It stops when it reaches one of -# these symbols. Use \n for line breaks. -# -# Line Extender: [symbol] -# Defines the symbol that allows a prototype to span multiple lines if -# normally a line break would end it. -# -# Enum Values: [global|under type|under parent] -# Defines how enum values are referenced. The default is global. -# global - Values are always global, referenced as 'value'. -# under type - Values are under the enum type, referenced as -# 'package.enum.value'. -# under parent - Values are under the enum's parent, referenced as -# 'package.value'. -# -# Perl Package: [perl package] -# Specifies the Perl package used to fine-tune the language behavior in ways -# too complex to do in this file. -# -#------------------------------------------------------------------------------ -# For full language support only: -# -# Full Language Support: [perl package] -# Specifies the Perl package that has the parsing routines necessary for full -# language support. -# -#------------------------------------------------------------------------------- - -# The following languages are defined in the main file, if you'd like to alter -# them: -# -# Text File, Shebang Script, C/C++, C#, Java, JavaScript, Perl, Python, -# PHP, SQL, Visual Basic, Pascal, Assembly, Ada, Tcl, Ruby, Makefile, -# ActionScript, ColdFusion, R, Fortran - -# If you add a language that you think would be useful to other developers -# and should be included in Natural Docs by default, please e-mail it to -# languages [at] naturaldocs [dot] org. diff --git a/docu/nd/Menu.txt b/docu/nd/Menu.txt deleted file mode 100644 index 85c51af..0000000 --- a/docu/nd/Menu.txt +++ /dev/null @@ -1,60 +0,0 @@ -Format: 1.4 - - -# You can add a title and sub-title to your menu like this: -# Title: [project name] -# SubTitle: [subtitle] - -# You can add a footer to your documentation like this: -# Footer: [text] -# If you want to add a copyright notice, this would be the place to do it. - -# You can add a timestamp to your documentation like one of these: -# Timestamp: Generated on month day, year -# Timestamp: Updated mm/dd/yyyy -# Timestamp: Last updated mon day -# -# m - One or two digit month. January is "1" -# mm - Always two digit month. January is "01" -# mon - Short month word. January is "Jan" -# month - Long month word. January is "January" -# d - One or two digit day. 1 is "1" -# dd - Always two digit day. 1 is "01" -# day - Day with letter extension. 1 is "1st" -# yy - Two digit year. 2006 is "06" -# yyyy - Four digit year. 2006 is "2006" -# year - Four digit year. 2006 is "2006" - - -# -------------------------------------------------------------------------- -# -# Cut and paste the lines below to change the order in which your files -# appear on the menu. Don't worry about adding or removing files, Natural -# Docs will take care of that. -# -# You can further organize the menu by grouping the entries. Add a -# "Group: [name] {" line to start a group, and add a "}" to end it. -# -# You can add text and web links to the menu by adding "Text: [text]" and -# "Link: [name] ([URL])" lines, respectively. -# -# The formatting and comments are auto-generated, so don't worry about -# neatness when editing the file. Natural Docs will clean it up the next -# time it is run. When working with groups, just deal with the braces and -# forget about the indentation and comments. -# -# -------------------------------------------------------------------------- - - -File: stupid_template_engine.php (stupid_template_engine.php) - -Group: Index { - - Index: Everything - Class Index: Classes - Constant Index: Constants - File Index: Files - Function Index: Functions - Variable Index: Variables - } # Group: Index - diff --git a/docu/nd/Topics.txt b/docu/nd/Topics.txt deleted file mode 100644 index b1a9b93..0000000 --- a/docu/nd/Topics.txt +++ /dev/null @@ -1,81 +0,0 @@ -Format: 1.4 - -# This is the Natural Docs topics file for this project. If you change anything -# here, it will apply to THIS PROJECT ONLY. If you'd like to change something -# for all your projects, edit the Topics.txt in Natural Docs' Config directory -# instead. - - -# If you'd like to prevent keywords from being recognized by Natural Docs, you -# can do it like this: -# Ignore Keywords: [keyword], [keyword], ... -# -# Or you can use the list syntax like how they are defined: -# Ignore Keywords: -# [keyword] -# [keyword], [plural keyword] -# ... - - -#------------------------------------------------------------------------------- -# SYNTAX: -# -# Topic Type: [name] -# Alter Topic Type: [name] -# Creates a new topic type or alters one from the main file. Each type gets -# its own index and behavior settings. Its name can have letters, numbers, -# spaces, and these charaters: - / . ' -# -# Plural: [name] -# Sets the plural name of the topic type, if different. -# -# Keywords: -# [keyword] -# [keyword], [plural keyword] -# ... -# Defines or adds to the list of keywords for the topic type. They may only -# contain letters, numbers, and spaces and are not case sensitive. Plural -# keywords are used for list topics. You can redefine keywords found in the -# main topics file. -# -# Index: [yes|no] -# Whether the topics get their own index. Defaults to yes. Everything is -# included in the general index regardless of this setting. -# -# Scope: [normal|start|end|always global] -# How the topics affects scope. Defaults to normal. -# normal - Topics stay within the current scope. -# start - Topics start a new scope for all the topics beneath it, -# like class topics. -# end - Topics reset the scope back to global for all the topics -# beneath it. -# always global - Topics are defined as global, but do not change the scope -# for any other topics. -# -# Class Hierarchy: [yes|no] -# Whether the topics are part of the class hierarchy. Defaults to no. -# -# Page Title If First: [yes|no] -# Whether the topic's title becomes the page title if it's the first one in -# a file. Defaults to no. -# -# Break Lists: [yes|no] -# Whether list topics should be broken into individual topics in the output. -# Defaults to no. -# -# Can Group With: [type], [type], ... -# Defines a list of topic types that this one can possibly be grouped with. -# Defaults to none. -#------------------------------------------------------------------------------- - -# The following topics are defined in the main file, if you'd like to alter -# their behavior or add keywords: -# -# Generic, Class, Interface, Section, File, Group, Function, Variable, -# Property, Type, Constant, Enumeration, Event, Delegate, Macro, -# Database, Database Table, Database View, Database Index, Database -# Cursor, Database Trigger, Cookie, Build Target - -# If you add something that you think would be useful to other developers -# and should be included in Natural Docs by default, please e-mail it to -# topics [at] naturaldocs [dot] org. diff --git a/docu/nd/files/stupid_template_engine-php.html b/docu/nd/files/stupid_template_engine-php.html index efbb4b8..b7b8ea3 100644 --- a/docu/nd/files/stupid_template_engine-php.html +++ b/docu/nd/files/stupid_template_engine-php.html @@ -11,37 +11,39 @@ if (browserType) {document.write("
");if (browserV -

stupid_template_engine.php

The implementation of the Stupid Template Engine.

Summary
stupid_template_engine.phpThe implementation of the Stupid Template Engine.
LicenseThis file is licensed under the MIT/X11 License.
steEverything in this file is in this namespace.
Functions
parseParsing a STE T/PL template.
transcompileTranscompiles an abstract syntax tree to PHP.
Constants
Template modes
StorageAccessAn interface.
Functions
loadLoading a template.
saveSaves a template.
FilesystemStorageAccessThe default StorageAccess implementation for loading / saving templates into a directory structure.
Functions
__construct
STECoreThe Core of STE
Variables
Public variables
Functions
__construct
register_tagRegister a custom tag.
call_tagCalling a custom tag (builtin ones can not be called)
exectemplateExecutes a template and returns the result.
get_var_referenceGet a reference to a template variable using a variable name.
get_var_by_nameGet a template variable by its name.
loadLoad a template and return its result (blocks not included, use exectemplate for this).
evalboolTest, if a text represents false (an empty / only whitespace text) or true (everything else).
+

stupid_template_engine.php

The implementation of the Stupid Template Engine.

Summary
stupid_template_engine.phpThe implementation of the Stupid Template Engine.
LicenseThis file is licensed under the MIT/X11 License.
steEverything in this file is in this namespace.
Functions
precompilePrecompiling STE T/PL templates.
parseParsing a STE T/PL template.
transcompileTranscompiles an abstract syntax tree to PHP.
Constants
Template modes
StorageAccessAn interface.
Functions
loadLoading a template.
saveSaves a template.
FilesystemStorageAccessThe default StorageAccess implementation for loading / saving templates into a directory structure.
Functions
__construct
STECoreThe Core of STE
Variables
Public variables
Functions
__construct
register_tagRegister a custom tag.
call_tagCalling a custom tag (builtin ones can not be called)
exectemplateExecutes a template and returns the result.
get_var_referenceGet a reference to a template variable using a variable name.
set_var_by_nameSet a template variable by its name.
get_var_by_nameGet a template variable by its name.
loadLoad a template and return its result (blocks not included, use exectemplate for this).
evalboolTest, if a text represents false (an empty / only whitespace text) or true (everything else).

License

This file is licensed under the MIT/X11 License.  See COPYING for more details.

-

ste

Everything in this file is in this namespace.

Summary
Functions
parseParsing a STE T/PL template.
transcompileTranscompiles an abstract syntax tree to PHP.
Constants
Template modes
+

ste

Everything in this file is in this namespace.

Summary
Functions
precompilePrecompiling STE T/PL templates.
parseParsing a STE T/PL template.
transcompileTranscompiles an abstract syntax tree to PHP.
Constants
Template modes

Functions

-

parse

function parse($code)

Parsing a STE T/PL template.  You only need this function, if you want to manually transcompile a template.

Parameters

$codeThe STE T/PL code.

Returns

An abstract syntax tree, whic can be used with transcompile.

+

precompile

function precompile($code)

Precompiling STE T/PL templates.  You only need this function, if you want to manually transcompile a template.

Parameters

$codeThe input code

Returns

The precompiled code.

-

transcompile

function transcompile($ast) /* Transcompile and add some boilerplate code. */

Transcompiles an abstract syntax tree to PHP.

Parameters

$astThe abstract syntax tree to transcompile.

Returns

PHP code.  The PHP code is an anonymous function expecting a STECore instance as its parameter and returns a string (everything that was not pached into a section).

+

parse

function parse($code,
$tpl)

Parsing a STE T/PL template.  You only need this function, if you want to manually transcompile a template.

Parameters

$codeThe STE T/PL code.
$tplThe name of the template.

Returns

An abstract syntax tree, which can be used with transcompile.

+ +

transcompile

function transcompile($ast) /* Transcompile and add some boilerplate code. */

Transcompiles an abstract syntax tree to PHP.  You only need this function, if you want to manually transcompile a template.

Parameters

$astThe abstract syntax tree to transcompile.

Returns

PHP code.  The PHP code is an anonymous function expecting a STECore instance as its parameter and returns a string (everything that was not pached into a section).

Constants

Template modes

MODE_SOURCEThe Templates source
MODE_TRANSCOMPILEDThe transcompiled template
-

StorageAccess

An interface.  A StorageAccess implementation is used to access the templates from any storage.  This means, that you are not limited to store the Templates inside directories, you can also use a database or something else.

Summary
Functions
loadLoading a template.
saveSaves a template.
+

StorageAccess

An interface.  A StorageAccess implementation is used to access the templates from any storage.  This means, that you are not limited to store the Templates inside directories, you can also use a database or something else.

Summary
Functions
loadLoading a template.
saveSaves a template.

Functions

-

load

public function load($tpl,
&$mode)

Loading a template.

Parameters

$tplThe name of the template.
&$modeWhich mode is preferred?  One of the <Template modes>.  If <MODE_SOURCE>, the raw sourcecode is expected, if <MODE_TRANSCOMPILED> the transcompiled template as a callable function (expecting an STECore instance as first parameter) is expected.  If the transcompiled version is not available or older than the source, you can set this parameter to <MODE_SOURCE> and return the source.

Returns

Either the sourcecode or a callable function (first, and only parameter: an STECore instance).

+

load

public function load($tpl,
&$mode)

Loading a template.

Parameters

$tplThe name of the template.
&$modeWhich mode is preferred?  One of the <Template modes>.  If <MODE_SOURCE>, the raw sourcecode is expected, if <MODE_TRANSCOMPILED> the transcompiled template as a callable function (expecting an STECore instance as first parameter) is expected.  If the transcompiled version is not available or older than the source, you can set this parameter to <MODE_SOURCE> and return the source.

Returns

Either the sourcecode or a callable function (first, and only parameter: an STECore instance).

save

public function save($tpl,
$data,
$mode)

Saves a template.

Parameters

$tpl -The name of the template.  $data - The data to be saved.  $mode - A <Template mode> constant.

-

FilesystemStorageAccess

The default StorageAccess implementation for loading / saving templates into a directory structure.

+

FilesystemStorageAccess

The default StorageAccess implementation for loading / saving templates into a directory structure.

Functions

__construct

public function __construct($src,
$transc)

Parameters

$srcThe directory with the sources (Writing permissions are not mandatory, because STE does not save template sources).
$transcThe directory with the transcompiled templates (the PHP instance / the HTTP Server needs writing permissions to this directory).
-

STECore

The Core of STE

Summary
Variables
Public variables
Functions
__construct
register_tagRegister a custom tag.
call_tagCalling a custom tag (builtin ones can not be called)
exectemplateExecutes a template and returns the result.
get_var_referenceGet a reference to a template variable using a variable name.
get_var_by_nameGet a template variable by its name.
loadLoad a template and return its result (blocks not included, use exectemplate for this).
evalboolTest, if a text represents false (an empty / only whitespace text) or true (everything else).
+

STECore

The Core of STE

Summary
Variables
Public variables
Functions
__construct
register_tagRegister a custom tag.
call_tagCalling a custom tag (builtin ones can not be called)
exectemplateExecutes a template and returns the result.
get_var_referenceGet a reference to a template variable using a variable name.
set_var_by_nameSet a template variable by its name.
get_var_by_nameGet a template variable by its name.
loadLoad a template and return its result (blocks not included, use exectemplate for this).
evalboolTest, if a text represents false (an empty / only whitespace text) or true (everything else).

Variables

@@ -49,19 +51,21 @@ if (browserType) {document.write("
");if (browserV

Functions

-

__construct

public function __construct($storage_access)

Parameters

$storage_accessAn Instance of a StorageAccess implementation.
+

__construct

public function __construct($storage_access)

Parameters

$storage_accessAn Instance of a StorageAccess implementation.
-

register_tag

public function register_tag($name,
$callback)

Register a custom tag.

Parameters

$nameThe name of the tag.
$callbackA callable function (This must tage three parameters: The STECore instance, an associative array of parameters, and a function representing the tags content(This expects the STECore instance as its only parameter and returns its text result, i.e to get the text, you neeed to call this function with the STECore instance as a parameter)).
+

register_tag

public function register_tag($name,
$callback)

Register a custom tag.

Parameters

$nameThe name of the tag.
$callbackA callable function (This must tage three parameters: The STECore instance, an associative array of parameters, and a function representing the tags content(This expects the STECore instance as its only parameter and returns its text result, i.e to get the text, you neeed to call this function with the STECore instance as a parameter)).
-

call_tag

public function call_tag($name,
$params,
$sub)

Calling a custom tag (builtin ones can not be called)

Parameters

$nameThe Tag’s name
$paramsAssociative array of parameters
$subA callable function (expecting an STECore instance as it’s parameter) that represents the tag’s content.

Returns

The output of the tag.

+

call_tag

public function call_tag($name,
$params,
$sub)

Calling a custom tag (builtin ones can not be called)

Parameters

$nameThe Tag’s name
$paramsAssociative array of parameters
$subA callable function (expecting an STECore instance as it’s parameter) that represents the tag’s content.

Returns

The output of the tag.

-

exectemplate

public function exectemplate($tpl)

Executes a template and returns the result.  The huge difference to load is that this function will also output all blocks.

Parameters

$tplThe name of the template to execute.

Returns

The output of the template.

+

exectemplate

public function exectemplate($tpl)

Executes a template and returns the result.  The huge difference to load is that this function will also output all blocks.

Parameters

$tplThe name of the template to execute.

Returns

The output of the template.

get_var_reference

public function &get_var_reference($name,
$create_if_not_exist)

Get a reference to a template variable using a variable name.  This can be used,if your custom tag takes a variable name as a parameter.

Parameters

$nameThe variables name.
$create_if_not_existShould the variable be created, if it does not exist?  Otherwise NULL will be returned, if the variable does not exist.

Returns

A Reference to the variable.

+

set_var_by_name

public function set_var_by_name($name,
$val)

Set a template variable by its name.  This can be used,if your custom tag takes a variable name as a parameter.

Parameters

$nameThe variables name.
$valThe new value.
+

get_var_by_name

public function get_var_by_name($name)

Get a template variable by its name.  This can be used,if your custom tag takes a variable name as a parameter.

Parameters

$nameThe variables name.

Returns

The variables value.

-

load

public function load($tpl,  
$quiet = False)

Load a template and return its result (blocks not included, use exectemplate for this).

Parameters

$tplThe name of the template to be loaded.
$quietIf true, do not output anything and do notmodify the blocks.  This can be useful to load custom tags that are programmed in STE T/PL.  Default: false.

Returns

The result of the template (if $quiet == false).

+

load

public function load($tpl,  
$quiet = False)

Load a template and return its result (blocks not included, use exectemplate for this).

Parameters

$tplThe name of the template to be loaded.
$quietIf true, do not output anything and do notmodify the blocks.  This can be useful to load custom tags that are programmed in STE T/PL.  Default: false.

Returns

The result of the template (if $quiet == false).

evalbool

public function evalbool($txt)

Test, if a text represents false (an empty / only whitespace text) or true (everything else).

Parameters

$txtThe text to test.

Returns

true/false.

@@ -78,7 +82,7 @@ var searchPanel = new SearchPanel("searchPanel", "HTML", "../search"); -
function parse($code)
Parsing a STE T/PL template.
function transcompile($ast) /* Transcompile and add some boilerplate code. */
Transcompiles an abstract syntax tree to PHP.
public function load($tpl,
&$mode)
Loading a template.
public function save($tpl,
$data,
$mode)
Saves a template.
An interface.
public function __construct($src,
$transc)
public function __construct($storage_access)
public function register_tag($name,
$callback)
Register a custom tag.
public function call_tag($name,
$params,
$sub)
Calling a custom tag (builtin ones can not be called)
public function exectemplate($tpl)
Executes a template and returns the result.
public function &get_var_reference($name,
$create_if_not_exist)
Get a reference to a template variable using a variable name.
public function get_var_by_name($name)
Get a template variable by its name.
public function load($tpl,  
$quiet = False)
Load a template and return its result (blocks not included, use exectemplate for this).
public function evalbool($txt)
Test, if a text represents false (an empty / only whitespace text) or true (everything else).
The Core of STE
+
function precompile($code)
Precompiling STE T/PL templates.
function parse($code,
$tpl)
Parsing a STE T/PL template.
function transcompile($ast) /* Transcompile and add some boilerplate code. */
Transcompiles an abstract syntax tree to PHP.
public function load($tpl,
&$mode)
Loading a template.
public function save($tpl,
$data,
$mode)
Saves a template.
An interface.
public function __construct($src,
$transc)
public function __construct($storage_access)
public function register_tag($name,
$callback)
Register a custom tag.
public function call_tag($name,
$params,
$sub)
Calling a custom tag (builtin ones can not be called)
public function exectemplate($tpl)
Executes a template and returns the result.
public function &get_var_reference($name,
$create_if_not_exist)
Get a reference to a template variable using a variable name.
public function set_var_by_name($name,
$val)
Set a template variable by its name.
public function get_var_by_name($name)
Get a template variable by its name.
public function load($tpl,  
$quiet = False)
Load a template and return its result (blocks not included, use exectemplate for this).
public function evalbool($txt)
Test, if a text represents false (an empty / only whitespace text) or true (everything else).
The Core of STE
diff --git a/docu/nd/index/Functions.html b/docu/nd/index/Functions.html index 0420685..5a9cff5 100644 --- a/docu/nd/index/Functions.html +++ b/docu/nd/index/Functions.html @@ -11,7 +11,7 @@ if (browserType) {document.write("
");if (browserV -
Function Index
$#! · 0-9 · A · B · C · D · E · F · G · H · I · J · K · L · M · N · O · P · Q · R · S · T · U · V · W · X · Y · Z
$#!
 __construct
C
 call_tag, STECore
E
 evalbool, STECore
 exectemplate, STECore
G
 get_var_by_name, STECore
 get_var_reference, STECore
L
 load
P
 parse, ste
R
 register_tag, STECore
S
 save, StorageAccess
T
 transcompile, ste
+
Function Index
$#! · 0-9 · A · B · C · D · E · F · G · H · I · J · K · L · M · N · O · P · Q · R · S · T · U · V · W · X · Y · Z
$#!
 __construct
C
 call_tag, STECore
E
 evalbool, STECore
 exectemplate, STECore
G
 get_var_by_name, STECore
 get_var_reference, STECore
L
 load
P
 parse, ste
 precompile, ste
R
 register_tag, STECore
S
 save, StorageAccess
 set_var_by_name, STECore
T
 transcompile, ste
public function __construct($src,
$transc)
public function __construct($storage_access)
@@ -33,19 +33,19 @@ if (browserType) {document.write("
");if (browserV -
function parse($code)
Parsing a STE T/PL template.
+
function parse($code,
$tpl)
Parsing a STE T/PL template.
function precompile($code)
Precompiling STE T/PL templates.
-
public function register_tag($name,
$callback)
Register a custom tag.
+
public function register_tag($name,
$callback)
Register a custom tag.
-
public function save($tpl,
$data,
$mode)
Saves a template.
+
public function save($tpl,
$data,
$mode)
Saves a template.
public function set_var_by_name($name,
$val)
Set a template variable by its name.
-
function transcompile($ast) /* Transcompile and add some boilerplate code. */
Transcompiles an abstract syntax tree to PHP.
+
function transcompile($ast) /* Transcompile and add some boilerplate code. */
Transcompiles an abstract syntax tree to PHP.
diff --git a/docu/nd/index/General.html b/docu/nd/index/General.html index 6e92b33..25c3cbb 100644 --- a/docu/nd/index/General.html +++ b/docu/nd/index/General.html @@ -11,7 +11,7 @@ if (browserType) {document.write("
");if (browserV -
Index
$#! · 0-9 · A · B · C · D · E · F · G · H · I · J · K · L · M · N · O · P · Q · R · S · T · U · V · W · X · Y · Z
$#!
 __construct
B
$blockorder, STECore
$blocks, STECore
C
 call_tag, STECore
 Constants, ste
E
 evalbool, STECore
 exectemplate, STECore
F
 FilesystemStorageAccess
 Functions
G
 get_var_by_name, STECore
 get_var_reference, STECore
L
 License
 load
M
 MODE_SOURCE, ste
 MODE_TRANSCOMPILED, ste
P
 parse, ste
 Public variables, STECore
R
 register_tag, STECore
S
 save, StorageAccess
 ste
 STECore
 StorageAccess
 stupid_template_engine.php
T
 Template modes, ste
 transcompile, ste
V
 Variables, STECore
$vars, STECore
+
Index
$#! · 0-9 · A · B · C · D · E · F · G · H · I · J · K · L · M · N · O · P · Q · R · S · T · U · V · W · X · Y · Z
$#!
 __construct
B
$blockorder, STECore
$blocks, STECore
C
 call_tag, STECore
 Constants, ste
E
 evalbool, STECore
 exectemplate, STECore
F
 FilesystemStorageAccess
 Functions
G
 get_var_by_name, STECore
 get_var_reference, STECore
L
 License
 load
M
 MODE_SOURCE, ste
 MODE_TRANSCOMPILED, ste
P
 parse, ste
 precompile, ste
 Public variables, STECore
R
 register_tag, STECore
S
 save, StorageAccess
 set_var_by_name, STECore
 ste
 STECore
 StorageAccess
 stupid_template_engine.php
T
 Template modes, ste
 transcompile, ste
V
 Variables, STECore
$vars, STECore
public function __construct($src,
$transc)
public function __construct($storage_access)
@@ -45,23 +45,23 @@ if (browserType) {document.write("
");if (browserV -
function parse($code)
Parsing a STE T/PL template.
+
function parse($code,
$tpl)
Parsing a STE T/PL template.
function precompile($code)
Precompiling STE T/PL templates.
-
public function register_tag($name,
$callback)
Register a custom tag.
+
public function register_tag($name,
$callback)
Register a custom tag.
-
public function save($tpl,
$data,
$mode)
Saves a template.
Everything in this file is in this namespace.
The Core of STE
An interface.
The implementation of the Stupid Template Engine.
+
public function save($tpl,
$data,
$mode)
Saves a template.
public function set_var_by_name($name,
$val)
Set a template variable by its name.
Everything in this file is in this namespace.
The Core of STE
An interface.
The implementation of the Stupid Template Engine.
-
function transcompile($ast) /* Transcompile and add some boilerplate code. */
Transcompiles an abstract syntax tree to PHP.
+
function transcompile($ast) /* Transcompile and add some boilerplate code. */
Transcompiles an abstract syntax tree to PHP.
-
Associative array of all template variables.
+
Associative array of all template variables.
diff --git a/docu/nd/javascript/searchdata.js b/docu/nd/javascript/searchdata.js index 3095b6a..985032f 100644 --- a/docu/nd/javascript/searchdata.js +++ b/docu/nd/javascript/searchdata.js @@ -119,7 +119,7 @@ var indexSectionsWithContent = { "Y": false, "Z": false }, - "Constants": { + "Classes": { "Symbols": false, "Numbers": false, "A": false, @@ -127,21 +127,21 @@ var indexSectionsWithContent = { "C": false, "D": false, "E": false, - "F": false, + "F": true, "G": false, "H": false, "I": false, "J": false, "K": false, "L": false, - "M": true, + "M": false, "N": false, "O": false, "P": false, "Q": false, "R": false, - "S": false, - "T": true, + "S": true, + "T": false, "U": false, "V": false, "W": false, @@ -149,7 +149,7 @@ var indexSectionsWithContent = { "Y": false, "Z": false }, - "Classes": { + "Constants": { "Symbols": false, "Numbers": false, "A": false, @@ -157,21 +157,21 @@ var indexSectionsWithContent = { "C": false, "D": false, "E": false, - "F": true, + "F": false, "G": false, "H": false, "I": false, "J": false, "K": false, "L": false, - "M": false, + "M": true, "N": false, "O": false, "P": false, "Q": false, "R": false, - "S": true, - "T": false, + "S": false, + "T": true, "U": false, "V": false, "W": false, diff --git a/docu/nd/search/FunctionsP.html b/docu/nd/search/FunctionsP.html index c4b218e..d5fc2ab 100644 --- a/docu/nd/search/FunctionsP.html +++ b/docu/nd/search/FunctionsP.html @@ -11,7 +11,7 @@ if (browserType) {document.write("
");if (browserV -
Loading...
parse, ste
Searching...
No Matches