Now solving issues with faulty imports. Still nothing functional.

This commit is contained in:
Griatch 2014-12-20 17:03:34 +01:00
parent 08d0442f9c
commit 8314d8ba5e
8 changed files with 77 additions and 37 deletions

View file

@ -14,7 +14,19 @@ class Channel(ChannelDB):
This is the base class for all Comms. Inherit from this to create different
types of communication channels.
"""
__metaclass__ = TypeclassBase
def __new__(cls, *args, **kwargs):
"""
We must define our Typeclasses as proxies. We also store the path
directly on the class, this is useful for managers.
"""
if hasattr(cls, "Meta"):
cls.Meta.proxy = True
else:
class Meta:
proxy = True
cls.Meta = Meta
return super(TypeclassBase, cls).__new__(*args, **kwargs)
# helper methods, for easy overloading