mirror of
https://github.com/volatilityfoundation/volatility3.git
synced 2026-09-11 12:17:38 +02:00
Rework config system yet again, and start filling in some of the requirements.
This commit is contained in:
@@ -17,6 +17,10 @@ class ContextInterface(object, metaclass = ABCMeta):
|
||||
|
||||
# ## Symbol Space Functions
|
||||
|
||||
@abstractproperty
|
||||
def config(self):
|
||||
"""Returns the configuration object for this context"""
|
||||
|
||||
@abstractproperty
|
||||
def symbol_space(self):
|
||||
"""Returns the symbol_space for the context"""
|
||||
@@ -46,6 +50,12 @@ class ContextInterface(object, metaclass = ABCMeta):
|
||||
|
||||
|
||||
class ContextModifierInterface(object, metaclass = ABCMeta):
|
||||
def __init__(self, namespace):
|
||||
self.namespace = namespace
|
||||
|
||||
def config_get(self, context):
|
||||
return context.config[self.namespace]
|
||||
|
||||
@classmethod
|
||||
@abstractmethod
|
||||
def requirements(cls):
|
||||
|
||||
Reference in New Issue
Block a user