@@ -22,14 +22,14 @@ discard block |
||
22 | 22 | * $xml can either be an XML string, a DOMDocument, or a DOMElement. |
23 | 23 | * You can also pass FALSE or NULL (or omit it) and load XML later using loadXML or loadHTML |
24 | 24 | * |
25 | - * @param mixed $auto_register_namespaces |
|
25 | + * @param boolean $auto_register_namespaces |
|
26 | 26 | * Auto-register namespaces. All namespaces in the root element will be registered for use in xpath queries. |
27 | 27 | * Namespaces that are not declared in the root element will not be auto-registered |
28 | 28 | * Defaults to TRUE (Meaning it will auto register all auxiliary namespaces but not the default namespace). |
29 | 29 | * Pass a prefix string to automatically register the default namespace. |
30 | 30 | * Pass FALSE to disable auto-namespace registeration |
31 | 31 | * |
32 | - * @param bool $error_checking |
|
32 | + * @param string|boolean $error_checking |
|
33 | 33 | * Can be 'strict', 'warning', or 'none. Defaults to 'strict'. |
34 | 34 | * 'none' supresses all errors |
35 | 35 | * 'warning' is the default behavior in DOMDocument |
@@ -489,10 +489,10 @@ discard block |
||
489 | 489 | /** |
490 | 490 | * Given a pair of nodes, replace the first with the second |
491 | 491 | * |
492 | - * @param mixed $node |
|
492 | + * @param \DOMElement $node |
|
493 | 493 | * Node to be replaced. Can either be an xpath string or a DOMDocument (or even a DOMNode). |
494 | 494 | * |
495 | - * @param mixed $replace |
|
495 | + * @param \DOMElement $replace |
|
496 | 496 | * Replace $node with $replace. Replace can be an XML string, or a DOMNode |
497 | 497 | * |
498 | 498 | * @return replaced node |
@@ -552,7 +552,7 @@ discard block |
||
552 | 552 | * $context can either be an xpath string, or a DOMElement. Ommiting it |
553 | 553 | * results in transforming the entire document |
554 | 554 | * |
555 | - * @return a new DOMDoc |
|
555 | + * @return DOMDoc new DOMDoc |
|
556 | 556 | */ |
557 | 557 | function tranform($xsl, $context = NULL) { |
558 | 558 | if (!$context) { |
@@ -578,8 +578,6 @@ discard block |
||
578 | 578 | * @param mixed $node |
579 | 579 | * Node to be changed. Can either be an xpath string or a DOMElement. |
580 | 580 | * |
581 | - * @param mixed $replace |
|
582 | - * Replace $node with $replace. Replace can be an XML string, or a DOMNode |
|
583 | 581 | * |
584 | 582 | * @return the changed node |
585 | 583 | * The node with the new namespace. The node will also be changed in-situ in the document as well. |
@@ -635,7 +633,7 @@ discard block |
||
635 | 633 | * it will transform all elements with xlink:type = simple into a <a href> element. |
636 | 634 | * Alternatively you may specify your own xpath for selecting which elements get transformed |
637 | 635 | * into <a href> tags. |
638 | - * @return HTML string |
|
636 | + * @return string string |
|
639 | 637 | */ |
640 | 638 | function asHTML($context = NULL, $options = array()) { |
641 | 639 | $xslSimple = ' |
@@ -717,7 +715,7 @@ discard block |
||
717 | 715 | * $context can either be an xpath string, or a DOMElement. Ommiting it |
718 | 716 | * results in outputting the entire document |
719 | 717 | * |
720 | - * @return XML string |
|
718 | + * @return string string |
|
721 | 719 | */ |
722 | 720 | function out($context = NULL) { |
723 | 721 | $this->createContext($context, 'xpath'); |
@@ -752,6 +750,9 @@ discard block |
||
752 | 750 | return $this->out(); |
753 | 751 | } |
754 | 752 | |
753 | + /** |
|
754 | + * @param string|boolean $error_checking |
|
755 | + */ |
|
755 | 756 | public function setErrorChecking($error_checking) { |
756 | 757 | // Check up error-checking |
757 | 758 | if ($error_checking == FALSE) { |
@@ -53,6 +53,9 @@ |
||
53 | 53 | return isset($this->array[$this->position]); |
54 | 54 | } |
55 | 55 | |
56 | + /** |
|
57 | + * @param integer $index |
|
58 | + */ |
|
56 | 59 | function item($index) { |
57 | 60 | if (isset($this->array[$index])) { |
58 | 61 | return $this->array[$index]; |