MethodTag::getArguments
This function return an array of array, there is no defined order of this structure.
I guess it could be useful to add a correct interpretation of this information : [[type] [parameter]<, ...>]
There is 3 informations :
- name
- type
- default value
Could return instances of FunctionReflector\ArgumentReflector just like a normal method.
It would be awesome if we could access the various information of a tag! Any implementation available?
It looks to me like nearly everything this library provides is string-based, rather than reflectors... @jaapio @mvriel , does that sound right to you? If so, then we probably don't want to bend things into the latter, unless we went whole hog and made everything return reflectors.
Thoughts, anyone?
The mentioned reflection classes are part of phpdocumentor/reflection. I can imagine that we could create a param like class to support typed arguments. But before going that way I want to have a good benchmark setup avaliable. So we can measure the impact of changes like this.
I'm sure that we will get the same request for callables. And other complex docblock tags. Main concern is the memory usage in applications like phpdocumentor.
Right, but Reflection depends on ReflectionDocBlock, not the other way around. If the whole paradigm in ReflectionDocBlock is "return strings for all the info you ask for", I'd say it should stay that way in this library. Maybe the Reflection library itself could be the level of providing higher level classes wrapped around these strings.
I started an effort to get this thing done #304