H
Henry Townsend
Say I have a class Foo implementing interface Bar. I want Foo to be able
to learn, at runtime, the names of all other classes implementing Bar.
Is this doable? I've looked through the Class API but don't see anything
appropriate
Background: I'm trying to set up my app with a "plugin" style
architecture, thus accepting user-added classes. I'd like each subclass
to expose a "helpMessage()" method, such that a user could request help
from all subclasses (those shipped with it plus aftermarket plugins)
using code which would discover them dynamically and invoke
subclass.helpMessage() on each. It feels like this should be possible
but I haven't found the magic button yet.
Thanks,
HT
to learn, at runtime, the names of all other classes implementing Bar.
Is this doable? I've looked through the Class API but don't see anything
appropriate
Background: I'm trying to set up my app with a "plugin" style
architecture, thus accepting user-added classes. I'd like each subclass
to expose a "helpMessage()" method, such that a user could request help
from all subclasses (those shipped with it plus aftermarket plugins)
using code which would discover them dynamically and invoke
subclass.helpMessage() on each. It feels like this should be possible
but I haven't found the magic button yet.
Thanks,
HT