DOM-Model:Overriding @Convert/attribute type with incompatible return types

In DomElement method getMyParameter() should be annotated either with

GenericAttributeValue 2) @Convert(MyConverter.class) GenericAttributeValue depending on another attribute value. The only solution I found would be to use GenericAttributeValue (w/o @Convert) and write a ResolveConverter and do all the stuff there, returning String or PsiMethod. I'd rather want to use TypeChooser and return corresponding implementation class (1) or 2)) with correct annotation and return type, but then I have to mark getMyParameter() with GenericAttributeValue]]>. All my tries ended with StackOverflowExceptions.

Does anyone have another proposal? Is it possible at all?


PS: Ofcourse I could use a plain old PsiReferenceProvider :(

Please sign in to leave a comment.