oldman.client.model package¶
Submodules¶
oldman.client.model.manager module¶
-
class
oldman.client.model.manager.
ClientModelManager
(oper_extractor, declare_default_operation_functions=True, **kwargs)[source]¶ Bases:
oldman.core.model.manager.ModelManager
Client ModelManager.
In charge of the conversion between and store and client models.
oldman.client.model.model module¶
-
class
oldman.client.model.model.
ClientModel
(name, class_iri, ancestry_iris, context, om_attributes, operations=None, local_context=None, accept_new_blank_nodes=False)[source]¶ Bases:
oldman.core.model.model.Model
TODO: describe.
TODO: further study this specific case.
Contains methods for end-users (–> layer above the user mediator).
-
all
(session, limit=None, eager=False)[source]¶ Finds every
Resource
object that is instance of its RDFS class.Parameters: - limit – Upper bound on the number of solutions returned (SPARQL LIMIT). Positive integer. Defaults to None.
- eager – If True loads all the Resource objects within one single SPARQL query. Defaults to False (lazy).
Returns: A generator of
Resource
objects.
-
filter
(session, hashless_iri=None, limit=None, eager=True, pre_cache_properties=None, **kwargs)[source]¶ Finds the
Resource
objects matching the given criteria.The class_iri attribute is added to the types.
See
oldman.resource.finder.ResourceFinder.filter()
for further details.
-
first
(session, hashless_iri=None, eager_with_reversed_attributes=True, pre_cache_properties=None, **kwargs)[source]¶ Finds the
Resource
objects matching the given criteria.The class_iri attribute is added to the types.
See
oldman.resource.finder.ResourceFinder.filter()
for further details.
-
get
(session, iri, eager_with_reversed_attributes=None)[source]¶ Gets the first
Resource
object matching the given criteria.The class_iri attribute is added to the types. Also looks if reversed attributes should be considered eagerly.
See
oldman.store.datastore.DataStore.get()
for further details.
-
methods
¶ dict of Python functions that takes as first argument a
Resource
object. Keys are the method names.
-
oldman.client.model.operation module¶
TODO: explain