1
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2025-08-04 21:28:06 +02:00

Convert to PHP 5 only codebase, adding visibility modifiers to all members and methods in the main library area (function only for test methods)

git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/trunk@1458 48356398-32a2-884e-a903-53898d9a118a
This commit is contained in:
Edward Z. Yang
2007-11-25 02:24:39 +00:00
parent 85a23bacb6
commit 43f01925cd
195 changed files with 1003 additions and 1064 deletions

View File

@@ -9,9 +9,9 @@ require_once 'HTMLPurifier/ConfigDef.php';
class HTMLPurifier_ConfigDef_Directive extends HTMLPurifier_ConfigDef
{
var $class = 'directive';
public $class = 'directive';
function HTMLPurifier_ConfigDef_Directive(
public function HTMLPurifier_ConfigDef_Directive(
$type = null,
$descriptions = null,
$allow_null = null,
@@ -37,40 +37,40 @@ class HTMLPurifier_ConfigDef_Directive extends HTMLPurifier_ConfigDef
* - hash (array of key => value)
* - mixed (anything goes)
*/
var $type = 'mixed';
public $type = 'mixed';
/**
* Plaintext descriptions of the configuration entity is. Organized by
* file and line number, so multiple descriptions are allowed.
*/
var $descriptions = array();
public $descriptions = array();
/**
* Is null allowed? Has no effect for mixed type.
* @bool
*/
var $allow_null = false;
public $allow_null = false;
/**
* Lookup table of allowed values of the element, bool true if all allowed.
*/
var $allowed = true;
public $allowed = true;
/**
* Hash of value aliases, i.e. values that are equivalent.
*/
var $aliases = array();
public $aliases = array();
/**
* Advisory list of directive aliases, i.e. other directives that
* redirect here
*/
var $directiveAliases = array();
public $directiveAliases = array();
/**
* Adds a description to the array
*/
function addDescription($file, $line, $description) {
public function addDescription($file, $line, $description) {
if (!isset($this->descriptions[$file])) $this->descriptions[$file] = array();
$this->descriptions[$file][$line] = $description;
}

View File

@@ -7,18 +7,18 @@ require_once 'HTMLPurifier/ConfigDef.php';
*/
class HTMLPurifier_ConfigDef_DirectiveAlias extends HTMLPurifier_ConfigDef
{
var $class = 'alias';
public $class = 'alias';
/**
* Namespace being aliased to
*/
var $namespace;
public $namespace;
/**
* Directive being aliased to
*/
var $name;
public $name;
function HTMLPurifier_ConfigDef_DirectiveAlias($namespace, $name) {
public function HTMLPurifier_ConfigDef_DirectiveAlias($namespace, $name) {
$this->namespace = $namespace;
$this->name = $name;
}

View File

@@ -7,16 +7,16 @@ require_once 'HTMLPurifier/ConfigDef.php';
*/
class HTMLPurifier_ConfigDef_Namespace extends HTMLPurifier_ConfigDef {
function HTMLPurifier_ConfigDef_Namespace($description = null) {
public function HTMLPurifier_ConfigDef_Namespace($description = null) {
$this->description = $description;
}
var $class = 'namespace';
public $class = 'namespace';
/**
* String description of what kinds of directives go in this namespace.
*/
var $description;
public $description;
}