[PATCH 10 of 10 seda] [entities] Mark DirectLinkIContained adapter as abstract explicitly

Sylvain Thenault sylvain.thenault at logilab.fr
Tue Mar 7 15:25:47 CET 2017


# HG changeset patch
# User Sylvain Thénault <sylvain.thenault at logilab.fr>
# Date 1488552326 -3600
#      Fri Mar 03 15:45:26 2017 +0100
# Node ID 21e5b20728f01330bce1cf6da5a6f6030eac36cd
# Parent  b45b59bc5550d54a3a14d9020f8e3c108e72ce78
[entities] Mark DirectLinkIContained adapter as abstract explicitly

concret subclasses are built in registration_callback.

diff --git a/cubicweb_seda/entities/__init__.py b/cubicweb_seda/entities/__init__.py
--- a/cubicweb_seda/entities/__init__.py
+++ b/cubicweb_seda/entities/__init__.py
@@ -141,10 +141,12 @@ def rule_type_from_etype(etype):
 
 class DirectLinkIContained(IContained):
     """IContained implementation using a relation that link every contained entities to its parent
     container.
     """
+    __abstract__ = True
+
     @property
     def container(self):
         """Return the container to which this entity belongs, or None."""
         container = self.entity.related('container', entities=True)
         return container and container[0] or None


More information about the saem-devel mailing list