decompiler
1.0.0
|
Class for automatically registering extension points to the decompiler. More...
#include <capability.hh>
Public Member Functions | |
virtual | ~CapabilityPoint (void) |
Destructor. | |
virtual void | initialize (void)=0 |
Complete initialization of an extension point. More... | |
Static Public Member Functions | |
static void | initializeAll (void) |
Finish initialization for all extension points. More... | |
Protected Member Functions | |
CapabilityPoint (void) | |
Construct extension capability exactly once. More... | |
Static Private Member Functions | |
static vector< CapabilityPoint * > & | getList (void) |
Retrieve the list of extension point singletons. More... | |
Class for automatically registering extension points to the decompiler.
This uses the C++ static initializer feature to automatically discover and register extension point. Code for an extension should provide a class that derives from CapabilityPoint and overrides the initialize() method. Additionally there should be a singleton static instantiation of this extension class. The extensions are accumulated in a list automatically, then the decompiler engine will ensure that the initialize() method is called on each extension, allowing it to complete its integration.
|
protected |
Construct extension capability exactly once.
Constructing the object automatically registers it. For global instances, this happens during static initialization
References getList().
|
staticprivate |
Retrieve the list of extension point singletons.
Access static vector of CapabilityPoint objects that are registered during static initialization The list itself is created once on the first call to this method after all the static initializers have run
Referenced by CapabilityPoint(), and initializeAll().
|
pure virtual |
Complete initialization of an extension point.
This method is implemented by each extension so it can do specialized integration
Implemented in ArchitectureCapability, GhidraDecompCapability, and PrintLanguageCapability.
Referenced by initializeAll().
|
static |
Finish initialization for all extension points.
Give all registered capabilities a chance to initialize (after all static initialization has happened)
References getList(), and initialize().