summaryrefslogtreecommitdiff
path: root/lib/git_python/method_missing.py
diff options
context:
space:
mode:
Diffstat (limited to 'lib/git_python/method_missing.py')
-rw-r--r--lib/git_python/method_missing.py21
1 files changed, 0 insertions, 21 deletions
diff --git a/lib/git_python/method_missing.py b/lib/git_python/method_missing.py
deleted file mode 100644
index 478ee1d3..00000000
--- a/lib/git_python/method_missing.py
+++ /dev/null
@@ -1,21 +0,0 @@
-class MethodMissingMixin(object):
- """
- A Mixin' to implement the 'method_missing' Ruby-like protocol.
-
- This was `taken from a blog post <http://blog.iffy.us/?p=43>`_
- """
- def __getattribute__(self, attr):
- try:
- return object.__getattribute__(self, attr)
- except:
- class MethodMissing(object):
- def __init__(self, wrapped, method):
- self.__wrapped__ = wrapped
- self.__method__ = method
- def __call__(self, *args, **kwargs):
- return self.__wrapped__.method_missing(self.__method__, *args, **kwargs)
- return MethodMissing(self, attr)
-
- def method_missing(self, *args, **kwargs):
- """ This method should be overridden in the derived class. """
- raise NotImplementedError(str(self.__wrapped__) + " 'method_missing' method has not been implemented.")