chore: Un-deprecate IControllerMethodReflector as it’s now useful for attributes as well

It should be extended later to add methods to get attributes from
 reflection, and maybe a getter to the reflectionMethod object to avoid
 middlewares building their own.

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
This commit is contained in:
Côme Chilliet 2026-03-11 14:43:50 +01:00 committed by Louis Chmn
parent a5e79add44
commit 841a3c4045

View file

@ -11,22 +11,13 @@ namespace OCP\AppFramework\Utility;
/**
* Interface ControllerMethodReflector
*
* Reads and parses annotations from doc comments
* You can inject this interface in your Middleware, and it will be prefilled with information related to the called controller method
*
* Reads and parses annotations from doc comments (deprecated) and PHP attributes
*
* @since 8.0.0
* @deprecated 22.0.0 will be obsolete with native attributes in PHP8
* @see https://help.nextcloud.com/t/how-should-we-use-php8-attributes/104278
*/
interface IControllerMethodReflector {
/**
* @param object $object an object or classname
* @param string $method the method which we want to inspect
* @return void
* @since 8.0.0
* @deprecated 17.0.0 Reflect should not be called multiple times and only be used internally. This will be removed in Nextcloud 18
*/
public function reflect($object, string $method);
/**
* Inspects the PHPDoc parameters for types
*