Convert from abstractproperty which was deprecated in python-3.3.

This commit is contained in:
Mike Auty
2017-06-20 15:14:13 +01:00
parent d0ebeab253
commit df527d2f00
2 changed files with 12 additions and 7 deletions
+7 -4
View File
@@ -5,7 +5,7 @@ of symbols that can be used to interpret data in a layer. The context also prov
notably the object constructor function, `object`, which will construct a symbol on a layer at a particular offset.
"""
import copy
from abc import ABCMeta, abstractmethod, abstractproperty
from abc import ABCMeta, abstractmethod
from volatility.framework import validity
@@ -21,11 +21,13 @@ class ContextInterface(object, metaclass = ABCMeta):
# ## Symbol Space Functions
@abstractproperty
@property
@abstractmethod
def config(self):
"""Returns the configuration object for this context"""
@abstractproperty
@property
@abstractmethod
def symbol_space(self):
"""Returns the symbol_space for the context
@@ -34,7 +36,8 @@ class ContextInterface(object, metaclass = ABCMeta):
# ## Memory Functions
@abstractproperty
@property
@abstractmethod
def memory(self):
"""Returns the memory object for the context"""
raise NotImplementedError("Memory has not been implemented.")
+5 -3
View File
@@ -6,7 +6,7 @@ import functools
import logging
import math
import multiprocessing
from abc import ABCMeta, abstractmethod, abstractproperty
from abc import ABCMeta, abstractmethod
from volatility.framework import constants, exceptions, validity
from volatility.framework.interfaces import configuration, context
@@ -109,11 +109,13 @@ class DataLayerInterface(configuration.ConfigurableInterface, validity.ValidityR
"""Returns the layer name"""
return self._name
@abstractproperty
@property
@abstractmethod
def maximum_address(self):
"""Returns the maximum valid address of the space"""
@abstractproperty
@property
@abstractmethod
def minimum_address(self):
"""Returns the minimum valid address of the space"""