dom_fe.h 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280
  1. /*
  2. +----------------------------------------------------------------------+
  3. | PHP Version 5 |
  4. +----------------------------------------------------------------------+
  5. | Copyright (c) 1997-2016 The PHP Group |
  6. +----------------------------------------------------------------------+
  7. | This source file is subject to version 3.01 of the PHP license, |
  8. | that is bundled with this package in the file LICENSE, and is |
  9. | available through the world-wide-web at the following url: |
  10. | http://www.php.net/license/3_01.txt |
  11. | If you did not receive a copy of the PHP license and are unable to |
  12. | obtain it through the world-wide-web, please send a note to |
  13. | license@php.net so we can mail you a copy immediately. |
  14. +----------------------------------------------------------------------+
  15. | Authors: Christian Stocker <chregu@php.net> |
  16. | Rob Richards <rrichards@php.net> |
  17. +----------------------------------------------------------------------+
  18. */
  19. /* $Id$ */
  20. #ifndef DOM_FE_H
  21. #define DOM_FE_H
  22. extern const zend_function_entry php_dom_domexception_class_functions[];
  23. extern const zend_function_entry php_dom_domstringlist_class_functions[];
  24. extern const zend_function_entry php_dom_namelist_class_functions[];
  25. extern const zend_function_entry php_dom_domimplementationlist_class_functions[];
  26. extern const zend_function_entry php_dom_domimplementationsource_class_functions[];
  27. extern const zend_function_entry php_dom_domimplementation_class_functions[];
  28. extern const zend_function_entry php_dom_documentfragment_class_functions[];
  29. extern const zend_function_entry php_dom_document_class_functions[];
  30. extern const zend_function_entry php_dom_node_class_functions[];
  31. extern const zend_function_entry php_dom_nodelist_class_functions[];
  32. extern const zend_function_entry php_dom_namednodemap_class_functions[];
  33. extern const zend_function_entry php_dom_characterdata_class_functions[];
  34. extern const zend_function_entry php_dom_attr_class_functions[];
  35. extern const zend_function_entry php_dom_element_class_functions[];
  36. extern const zend_function_entry php_dom_text_class_functions[];
  37. extern const zend_function_entry php_dom_comment_class_functions[];
  38. extern const zend_function_entry php_dom_typeinfo_class_functions[];
  39. extern const zend_function_entry php_dom_userdatahandler_class_functions[];
  40. extern const zend_function_entry php_dom_domerror_class_functions[];
  41. extern const zend_function_entry php_dom_domerrorhandler_class_functions[];
  42. extern const zend_function_entry php_dom_domlocator_class_functions[];
  43. extern const zend_function_entry php_dom_domconfiguration_class_functions[];
  44. extern const zend_function_entry php_dom_cdatasection_class_functions[];
  45. extern const zend_function_entry php_dom_documenttype_class_functions[];
  46. extern const zend_function_entry php_dom_notation_class_functions[];
  47. extern const zend_function_entry php_dom_entity_class_functions[];
  48. extern const zend_function_entry php_dom_entityreference_class_functions[];
  49. extern const zend_function_entry php_dom_processinginstruction_class_functions[];
  50. extern const zend_function_entry php_dom_string_extend_class_functions[];
  51. extern const zend_function_entry php_dom_xpath_class_functions[];
  52. /* domexception errors */
  53. typedef enum {
  54. /* PHP_ERR is non-spec code for PHP errors: */
  55. PHP_ERR = 0,
  56. INDEX_SIZE_ERR = 1,
  57. DOMSTRING_SIZE_ERR = 2,
  58. HIERARCHY_REQUEST_ERR = 3,
  59. WRONG_DOCUMENT_ERR = 4,
  60. INVALID_CHARACTER_ERR = 5,
  61. NO_DATA_ALLOWED_ERR = 6,
  62. NO_MODIFICATION_ALLOWED_ERR = 7,
  63. NOT_FOUND_ERR = 8,
  64. NOT_SUPPORTED_ERR = 9,
  65. INUSE_ATTRIBUTE_ERR = 10,
  66. /* Introduced in DOM Level 2: */
  67. INVALID_STATE_ERR = 11,
  68. /* Introduced in DOM Level 2: */
  69. SYNTAX_ERR = 12,
  70. /* Introduced in DOM Level 2: */
  71. INVALID_MODIFICATION_ERR = 13,
  72. /* Introduced in DOM Level 2: */
  73. NAMESPACE_ERR = 14,
  74. /* Introduced in DOM Level 2: */
  75. INVALID_ACCESS_ERR = 15,
  76. /* Introduced in DOM Level 3: */
  77. VALIDATION_ERR = 16
  78. } dom_exception_code;
  79. /* domstringlist methods */
  80. PHP_FUNCTION(dom_domstringlist_item);
  81. /* domnamelist methods */
  82. PHP_FUNCTION(dom_namelist_get_name);
  83. PHP_FUNCTION(dom_namelist_get_namespace_uri);
  84. /* domimplementationlist methods */
  85. PHP_FUNCTION(dom_domimplementationlist_item);
  86. /* domimplementationsource methods */
  87. PHP_FUNCTION(dom_domimplementationsource_get_domimplementation);
  88. PHP_FUNCTION(dom_domimplementationsource_get_domimplementations);
  89. /* domimplementation methods */
  90. PHP_METHOD(domimplementation, hasFeature);
  91. PHP_METHOD(domimplementation, createDocumentType);
  92. PHP_METHOD(domimplementation, createDocument);
  93. PHP_METHOD(domimplementation, getFeature);
  94. /* domdocumentfragment methods */
  95. PHP_METHOD(domdocumentfragment, __construct);
  96. PHP_METHOD(domdocumentfragment, appendXML);
  97. /* domdocument methods */
  98. PHP_FUNCTION(dom_document_create_element);
  99. PHP_FUNCTION(dom_document_create_document_fragment);
  100. PHP_FUNCTION(dom_document_create_text_node);
  101. PHP_FUNCTION(dom_document_create_comment);
  102. PHP_FUNCTION(dom_document_create_cdatasection);
  103. PHP_FUNCTION(dom_document_create_processing_instruction);
  104. PHP_FUNCTION(dom_document_create_attribute);
  105. PHP_FUNCTION(dom_document_create_entity_reference);
  106. PHP_FUNCTION(dom_document_get_elements_by_tag_name);
  107. PHP_FUNCTION(dom_document_import_node);
  108. PHP_FUNCTION(dom_document_create_element_ns);
  109. PHP_FUNCTION(dom_document_create_attribute_ns);
  110. PHP_FUNCTION(dom_document_get_elements_by_tag_name_ns);
  111. PHP_FUNCTION(dom_document_get_element_by_id);
  112. PHP_FUNCTION(dom_document_adopt_node);
  113. PHP_FUNCTION(dom_document_normalize_document);
  114. PHP_FUNCTION(dom_document_rename_node);
  115. PHP_METHOD(domdocument, __construct);
  116. /* convienience methods */
  117. PHP_METHOD(domdocument, load);
  118. PHP_FUNCTION(dom_document_save);
  119. PHP_METHOD(domdocument, loadXML);
  120. PHP_FUNCTION(dom_document_savexml);
  121. PHP_FUNCTION(dom_document_validate);
  122. PHP_FUNCTION(dom_document_xinclude);
  123. PHP_METHOD(domdocument, registerNodeClass);
  124. #if defined(LIBXML_HTML_ENABLED)
  125. PHP_METHOD(domdocument, loadHTML);
  126. PHP_METHOD(domdocument, loadHTMLFile);
  127. PHP_FUNCTION(dom_document_save_html);
  128. PHP_FUNCTION(dom_document_save_html_file);
  129. #endif /* defined(LIBXML_HTML_ENABLED) */
  130. #if defined(LIBXML_SCHEMAS_ENABLED)
  131. PHP_FUNCTION(dom_document_schema_validate_file);
  132. PHP_FUNCTION(dom_document_schema_validate_xml);
  133. PHP_FUNCTION(dom_document_relaxNG_validate_file);
  134. PHP_FUNCTION(dom_document_relaxNG_validate_xml);
  135. #endif
  136. /* domnode methods */
  137. PHP_FUNCTION(dom_node_insert_before);
  138. PHP_FUNCTION(dom_node_replace_child);
  139. PHP_FUNCTION(dom_node_remove_child);
  140. PHP_FUNCTION(dom_node_append_child);
  141. PHP_FUNCTION(dom_node_has_child_nodes);
  142. PHP_FUNCTION(dom_node_clone_node);
  143. PHP_FUNCTION(dom_node_normalize);
  144. PHP_FUNCTION(dom_node_is_supported);
  145. PHP_FUNCTION(dom_node_has_attributes);
  146. PHP_FUNCTION(dom_node_compare_document_position);
  147. PHP_FUNCTION(dom_node_is_same_node);
  148. PHP_FUNCTION(dom_node_lookup_prefix);
  149. PHP_FUNCTION(dom_node_is_default_namespace);
  150. PHP_FUNCTION(dom_node_lookup_namespace_uri);
  151. PHP_FUNCTION(dom_node_is_equal_node);
  152. PHP_FUNCTION(dom_node_get_feature);
  153. PHP_FUNCTION(dom_node_set_user_data);
  154. PHP_FUNCTION(dom_node_get_user_data);
  155. PHP_METHOD(domnode, C14N);
  156. PHP_METHOD(domnode, C14NFile);
  157. PHP_METHOD(domnode, getNodePath);
  158. PHP_METHOD(domnode, getLineNo);
  159. /* domnodelist methods */
  160. PHP_FUNCTION(dom_nodelist_item);
  161. /* domnamednodemap methods */
  162. PHP_FUNCTION(dom_namednodemap_get_named_item);
  163. PHP_FUNCTION(dom_namednodemap_set_named_item);
  164. PHP_FUNCTION(dom_namednodemap_remove_named_item);
  165. PHP_FUNCTION(dom_namednodemap_item);
  166. PHP_FUNCTION(dom_namednodemap_get_named_item_ns);
  167. PHP_FUNCTION(dom_namednodemap_set_named_item_ns);
  168. PHP_FUNCTION(dom_namednodemap_remove_named_item_ns);
  169. /* domcharacterdata methods */
  170. PHP_FUNCTION(dom_characterdata_substring_data);
  171. PHP_FUNCTION(dom_characterdata_append_data);
  172. PHP_FUNCTION(dom_characterdata_insert_data);
  173. PHP_FUNCTION(dom_characterdata_delete_data);
  174. PHP_FUNCTION(dom_characterdata_replace_data);
  175. /* domattr methods */
  176. PHP_FUNCTION(dom_attr_is_id);
  177. PHP_METHOD(domattr, __construct);
  178. /* domelement methods */
  179. PHP_FUNCTION(dom_element_get_attribute);
  180. PHP_FUNCTION(dom_element_set_attribute);
  181. PHP_FUNCTION(dom_element_remove_attribute);
  182. PHP_FUNCTION(dom_element_get_attribute_node);
  183. PHP_FUNCTION(dom_element_set_attribute_node);
  184. PHP_FUNCTION(dom_element_remove_attribute_node);
  185. PHP_FUNCTION(dom_element_get_elements_by_tag_name);
  186. PHP_FUNCTION(dom_element_get_attribute_ns);
  187. PHP_FUNCTION(dom_element_set_attribute_ns);
  188. PHP_FUNCTION(dom_element_remove_attribute_ns);
  189. PHP_FUNCTION(dom_element_get_attribute_node_ns);
  190. PHP_FUNCTION(dom_element_set_attribute_node_ns);
  191. PHP_FUNCTION(dom_element_get_elements_by_tag_name_ns);
  192. PHP_FUNCTION(dom_element_has_attribute);
  193. PHP_FUNCTION(dom_element_has_attribute_ns);
  194. PHP_FUNCTION(dom_element_set_id_attribute);
  195. PHP_FUNCTION(dom_element_set_id_attribute_ns);
  196. PHP_FUNCTION(dom_element_set_id_attribute_node);
  197. PHP_METHOD(domelement, __construct);
  198. /* domtext methods */
  199. PHP_FUNCTION(dom_text_split_text);
  200. PHP_FUNCTION(dom_text_is_whitespace_in_element_content);
  201. PHP_FUNCTION(dom_text_replace_whole_text);
  202. PHP_METHOD(domtext, __construct);
  203. /* domcomment methods */
  204. PHP_METHOD(domcomment, __construct);
  205. /* domtypeinfo methods */
  206. /* domuserdatahandler methods */
  207. PHP_FUNCTION(dom_userdatahandler_handle);
  208. /* domdomerror methods */
  209. /* domerrorhandler methods */
  210. PHP_FUNCTION(dom_domerrorhandler_handle_error);
  211. /* domlocator methods */
  212. /* domconfiguration methods */
  213. PHP_FUNCTION(dom_domconfiguration_set_parameter);
  214. PHP_FUNCTION(dom_domconfiguration_get_parameter);
  215. PHP_FUNCTION(dom_domconfiguration_can_set_parameter);
  216. /* domcdatasection methods */
  217. PHP_METHOD(domcdatasection, __construct);
  218. /* domdocumenttype methods */
  219. /* domnotation methods */
  220. /* domentity methods */
  221. /* domentityreference methods */
  222. PHP_METHOD(domentityreference, __construct);
  223. /* domprocessinginstruction methods */
  224. PHP_METHOD(domprocessinginstruction, __construct);
  225. /* string_extend methods */
  226. PHP_FUNCTION(dom_string_extend_find_offset16);
  227. PHP_FUNCTION(dom_string_extend_find_offset32);
  228. #if defined(LIBXML_XPATH_ENABLED)
  229. /* xpath methods */
  230. PHP_METHOD(domxpath, __construct);
  231. PHP_FUNCTION(dom_xpath_register_ns);
  232. PHP_FUNCTION(dom_xpath_query);
  233. PHP_FUNCTION(dom_xpath_evaluate);
  234. PHP_FUNCTION(dom_xpath_register_php_functions);
  235. #endif
  236. #endif /* DOM_FE_H */
  237. /*
  238. * Local variables:
  239. * tab-width: 4
  240. * c-basic-offset: 4
  241. * End:
  242. * vim600: noet sw=4 ts=4 fdm=marker
  243. * vim<600: noet sw=4 ts=4
  244. */