diff options
author | Máté Kocsis <kocsismate@woohoolabs.com> | 2020-04-13 16:28:55 +0200 |
---|---|---|
committer | Máté Kocsis <kocsismate@woohoolabs.com> | 2020-04-14 11:49:02 +0200 |
commit | c5fb4f0794c6efe06f64d6d462e14357d527b564 (patch) | |
tree | c34c643b8505356beaa091904a8e8aa9d9cd4519 /ext/xmlreader | |
parent | 80598f12507c5cbde04163289e4d2575f05d2a0c (diff) | |
download | php-git-c5fb4f0794c6efe06f64d6d462e14357d527b564.tar.gz |
Generate function entries from stubs for a couple of extensions
Migrates ext/standard, ext/tidy, ext/tokenizer,
ext/xml, ext/xml_reader, and ext/xml_writer. Closes GH-5381.
Diffstat (limited to 'ext/xmlreader')
-rw-r--r-- | ext/xmlreader/php_xmlreader.c | 88 | ||||
-rw-r--r-- | ext/xmlreader/php_xmlreader.stub.php (renamed from ext/xmlreader/xmlreader.stub.php) | 6 | ||||
-rw-r--r-- | ext/xmlreader/php_xmlreader_arginfo.h | 139 | ||||
-rw-r--r-- | ext/xmlreader/xmlreader_arginfo.h | 82 |
4 files changed, 171 insertions, 144 deletions
diff --git a/ext/xmlreader/php_xmlreader.c b/ext/xmlreader/php_xmlreader.c index 8ba87763c1..acb39a7fc9 100644 --- a/ext/xmlreader/php_xmlreader.c +++ b/ext/xmlreader/php_xmlreader.c @@ -23,13 +23,13 @@ #include "php_ini.h" #include "ext/standard/info.h" #include "php_xmlreader.h" +#include "php_xmlreader_arginfo.h" #ifdef HAVE_DOM #include "ext/dom/xml_common.h" #include "ext/dom/dom_ce.h" #endif #include <libxml/xmlreader.h> #include <libxml/uri.h> -#include "xmlreader_arginfo.h" zend_class_entry *xmlreader_class_entry; @@ -523,7 +523,7 @@ static void php_xmlreader_set_relaxng_schema(INTERNAL_FUNCTION_PARAMETERS, int t /* {{{ proto bool XMLReader::close() Closes xmlreader - current frees resources until xmlTextReaderClose is fixed in libxml */ -PHP_METHOD(xmlreader, close) +PHP_METHOD(XMLReader, close) { zval *id; xmlreader_object *intern; @@ -545,7 +545,7 @@ PHP_METHOD(xmlreader, close) /* {{{ proto string XMLReader::getAttribute(string name) Get value of an attribute from current element */ -PHP_METHOD(xmlreader, getAttribute) +PHP_METHOD(XMLReader, getAttribute) { php_xmlreader_string_arg(INTERNAL_FUNCTION_PARAM_PASSTHRU, xmlTextReaderGetAttribute); } @@ -553,7 +553,7 @@ PHP_METHOD(xmlreader, getAttribute) /* {{{ proto string XMLReader::getAttributeNo(int index) Get value of an attribute at index from current element */ -PHP_METHOD(xmlreader, getAttributeNo) +PHP_METHOD(XMLReader, getAttributeNo) { zval *id; zend_long attr_pos; @@ -579,7 +579,7 @@ PHP_METHOD(xmlreader, getAttributeNo) /* {{{ proto string XMLReader::getAttributeNs(string name, string namespaceURI) Get value of a attribute via name and namespace from current element */ -PHP_METHOD(xmlreader, getAttributeNs) +PHP_METHOD(XMLReader, getAttributeNs) { zval *id; size_t name_len = 0, ns_uri_len = 0; @@ -610,7 +610,7 @@ PHP_METHOD(xmlreader, getAttributeNs) /* {{{ proto bool XMLReader::getParserProperty(int property) Indicates whether given property (one of the parser option constants) is set or not on parser */ -PHP_METHOD(xmlreader, getParserProperty) +PHP_METHOD(XMLReader, getParserProperty) { zval *id; zend_long property; @@ -640,7 +640,7 @@ PHP_METHOD(xmlreader, getParserProperty) Returns boolean indicating if parsed document is valid or not. Must set XMLREADER_LOADDTD or XMLREADER_VALIDATE parser option prior to the first call to read or this method will always return FALSE */ -PHP_METHOD(xmlreader, isValid) +PHP_METHOD(XMLReader, isValid) { php_xmlreader_no_arg(INTERNAL_FUNCTION_PARAM_PASSTHRU, xmlTextReaderIsValid); } @@ -648,7 +648,7 @@ PHP_METHOD(xmlreader, isValid) /* {{{ proto string XMLReader::lookupNamespace(string prefix) Return namespaceURI for associated prefix on current node */ -PHP_METHOD(xmlreader, lookupNamespace) +PHP_METHOD(XMLReader, lookupNamespace) { php_xmlreader_string_arg(INTERNAL_FUNCTION_PARAM_PASSTHRU, xmlTextReaderLookupNamespace); } @@ -656,7 +656,7 @@ PHP_METHOD(xmlreader, lookupNamespace) /* {{{ proto bool XMLReader::moveToAttribute(string name) Positions reader at specified attribute - Returns TRUE on success and FALSE on failure */ -PHP_METHOD(xmlreader, moveToAttribute) +PHP_METHOD(XMLReader, moveToAttribute) { zval *id; size_t name_len = 0; @@ -690,7 +690,7 @@ PHP_METHOD(xmlreader, moveToAttribute) /* {{{ proto bool XMLReader::moveToAttributeNo(int index) Positions reader at attribute at specified index. Returns TRUE on success and FALSE on failure */ -PHP_METHOD(xmlreader, moveToAttributeNo) +PHP_METHOD(XMLReader, moveToAttributeNo) { zval *id; zend_long attr_pos; @@ -718,7 +718,7 @@ PHP_METHOD(xmlreader, moveToAttributeNo) /* {{{ proto bool XMLReader::moveToAttributeNs(string name, string namespaceURI) Positions reader at attribute spcified by name and namespaceURI. Returns TRUE on success and FALSE on failure */ -PHP_METHOD(xmlreader, moveToAttributeNs) +PHP_METHOD(XMLReader, moveToAttributeNs) { zval *id; size_t name_len=0, ns_uri_len=0; @@ -751,7 +751,7 @@ PHP_METHOD(xmlreader, moveToAttributeNs) /* {{{ proto bool XMLReader::moveToElement() Moves the position of the current instance to the node that contains the current Attribute node. */ -PHP_METHOD(xmlreader, moveToElement) +PHP_METHOD(XMLReader, moveToElement) { php_xmlreader_no_arg(INTERNAL_FUNCTION_PARAM_PASSTHRU, xmlTextReaderMoveToElement); } @@ -759,7 +759,7 @@ PHP_METHOD(xmlreader, moveToElement) /* {{{ proto bool XMLReader::moveToFirstAttribute() Moves the position of the current instance to the first attribute associated with the current node. */ -PHP_METHOD(xmlreader, moveToFirstAttribute) +PHP_METHOD(XMLReader, moveToFirstAttribute) { php_xmlreader_no_arg(INTERNAL_FUNCTION_PARAM_PASSTHRU, xmlTextReaderMoveToFirstAttribute); } @@ -767,7 +767,7 @@ PHP_METHOD(xmlreader, moveToFirstAttribute) /* {{{ proto bool XMLReader::moveToNextAttribute() Moves the position of the current instance to the next attribute associated with the current node. */ -PHP_METHOD(xmlreader, moveToNextAttribute) +PHP_METHOD(XMLReader, moveToNextAttribute) { php_xmlreader_no_arg(INTERNAL_FUNCTION_PARAM_PASSTHRU, xmlTextReaderMoveToNextAttribute); } @@ -775,7 +775,7 @@ PHP_METHOD(xmlreader, moveToNextAttribute) /* {{{ proto bool XMLReader::read() Moves the position of the current instance to the next node in the stream. */ -PHP_METHOD(xmlreader, read) +PHP_METHOD(XMLReader, read) { zval *id; int retval; @@ -803,7 +803,7 @@ PHP_METHOD(xmlreader, read) /* {{{ proto bool XMLReader::next([string localname]) Moves the position of the current instance to the next node in the stream. */ -PHP_METHOD(xmlreader, next) +PHP_METHOD(XMLReader, next) { zval *id; int retval; @@ -839,7 +839,7 @@ PHP_METHOD(xmlreader, next) /* {{{ proto bool XMLReader::open(string URI [, string encoding [, int options]]) Sets the URI that the XMLReader will parse. */ -PHP_METHOD(xmlreader, open) +PHP_METHOD(XMLReader, open) { zval *id; size_t source_len = 0, encoding_len = 0; @@ -895,7 +895,7 @@ PHP_METHOD(xmlreader, open) /* }}} */ /* Not Yet Implemented in libxml - functions exist just not coded -PHP_METHOD(xmlreader, resetState) +PHP_METHOD(XMLReader, resetState) { } @@ -903,7 +903,7 @@ PHP_METHOD(xmlreader, resetState) /* {{{ proto string XMLReader::readInnerXml() Reads the contents of the current node, including child nodes and markup. */ -PHP_METHOD(xmlreader, readInnerXml) +PHP_METHOD(XMLReader, readInnerXml) { php_xmlreader_no_arg_string(INTERNAL_FUNCTION_PARAM_PASSTHRU, xmlTextReaderReadInnerXml); } @@ -911,7 +911,7 @@ PHP_METHOD(xmlreader, readInnerXml) /* {{{ proto bool XMLReader::readOuterXml() Reads the contents of the current node, including child nodes and markup. */ -PHP_METHOD(xmlreader, readOuterXml) +PHP_METHOD(XMLReader, readOuterXml) { php_xmlreader_no_arg_string(INTERNAL_FUNCTION_PARAM_PASSTHRU, xmlTextReaderReadOuterXml); } @@ -919,7 +919,7 @@ PHP_METHOD(xmlreader, readOuterXml) /* {{{ proto bool XMLReader::readString() Reads the contents of an element or a text node as a string. */ -PHP_METHOD(xmlreader, readString) +PHP_METHOD(XMLReader, readString) { php_xmlreader_no_arg_string(INTERNAL_FUNCTION_PARAM_PASSTHRU, xmlTextReaderReadString); } @@ -927,7 +927,7 @@ PHP_METHOD(xmlreader, readString) /* {{{ proto bool XMLReader::setSchema(string filename) Use W3C XSD schema to validate the document as it is processed. Activation is only possible before the first Read(). */ -PHP_METHOD(xmlreader, setSchema) +PHP_METHOD(XMLReader, setSchema) { #ifdef LIBXML_SCHEMAS_ENABLED zval *id; @@ -970,7 +970,7 @@ PHP_METHOD(xmlreader, setSchema) /* {{{ proto bool XMLReader::setParserProperty(int property, bool value) Sets parser property (one of the parser option constants). Properties must be set after open() or XML() and before the first read() is called */ -PHP_METHOD(xmlreader, setParserProperty) +PHP_METHOD(XMLReader, setParserProperty) { zval *id; zend_long property; @@ -999,7 +999,7 @@ PHP_METHOD(xmlreader, setParserProperty) /* {{{ proto bool XMLReader::setRelaxNGSchema(string filename) Sets the string that the XMLReader will parse. */ -PHP_METHOD(xmlreader, setRelaxNGSchema) +PHP_METHOD(XMLReader, setRelaxNGSchema) { php_xmlreader_set_relaxng_schema(INTERNAL_FUNCTION_PARAM_PASSTHRU, XMLREADER_LOAD_FILE); } @@ -1007,7 +1007,7 @@ PHP_METHOD(xmlreader, setRelaxNGSchema) /* {{{ proto bool XMLReader::setRelaxNGSchemaSource(string source) Sets the string that the XMLReader will parse. */ -PHP_METHOD(xmlreader, setRelaxNGSchemaSource) +PHP_METHOD(XMLReader, setRelaxNGSchemaSource) { php_xmlreader_set_relaxng_schema(INTERNAL_FUNCTION_PARAM_PASSTHRU, XMLREADER_LOAD_STRING); } @@ -1021,7 +1021,7 @@ XMLPUBFUN int XMLCALL /* {{{ proto bool XMLReader::XML(string source [, string encoding [, int options]]) Sets the string that the XMLReader will parse. */ -PHP_METHOD(xmlreader, XML) +PHP_METHOD(XMLReader, XML) { zval *id; size_t source_len = 0, encoding_len = 0; @@ -1105,7 +1105,7 @@ PHP_METHOD(xmlreader, XML) /* {{{ proto bool XMLReader::expand() Moves the position of the current instance to the next node in the stream. */ -PHP_METHOD(xmlreader, expand) +PHP_METHOD(XMLReader, expand) { #ifdef HAVE_DOM zval *id, *basenode = NULL; @@ -1153,38 +1153,6 @@ PHP_METHOD(xmlreader, expand) } /* }}} */ -static const zend_function_entry xmlreader_functions[] /* {{{ */ = { - PHP_ME(xmlreader, close, arginfo_class_XMLReader_close, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, getAttribute, arginfo_class_XMLReader_getAttribute, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, getAttributeNo, arginfo_class_XMLReader_getAttributeNo, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, getAttributeNs, arginfo_class_XMLReader_getAttributeNs, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, getParserProperty, arginfo_class_XMLReader_getParserProperty, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, isValid, arginfo_class_XMLReader_isValid, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, lookupNamespace, arginfo_class_XMLReader_lookupNamespace, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, moveToAttributeNo, arginfo_class_XMLReader_moveToAttributeNo, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, moveToAttribute, arginfo_class_XMLReader_moveToAttribute, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, moveToAttributeNs, arginfo_class_XMLReader_moveToAttributeNs, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, moveToElement, arginfo_class_XMLReader_moveToElement, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, moveToFirstAttribute, arginfo_class_XMLReader_moveToFirstAttribute, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, moveToNextAttribute, arginfo_class_XMLReader_moveToNextAttribute, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, open, arginfo_class_XMLReader_open, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC) - PHP_ME(xmlreader, read, arginfo_class_XMLReader_read, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, next, arginfo_class_XMLReader_next, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, readInnerXml, arginfo_class_XMLReader_readInnerXml, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, readOuterXml, arginfo_class_XMLReader_readOuterXml, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, readString, arginfo_class_XMLReader_readString, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, setSchema, arginfo_class_XMLReader_setSchema, ZEND_ACC_PUBLIC) -/* Not Yet Implemented though defined in libxml as of 2.6.9dev - PHP_ME(xmlreader, resetState, NULL, ZEND_ACC_PUBLIC) -*/ - PHP_ME(xmlreader, setParserProperty, arginfo_class_XMLReader_setParserProperty, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, setRelaxNGSchema, arginfo_class_XMLReader_setRelaxNGSchema, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, setRelaxNGSchemaSource, arginfo_class_XMLReader_setRelaxNGSchemaSource, ZEND_ACC_PUBLIC) - PHP_ME(xmlreader, XML, arginfo_class_XMLReader_XML, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC) - PHP_ME(xmlreader, expand, arginfo_class_XMLReader_expand, ZEND_ACC_PUBLIC) - PHP_FE_END -}; /* }}} */ - /* {{{ PHP_MINIT_FUNCTION */ PHP_MINIT_FUNCTION(xmlreader) @@ -1202,7 +1170,7 @@ PHP_MINIT_FUNCTION(xmlreader) xmlreader_object_handlers.get_method = xmlreader_get_method; xmlreader_object_handlers.clone_obj = NULL; - INIT_CLASS_ENTRY(ce, "XMLReader", xmlreader_functions); + INIT_CLASS_ENTRY(ce, "XMLReader", class_XMLReader_methods); ce.create_object = xmlreader_objects_new; xmlreader_class_entry = zend_register_internal_class(&ce); diff --git a/ext/xmlreader/xmlreader.stub.php b/ext/xmlreader/php_xmlreader.stub.php index 5cc08651fa..cbf7bb1bee 100644 --- a/ext/xmlreader/xmlreader.stub.php +++ b/ext/xmlreader/php_xmlreader.stub.php @@ -1,5 +1,7 @@ <?php +/** @generate-function-entries */ + class XMLReader { /** @return bool */ @@ -48,7 +50,7 @@ class XMLReader public function next(string $localname = UNKNOWN) {} /** @return bool|XMLReader */ - public function open(string $URI, ?string $encoding = null, int $options = 0) {} + public static function open(string $URI, ?string $encoding = null, int $options = 0) {} /** @return string */ public function readInnerXml() {} @@ -72,7 +74,7 @@ class XMLReader public function setRelaxNGSchemaSource(?string $source) {} /** @return bool|XMLReader */ - public function XML(string $source, ?string $encoding = null, int $options = 0) {} + public static function XML(string $source, ?string $encoding = null, int $options = 0) {} /** @return DOMNode|bool */ public function expand(?DOMNode $basenode = null) {} diff --git a/ext/xmlreader/php_xmlreader_arginfo.h b/ext/xmlreader/php_xmlreader_arginfo.h new file mode 100644 index 0000000000..0b9d28c944 --- /dev/null +++ b/ext/xmlreader/php_xmlreader_arginfo.h @@ -0,0 +1,139 @@ +/* This is a generated file, edit the .stub.php file instead. */ + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_close, 0, 0, 0) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_getAttribute, 0, 0, 1) + ZEND_ARG_TYPE_INFO(0, name, IS_STRING, 0) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_getAttributeNo, 0, 0, 1) + ZEND_ARG_TYPE_INFO(0, index, IS_LONG, 0) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_getAttributeNs, 0, 0, 2) + ZEND_ARG_TYPE_INFO(0, name, IS_STRING, 0) + ZEND_ARG_TYPE_INFO(0, namespaceURI, IS_STRING, 0) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_getParserProperty, 0, 0, 1) + ZEND_ARG_TYPE_INFO(0, property, IS_LONG, 0) +ZEND_END_ARG_INFO() + +#define arginfo_class_XMLReader_isValid arginfo_class_XMLReader_close + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_lookupNamespace, 0, 0, 1) + ZEND_ARG_TYPE_INFO(0, prefix, IS_STRING, 0) +ZEND_END_ARG_INFO() + +#define arginfo_class_XMLReader_moveToAttribute arginfo_class_XMLReader_getAttribute + +#define arginfo_class_XMLReader_moveToAttributeNo arginfo_class_XMLReader_getAttributeNo + +#define arginfo_class_XMLReader_moveToAttributeNs arginfo_class_XMLReader_getAttributeNs + +#define arginfo_class_XMLReader_moveToElement arginfo_class_XMLReader_close + +#define arginfo_class_XMLReader_moveToFirstAttribute arginfo_class_XMLReader_close + +#define arginfo_class_XMLReader_moveToNextAttribute arginfo_class_XMLReader_close + +#define arginfo_class_XMLReader_read arginfo_class_XMLReader_close + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_next, 0, 0, 0) + ZEND_ARG_TYPE_INFO(0, localname, IS_STRING, 0) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_open, 0, 0, 1) + ZEND_ARG_TYPE_INFO(0, URI, IS_STRING, 0) + ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, encoding, IS_STRING, 1, "null") + ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, options, IS_LONG, 0, "0") +ZEND_END_ARG_INFO() + +#define arginfo_class_XMLReader_readInnerXml arginfo_class_XMLReader_close + +#define arginfo_class_XMLReader_readOuterXml arginfo_class_XMLReader_close + +#define arginfo_class_XMLReader_readString arginfo_class_XMLReader_close + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_setSchema, 0, 0, 1) + ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 1) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_setParserProperty, 0, 0, 2) + ZEND_ARG_TYPE_INFO(0, property, IS_LONG, 0) + ZEND_ARG_TYPE_INFO(0, value, _IS_BOOL, 0) +ZEND_END_ARG_INFO() + +#define arginfo_class_XMLReader_setRelaxNGSchema arginfo_class_XMLReader_setSchema + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_setRelaxNGSchemaSource, 0, 0, 1) + ZEND_ARG_TYPE_INFO(0, source, IS_STRING, 1) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_XML, 0, 0, 1) + ZEND_ARG_TYPE_INFO(0, source, IS_STRING, 0) + ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, encoding, IS_STRING, 1, "null") + ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, options, IS_LONG, 0, "0") +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_expand, 0, 0, 0) + ZEND_ARG_OBJ_INFO_WITH_DEFAULT_VALUE(0, basenode, DOMNode, 1, "null") +ZEND_END_ARG_INFO() + + +ZEND_METHOD(XMLReader, close); +ZEND_METHOD(XMLReader, getAttribute); +ZEND_METHOD(XMLReader, getAttributeNo); +ZEND_METHOD(XMLReader, getAttributeNs); +ZEND_METHOD(XMLReader, getParserProperty); +ZEND_METHOD(XMLReader, isValid); +ZEND_METHOD(XMLReader, lookupNamespace); +ZEND_METHOD(XMLReader, moveToAttribute); +ZEND_METHOD(XMLReader, moveToAttributeNo); +ZEND_METHOD(XMLReader, moveToAttributeNs); +ZEND_METHOD(XMLReader, moveToElement); +ZEND_METHOD(XMLReader, moveToFirstAttribute); +ZEND_METHOD(XMLReader, moveToNextAttribute); +ZEND_METHOD(XMLReader, read); +ZEND_METHOD(XMLReader, next); +ZEND_METHOD(XMLReader, open); +ZEND_METHOD(XMLReader, readInnerXml); +ZEND_METHOD(XMLReader, readOuterXml); +ZEND_METHOD(XMLReader, readString); +ZEND_METHOD(XMLReader, setSchema); +ZEND_METHOD(XMLReader, setParserProperty); +ZEND_METHOD(XMLReader, setRelaxNGSchema); +ZEND_METHOD(XMLReader, setRelaxNGSchemaSource); +ZEND_METHOD(XMLReader, XML); +ZEND_METHOD(XMLReader, expand); + + +static const zend_function_entry class_XMLReader_methods[] = { + ZEND_ME(XMLReader, close, arginfo_class_XMLReader_close, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, getAttribute, arginfo_class_XMLReader_getAttribute, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, getAttributeNo, arginfo_class_XMLReader_getAttributeNo, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, getAttributeNs, arginfo_class_XMLReader_getAttributeNs, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, getParserProperty, arginfo_class_XMLReader_getParserProperty, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, isValid, arginfo_class_XMLReader_isValid, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, lookupNamespace, arginfo_class_XMLReader_lookupNamespace, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, moveToAttribute, arginfo_class_XMLReader_moveToAttribute, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, moveToAttributeNo, arginfo_class_XMLReader_moveToAttributeNo, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, moveToAttributeNs, arginfo_class_XMLReader_moveToAttributeNs, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, moveToElement, arginfo_class_XMLReader_moveToElement, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, moveToFirstAttribute, arginfo_class_XMLReader_moveToFirstAttribute, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, moveToNextAttribute, arginfo_class_XMLReader_moveToNextAttribute, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, read, arginfo_class_XMLReader_read, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, next, arginfo_class_XMLReader_next, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, open, arginfo_class_XMLReader_open, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC) + ZEND_ME(XMLReader, readInnerXml, arginfo_class_XMLReader_readInnerXml, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, readOuterXml, arginfo_class_XMLReader_readOuterXml, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, readString, arginfo_class_XMLReader_readString, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, setSchema, arginfo_class_XMLReader_setSchema, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, setParserProperty, arginfo_class_XMLReader_setParserProperty, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, setRelaxNGSchema, arginfo_class_XMLReader_setRelaxNGSchema, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, setRelaxNGSchemaSource, arginfo_class_XMLReader_setRelaxNGSchemaSource, ZEND_ACC_PUBLIC) + ZEND_ME(XMLReader, XML, arginfo_class_XMLReader_XML, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC) + ZEND_ME(XMLReader, expand, arginfo_class_XMLReader_expand, ZEND_ACC_PUBLIC) + ZEND_FE_END +}; diff --git a/ext/xmlreader/xmlreader_arginfo.h b/ext/xmlreader/xmlreader_arginfo.h deleted file mode 100644 index 39d84763f2..0000000000 --- a/ext/xmlreader/xmlreader_arginfo.h +++ /dev/null @@ -1,82 +0,0 @@ -/* This is a generated file, edit the .stub.php file instead. */ - -ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_close, 0, 0, 0) -ZEND_END_ARG_INFO() - -ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_getAttribute, 0, 0, 1) - ZEND_ARG_TYPE_INFO(0, name, IS_STRING, 0) -ZEND_END_ARG_INFO() - -ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_getAttributeNo, 0, 0, 1) - ZEND_ARG_TYPE_INFO(0, index, IS_LONG, 0) -ZEND_END_ARG_INFO() - -ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_getAttributeNs, 0, 0, 2) - ZEND_ARG_TYPE_INFO(0, name, IS_STRING, 0) - ZEND_ARG_TYPE_INFO(0, namespaceURI, IS_STRING, 0) -ZEND_END_ARG_INFO() - -ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_getParserProperty, 0, 0, 1) - ZEND_ARG_TYPE_INFO(0, property, IS_LONG, 0) -ZEND_END_ARG_INFO() - -#define arginfo_class_XMLReader_isValid arginfo_class_XMLReader_close - -ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_lookupNamespace, 0, 0, 1) - ZEND_ARG_TYPE_INFO(0, prefix, IS_STRING, 0) -ZEND_END_ARG_INFO() - -#define arginfo_class_XMLReader_moveToAttribute arginfo_class_XMLReader_getAttribute - -#define arginfo_class_XMLReader_moveToAttributeNo arginfo_class_XMLReader_getAttributeNo - -#define arginfo_class_XMLReader_moveToAttributeNs arginfo_class_XMLReader_getAttributeNs - -#define arginfo_class_XMLReader_moveToElement arginfo_class_XMLReader_close - -#define arginfo_class_XMLReader_moveToFirstAttribute arginfo_class_XMLReader_close - -#define arginfo_class_XMLReader_moveToNextAttribute arginfo_class_XMLReader_close - -#define arginfo_class_XMLReader_read arginfo_class_XMLReader_close - -ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_next, 0, 0, 0) - ZEND_ARG_TYPE_INFO(0, localname, IS_STRING, 0) -ZEND_END_ARG_INFO() - -ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_open, 0, 0, 1) - ZEND_ARG_TYPE_INFO(0, URI, IS_STRING, 0) - ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, encoding, IS_STRING, 1, "null") - ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, options, IS_LONG, 0, "0") -ZEND_END_ARG_INFO() - -#define arginfo_class_XMLReader_readInnerXml arginfo_class_XMLReader_close - -#define arginfo_class_XMLReader_readOuterXml arginfo_class_XMLReader_close - -#define arginfo_class_XMLReader_readString arginfo_class_XMLReader_close - -ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_setSchema, 0, 0, 1) - ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 1) -ZEND_END_ARG_INFO() - -ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_setParserProperty, 0, 0, 2) - ZEND_ARG_TYPE_INFO(0, property, IS_LONG, 0) - ZEND_ARG_TYPE_INFO(0, value, _IS_BOOL, 0) -ZEND_END_ARG_INFO() - -#define arginfo_class_XMLReader_setRelaxNGSchema arginfo_class_XMLReader_setSchema - -ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_setRelaxNGSchemaSource, 0, 0, 1) - ZEND_ARG_TYPE_INFO(0, source, IS_STRING, 1) -ZEND_END_ARG_INFO() - -ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_XML, 0, 0, 1) - ZEND_ARG_TYPE_INFO(0, source, IS_STRING, 0) - ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, encoding, IS_STRING, 1, "null") - ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, options, IS_LONG, 0, "0") -ZEND_END_ARG_INFO() - -ZEND_BEGIN_ARG_INFO_EX(arginfo_class_XMLReader_expand, 0, 0, 0) - ZEND_ARG_OBJ_INFO_WITH_DEFAULT_VALUE(0, basenode, DOMNode, 1, "null") -ZEND_END_ARG_INFO() |