SUIT Framework

Scripting Using Integrated Templates

Docs - defaultconfig

07/31/2010: SUIT 2.0.1 and Rulebox 1.1.0 released.

Available Since: SUIT (2.0.0)

Transform a string using rules. The function calls tokens, parse, and walk all in one convenient call.

Syntax dict suit.defaultconfig ( dict config )
Parameters
config

The dict to fill.

Return Value
Key Description Default
escape str: The escape string. \
insensitive bool: Whether or not the searching should be done case insensitively. True
log bool: Whether or not the execute call should be logged. True
mismatched bool: Whether or not to parse if the closing string does not match the opening string. False
unclosed bool: Whether or not the SUIT should walk through the node if it was opened but not closed. False
Examples
Basic Usage
PHP
<?php
require 'suit.class.php';
$suit = new SUIT();
$config = array
(
    'escape' => ''
);
$config = $suit->defaultconfig($config);
/*
Result: array
(
    'unclosed' => false,
    'insensitive' => true,
    'log' => true,
    'mismatched' => false,
    'escape' => ''
)
*/
?>
Python
import suit
config = {
    'escape': ''
}
config = suit.defaultconfig(config)
# Result: {
#     'unclosed': False,
#     'insensitive': True,
#     'log': True,
#     'mismatched': False,
#     'escape': ''
# }
See Also