apis_core.collections.models#

Module Contents#

Classes#

SkosCollectionManager

SkosCollection

SKOS collections are labeled and/or ordered groups of SKOS concepts. Collections are useful where a group of concepts shares something in common, and it is convenient to group them under a common label, or where some concepts can be placed in a meaningful order.

SkosCollectionContentObject

Throughtable datamodel to connect collections to arbitrary content

API#

class apis_core.collections.models.SkosCollectionManager#

Bases: django.db.models.Manager

by_instance(instance)#
class apis_core.collections.models.SkosCollection(*args, **kwargs)#

Bases: apis_core.generic.abc.GenericModel, django.db.models.Model

SKOS collections are labeled and/or ordered groups of SKOS concepts. Collections are useful where a group of concepts shares something in common, and it is convenient to group them under a common label, or where some concepts can be placed in a meaningful order.

Miles, Alistair, and Sean Bechhofer. “SKOS simple knowledge organization system reference. W3C recommendation (2009).”

Initialization

class Meta#
ordering = ['name']#
verbose_name = '_(...)'#
verbose_name_plural = '_(...)'#
class Config#

Bases: apis_core.generic.abc.GenericModel.Config

overview_section = '_(...)'#
search_initial = False#
name = 'CharField(...)'#
label_lang = 'CharField(...)'#
creator = 'TextField(...)'#
contributor = 'TextField(...)'#
objects = 'SkosCollectionManager(...)'#
__str__()#
add(instance: object)#
remove(instance: object)#
property parent_collection#
list(content_type=None)#
contains(instance: object)#
class apis_core.collections.models.SkosCollectionContentObject(*args, **kwargs)#

Bases: apis_core.generic.abc.GenericModel, django.db.models.Model

Throughtable datamodel to connect collections to arbitrary content

Initialization

class Meta#
verbose_name = '_(...)'#
verbose_name_plural = '_(...)'#
indexes = None#
class Config#

Bases: apis_core.generic.abc.GenericModel.Config

overview_section = '_(...)'#
search_initial = False#
collection = 'ForeignKey(...)'#
content_type = 'ForeignKey(...)'#
object_id = 'PositiveIntegerField(...)'#
content_object = 'GenericForeignKey(...)'#
__str__()#