Coverage for lode / models / attribute.py: 100%

6 statements  

« prev     ^ index     » next       coverage.py v7.13.0, created at 2026-11-22 15:54 +0000

1"""Attribute: an owl:DatatypeProperty.""" 

2from .property import Property 

3 

4class Attribute(Property): 

5 """A datatype property: it relates a resource to literals.""" 

6 

7 def __init__(self, **kwargs): 

8 """Create an attribute with empty has_range and has_type.""" 

9 super().__init__(**kwargs) 

10 

11 # Relation with Literal 

12 self.has_range = [] # Already defined in the parent class, card 1..* 

13 self.has_type = [] # [1..*]