Hi guys,
Is it proper with Qi4j to have a @Uses annotation in a Service mixin, and if yes, how can one inject the object into the mixin instance at runtime?
More specifically, here's an example sketch:
@Mixins{AbcService.Mixin.class}
interface AbcService implements Abc, ServiceComposite {
...
class Mixin implements Abc {
@Uses
SomeInterface obj;
...
}
}
Then:
ServiceReference<AbcService> serviceRef = module.findService(AbsService.class);
AbcService abcService = serviceRef.get();
At this point, how can I inject a SomeInterface object into the abcService instance?
TransientBuilder.use() is not applicable to this case, or is it in some way?
Best regards,
Michael