def update_direct_properties(self,
entity_class,
entity):
"""Update the graph by adding all direct literal properties of the entity
in the graph.
Args:
entity_class (url): URL of the entity's class
entity (rdflib.URIRef): RDFlib Entity
"""
sparql = GET_DIRECT_PROPS.format(entity_class)
for dest_prop, rule in self.rules_graph.query(sparql):
self.__handle_pattern__(
entity=entity,
rule=rule,
destination_property=dest_prop)
评论列表
文章目录