web/contentment/taxonomy.py
def contains(self, other):
		"""The asset, specified by the parameter, is a descendant of any of the selected assets."""

		if __debug__:  # Can be optimized away (-O) in production.
			from web.component.asset import Asset
			assert isinstance(other, Asset) or isinstance(other, ObjectId), "Argument must be Asset or ObjectId instance."

		parents = self.clone().scalar('id').no_dereference()
		return bool(self.base_query(pk=getattr(other, 'pk', other), parents__in=parents).count())
The asset, specified by the parameter, is a descendant of any of the selected assets.
The asset, specified by the parameter, is a descendant of any of the selected assets.
The asset specified by the parameter is a descendant of any of the selected assets .
def contains(self, other):
		if __debug__:  
			from web.component.asset import Asset
			assert isinstance(other, Asset) or isinstance(other, ObjectId), "Argument must be Asset or ObjectId instance."
		parents = self.clone().scalar('id').no_dereference()
		return bool(self.base_query(pk=getattr(other, 'pk', other), parents__in=parents).count())
def contains ( self , other ) : if __debug__ : from web . component . asset import Asset assert isinstance ( other , Asset ) or isinstance ( other , ObjectId ) , "Argument must be Asset or ObjectId instance." parents = self . clone ( ) . scalar ( 'id' ) . no_dereference ( ) return bool ( self . base_query ( pk = getattr ( other , 'pk' , other ) , parents__in = parents ) . count ( ) )
The asset, specified by the parameter, is a descendant of any of the selected assets.
The asset specified by the parameter is a descendant of any of the selected assets .
"""The asset, specified by the parameter, is a descendant of any of the selected assets.""" # Can be optimized away (-O) in production.
self
other