[3.1.0] Remove multi-description functionality as well as file detection.
[htmlpurifier.git] / library / HTMLPurifier / ConfigDef / Directive.php
blob65ea4740edcb4b1ea6bcc6f17402afbe4681089b
1 <?php
3 /**
4 * Structure object containing definition of a directive.
5 * @note This structure does not contain default values
6 */
7 class HTMLPurifier_ConfigDef_Directive extends HTMLPurifier_ConfigDef
10 public $class = 'directive';
12 public function __construct(
13 $type = null,
14 $description = null,
15 $allow_null = null,
16 $allowed = null,
17 $aliases = null
18 ) {
19 if ( $type !== null) $this->type = $type;
20 if ($description !== null) $this->description = $description;
21 if ( $allow_null !== null) $this->allow_null = $allow_null;
22 if ( $allowed !== null) $this->allowed = $allowed;
23 if ( $aliases !== null) $this->aliases = $aliases;
26 /**
27 * Allowed type of the directive. Values are:
28 * - string
29 * - istring (case insensitive string)
30 * - int
31 * - float
32 * - bool
33 * - lookup (array of value => true)
34 * - list (regular numbered index array)
35 * - hash (array of key => value)
36 * - mixed (anything goes)
38 public $type = 'mixed';
40 /**
41 * Plaintext description of the configuration entity is.
43 public $description = null;
45 /**
46 * Is null allowed? Has no effect for mixed type.
47 * @bool
49 public $allow_null = false;
51 /**
52 * Lookup table of allowed values of the element, bool true if all allowed.
54 public $allowed = true;
56 /**
57 * Hash of value aliases, i.e. values that are equivalent.
59 public $aliases = array();
61 /**
62 * Advisory list of directive aliases, i.e. other directives that
63 * redirect here
65 public $directiveAliases = array();