本文整理汇总了PHP中XML_Unserializer::XML_Unserializer方法的典型用法代码示例。如果您正苦于以下问题:PHP XML_Unserializer::XML_Unserializer方法的具体用法?PHP XML_Unserializer::XML_Unserializer怎么用?PHP XML_Unserializer::XML_Unserializer使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类XML_Unserializer
的用法示例。
在下文中一共展示了XML_Unserializer::XML_Unserializer方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: array
function __construct($variables, $fail_on_invalid_names = true, $structure = false, $valid_types = array(), $force_defaults = true)
{
// force ISO-8859-1 due to different defaults for PHP4 and PHP5
// todo: this probably needs to be investigated some more and cleaned up
$this->options['encoding'] = 'ISO-8859-1';
$this->options['XML_UNSERIALIZER_OPTION_ATTRIBUTES_PARSE'] = true;
$this->options['XML_UNSERIALIZER_OPTION_ATTRIBUTES_ARRAYKEY'] = false;
$this->options['forceEnum'] = array('table', 'field', 'index', 'insert', 'update', 'delete');
/*
* todo: find a way to force the following items not to be parsed as arrays
* as it cause problems in functions with multiple arguments
*/
//$this->options['forceNEnum'] = array('value', 'column');
$this->variables = $variables;
$this->structure = $structure;
$this->validator =& new MDB2_Schema_Validate($fail_on_invalid_names, $valid_types, $force_defaults);
parent::XML_Unserializer($this->options);
}