Commit graph

201 commits

Author SHA1 Message Date
Christoph M. Becker
ae9210b472
Fix typo 2021-04-29 12:13:07 +02:00
Christoph M. Becker
f7503d75d5
Fix typo
Pointed out by @GSokol.
2021-04-28 14:02:24 +02:00
Grigorii Sokolik
e504d84881
Add note for passing references to invoke methods.
During running unit tests for a private method I faced the lack of
documentation about how to pass arguments by references through `invoke`
method. (See https://bugs.php.net/bug.php?id=80991) I'd like to add
notes to clarify the workaround to make it easier for others.

Co-authored-by: Christoph M. Becker <cmbecker69@gmx.de>

Closes GH-550.
2021-04-28 11:34:43 +02:00
Sergey Panteleev
f9c4a68ef4
Removed references to PHP 5, PHP 7.0 (#548) 2021-04-26 11:46:55 +03:00
Sergey Panteleev
5fabd07880
Removed Changelog entries for PHP 5, PHP 7.0 (#543) 2021-04-22 17:52:58 +03:00
Yoshinari Takaoka
f114783c6e changed deprecation function warning as of PHP 8.0.0. 2021-02-10 03:59:29 +09:00
Anna Filina
cc422ba8c7 Fix #55026: Document access to protected/private members using reflection
Closes GH-325.
2021-01-12 12:57:40 +01:00
George Peter Banyard
a2afb71b63 Extend ReflectionProperty::hasDefaultValue() example
Closes GH-295.
2021-01-08 00:14:21 +01:00
Christoph M. Becker
8217228b33 Restore overloaded signature of reflectionmethod::__construct()
Still not great, but that constructor is a mess.
2021-01-03 00:32:27 +01:00
Christoph M. Becker
fcb74e8f48 Remove duplicate constructorsynopsis 2021-01-02 16:55:35 +01:00
Máté Kocsis
98df2cf9a9 Generate reflection methodsynopses based on stubs
We also document the new `$filter` parameter for the `ReflectionClass`
methods `::getConstants()` and `::getReflectionConstants()` and the
respective constants.

Co-authored-by: Christoph M. Becker <cmbecker69@gmx.de>

Closes GH-298.
2020-12-31 17:03:54 +01:00
Christoph Michael Becker
c40f07c937 Fix #80247: ReflectionType does not have an isBuiltin() method
Closes GH-273.


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@352224 c90b9560-bf6c-de11-be94-00142212c4b1
2020-12-27 23:23:02 +00:00
Christoph Michael Becker
565b5f3de9 Fix example output for PHP 7.0.0 and up
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@352077 c90b9560-bf6c-de11-be94-00142212c4b1
2020-12-14 20:10:29 +00:00
Christoph Michael Becker
e41806c30b Revert revision(s) 351724 from phpdoc/en/trunk:
Document false and null return types

Cf. <https://news-web.php.net/php.doc.cvs/17645>.


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@351730 c90b9560-bf6c-de11-be94-00142212c4b1
2020-11-28 18:05:44 +00:00
Christoph Michael Becker
4754397753 Revert revision 351727 from phpdoc/en/trunk:
Document false and null return types

Cf. <https://news-web.php.net/php.doc.cvs/17645>.


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@351729 c90b9560-bf6c-de11-be94-00142212c4b1
2020-11-28 17:58:32 +00:00
Jakub Vrana
69bd53265b Document false and null return types
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@351727 c90b9560-bf6c-de11-be94-00142212c4b1
2020-11-28 15:12:46 +00:00
Jakub Vrana
c80da7c04a Document false and null return types
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@351724 c90b9560-bf6c-de11-be94-00142212c4b1
2020-11-28 12:54:59 +00:00
Christoph Michael Becker
831603509b Fix return type
This integrates user note 125527.


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@351494 c90b9560-bf6c-de11-be94-00142212c4b1
2020-11-22 13:32:41 +00:00
Christoph Michael Becker
91de67290f Fix #78707: ReflectionClass::implementsInterface - incomplete documentation
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@351217 c90b9560-bf6c-de11-be94-00142212c4b1
2020-11-04 11:40:49 +00:00
Christoph Michael Becker
86e6094e86 Use canonical type names
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@351133 c90b9560-bf6c-de11-be94-00142212c4b1
2020-11-02 15:39:04 +00:00
Christoph Michael Becker
9e0f03ac35 Proper variadics instead of pseudo variadics
We markup variadic parameters with the `rep=repeat` standard DocBook
attribute of `<methodparam>`, and use proper variable names instead of
using the old pseudo variable name `...`.


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@351129 c90b9560-bf6c-de11-be94-00142212c4b1
2020-11-02 11:17:26 +00:00
George Peter Banyard
cdaea04215 Remove mention of PHP 5 in Language Reference section
This does not cover the OOP nor Error sections, but everything else should be covered

Closes GH-156

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@351112 c90b9560-bf6c-de11-be94-00142212c4b1
2020-10-31 19:13:58 +00:00
Christoph Michael Becker
d960106581 Document ReflectionProperty::getDefaultValue and ::hasDefaultValue
Patch provided by Benjamin Eberlei <kontakt@beberlei.de>.


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@351090 c90b9560-bf6c-de11-be94-00142212c4b1
2020-10-30 16:38:02 +00:00
Christoph Michael Becker
41445b3d77 Mark up nullable types as union types
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@351076 c90b9560-bf6c-de11-be94-00142212c4b1
2020-10-30 10:47:17 +00:00
Christoph Michael Becker
72502df5f5 ReflectionMethod accepts string|object, not mixed
Based on a patch contributed by Benjamin Morel <benjamin.morel@gmail.com>.


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@351060 c90b9560-bf6c-de11-be94-00142212c4b1
2020-10-29 17:14:02 +00:00
Christoph Michael Becker
7f569e1f17 Remove more changelog entries, mostly from PHP 5.3 era
Patch contributed by Sobak <msobaczewski@gmail.com>.


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@350655 c90b9560-bf6c-de11-be94-00142212c4b1
2020-09-26 14:08:59 +00:00
Christoph Michael Becker
3fc4586f54 Add missing changelog entry for deprecated ReflectionType::__toString()
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@350642 c90b9560-bf6c-de11-be94-00142212c4b1
2020-09-26 11:35:22 +00:00
Christoph Michael Becker
ecd72af657 Reflection can now get defaults for internals, see https://github.com/php/php-src/pull/5353
Patch contributed by Sjon Hortensius.


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@350519 c90b9560-bf6c-de11-be94-00142212c4b1
2020-09-05 09:49:21 +00:00
Christoph Michael Becker
a465b89916 Reflection*::export is deprecated as of PHP 7.4.0
Seems we're overdue actually documenting these methods.

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@350501 c90b9560-bf6c-de11-be94-00142212c4b1
2020-09-03 08:59:26 +00:00
Christoph Michael Becker
3a3b3279ef Fix #79593: Manual page missing for class ReflectionReference
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@349867 c90b9560-bf6c-de11-be94-00142212c4b1
2020-05-13 19:41:26 +00:00
Christoph Michael Becker
69dba7ad55 PHP 7 as well
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@349091 c90b9560-bf6c-de11-be94-00142212c4b1
2020-02-02 17:01:17 +00:00
George Peter Banyard
b716a57a5e Introspect is better term to use in scope of reflection: https://en.wikipedia.org/wiki/Type_introspection
-- 
Provided by anonymous 101415 (dario_swain@yahoo.com)

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@349021 c90b9560-bf6c-de11-be94-00142212c4b1
2020-01-26 10:22:32 +00:00
Christoph Michael Becker
0ce6b8da1e Document ReflectionParameter::__construct()
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@348589 c90b9560-bf6c-de11-be94-00142212c4b1
2019-12-19 17:03:47 +00:00
Christoph Michael Becker
c4c885db2f Fix #78936: Reflection methods for typed properties not documented
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@348478 c90b9560-bf6c-de11-be94-00142212c4b1
2019-12-09 15:22:24 +00:00
Christoph Michael Becker
6890875704 The signature of ReflectionMethod::getClosure() depends on its usage
As already pointed out in the description of the $object parameter.
See also bug #78897.


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@348397 c90b9560-bf6c-de11-be94-00142212c4b1
2019-12-02 12:20:37 +00:00
George Peter Banyard
83f9fa789a Fix method name, provided by anonymous user.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347954 c90b9560-bf6c-de11-be94-00142212c4b1
2019-09-07 12:29:38 +00:00
Pieter Hordijk
c55e85a130 var_export's second param is a bool not an int
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347166 c90b9560-bf6c-de11-be94-00142212c4b1
2019-04-08 06:23:00 +00:00
Christoph Michael Becker
bab9e5ad7f Fix parameter type and description
Patch provided by Jochem Klaver.

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@346993 c90b9560-bf6c-de11-be94-00142212c4b1
2019-03-11 12:47:04 +00:00
Christoph Michael Becker
f9e14201d4 Improve docs
Patch provided by Florian Berberich.

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@346901 c90b9560-bf6c-de11-be94-00142212c4b1
2019-02-25 11:37:39 +00:00
Christoph Michael Becker
1046d428ad Unify ReflectionClass::isIterateable() and ::isIterable() and make the former an alias
Cf. <http://git.php.net/?p=php-src.git;a=commit;h=c1500f8519aded29c3632de4240fbc0a4e485a81>.

This integrates user note 123629.

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@346865 c90b9560-bf6c-de11-be94-00142212c4b1
2019-02-21 08:37:26 +00:00
Christoph Michael Becker
4fd00d6b39 Add example for PHP 7.1+
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@346839 c90b9560-bf6c-de11-be94-00142212c4b1
2019-02-15 11:43:02 +00:00
Christoph Michael Becker
05c356b812 Reverse merged revision(s) 346836-346835 from phpdoc/en/trunk:
Add missing changelog entry
........
Correct return-types

Patch provided by Rasmus Schultz.
........
Cf. <http://news.php.net/php.doc.cvs/16556>.

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@346838 c90b9560-bf6c-de11-be94-00142212c4b1
2019-02-15 09:01:33 +00:00
Christoph Michael Becker
663be7df7f Add missing changelog entry
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@346836 c90b9560-bf6c-de11-be94-00142212c4b1
2019-02-14 22:40:46 +00:00
Christoph Michael Becker
828daf218f Correct return-types
Patch provided by Rasmus Schultz.

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@346835 c90b9560-bf6c-de11-be94-00142212c4b1
2019-02-14 22:21:41 +00:00
Christoph Michael Becker
e309892680 Add version info for ReflectionNamedType
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@346834 c90b9560-bf6c-de11-be94-00142212c4b1
2019-02-14 22:01:36 +00:00
Christoph Michael Becker
481248b3a1 Fix typo
Patch provided by girgias.

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@346813 c90b9560-bf6c-de11-be94-00142212c4b1
2019-02-12 16:33:07 +00:00
Christoph Michael Becker
962214a5cc Simplify signature of variadic functions
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@346102 c90b9560-bf6c-de11-be94-00142212c4b1
2018-11-27 19:09:14 +00:00
Christoph Michael Becker
c5971e972a Fix #76949: ReflectionType::__toString() not marked as deprecated
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345735 c90b9560-bf6c-de11-be94-00142212c4b1
2018-09-29 21:28:39 +00:00
Christoph Michael Becker
437bbf134e Show inherited constants
We do this for the classes of the core and bundled extensions only, for now.
This also allows us to remove some slightly incorrect and unnecessary copy
and paste documentation, where inherited constants have been explicitly
documented for child classes.

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345662 c90b9560-bf6c-de11-be94-00142212c4b1
2018-09-20 15:10:00 +00:00
Christoph Michael Becker
1c1b29f597 Fix #65011: ReflectionProperty::getDocComment() fails for multiple variable declarations
We add an example to clarify the behavior.

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345251 c90b9560-bf6c-de11-be94-00142212c4b1
2018-06-30 12:42:20 +00:00