Bug #25694
Multiple annotations with the same name are not supported by the reflection service
Status: | Closed | Start date: | 2011-04-01 | |
---|---|---|---|---|
Priority: | Should have | Due date: | ||
Assigned To: | - | % Done: | 0% |
|
Category: | Reflection | |||
Target version: | TYPO3 Flow Base Distribution - 1.0.0 | |||
PHP Version: | Complexity: | |||
Has patch: | Affected Flow version: |
Description
As the returned $tags array is indexed by the annotation name, e.g. two @validate annotations will override eachother.
History
#1 Updated by Karsten Dambekalns over 4 years ago
Did you see my comment at https://review.typo3.org/#patch,sidebyside,1300,2,Classes/Object/Proxy/ProxyMethod.php for buildMethodDocumentation()
?
Previously one tag per value would be generated, now one tag that combines the values.
#2 Updated by Andreas Förthner over 4 years ago
Yes, but the values array contains the values of one tag, e.g. @validate abc def ghi means that $values = array('abc', 'def', 'ghi');
Having multiple @validate annotations doesn't work in either case. To make this possible the ReflectionService API has to be changed...
#3 Updated by Christopher Hlubek about 4 years ago
I think the problem with the ProxyMethod was solved (generates multiple annotations again).
The methods for tags in the ReflectionService (e.g. getMethodTagsValues
) return an array of tags with values as array. So multiple annotations are returned inside the value array. This is also tested in the ReflectionServiceTest
with getMethodTagsValuesReturnsArrayOfTagsAndValuesOfAMethod
.
Maybe it's the ValidatorResolver
that cannot handle multiple tags?
#4 Updated by Sebastian Kurfuerst almost 5 years ago
- Target version changed from 1.0 beta 1 to 1.0 beta 2
we won't manage this for beta1 anymore, postproning
#5 Updated by Robert Lemke almost 4 years ago
- Status changed from New to Needs Feedback
- Priority changed from Must have to Should have
As far as I understand it, the ReflectionService works correctly.
Without some steps to reproduce this problem, I'd like to close this issue.
#6 Updated by Robert Lemke almost 4 years ago
- Target version changed from 1.0 beta 2 to 1.0.0
#7 Updated by Robert Lemke almost 4 years ago
- Status changed from Needs Feedback to Closed
Can't reproduce.