ontology.models.tag module¶
-
class
ontology.models.tag.
Tag
(*args, **kwargs)[source]¶ Bases:
django.db.models.base.Model
Tags can be attached to a Topic to specify which category it fits. Examples: Concept, Device, Model, Theory, …
-
name
¶ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
exception
DoesNotExist
¶ Bases:
django.core.exceptions.ObjectDoesNotExist
-
exception
MultipleObjectsReturned
¶ Bases:
django.core.exceptions.MultipleObjectsReturned
-
id
¶ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
objects
= <django.db.models.manager.Manager object>¶
-
topic_set
¶ Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.
In the example:
class Pizza(Model): toppings = ManyToManyField(Topping, related_name='pizzas')
Pizza.toppings
andTopping.pizzas
areManyToManyDescriptor
instances.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-