Hey again,
alright, I think I came to a quite elegant solution, and quite straightforward too I think. To configure properties and method invocations on classes where you do not have access to the source code (so you can't add the metadata directly into the source).
You could do something like this:
Code:
[Configuration]
public class configClass {
[Property(name="autowireOnce",value="false")]
[Property(name="objectDefinitionResolver",ref="myObjectDefinitionResolver")]
[Component(scope="singleton")]
public var autowireStageProcessor: DefaultAutowiringStageProcessor;
[Component(scope="singleton",lazyInit="true")]
public var eventHandlerProcessor:EventHandlerMetadataProcessor;
[Invoke(name="myMethod",args="stringValue")]
[Component(scope="singleton",lazyInit="true",initMethod="initResolver")]
public var myObjectDefinitionResolver:CustomObjectDefinitionResolver;
}
What do you think? I think I'll go ahead and implement it this way, unless someone has some clear objections against this?
cheers,
Roland