File tree Expand file tree Collapse file tree 1 file changed +17
-11
lines changed Expand file tree Collapse file tree 1 file changed +17
-11
lines changed Original file line number Diff line number Diff line change @@ -66,10 +66,17 @@ class NonExistentCDOConceptWarning(UserWarning):
66
66
67
67
68
68
class ValidationResult :
69
- conforms : bool
70
- graph : Any
71
- text : str
72
- undefined_concepts : Set [rdflib .URIRef ]
69
+ def __init__ (
70
+ self ,
71
+ conforms : bool ,
72
+ graph : Any ,
73
+ text : str ,
74
+ undefined_concepts : Set [rdflib .URIRef ],
75
+ ):
76
+ self .conforms = conforms
77
+ self .graph = graph
78
+ self .text = text
79
+ self .undefined_concepts = undefined_concepts
73
80
74
81
75
82
def concept_is_cdo_concept (n_concept : rdflib .URIRef ) -> bool :
@@ -229,13 +236,12 @@ def validate(
229
236
# Relieve RAM of the data graph after validation has run.
230
237
del data_graph
231
238
232
- result = ValidationResult ()
233
- result .conforms = validate_result [0 ]
234
- result .graph = validate_result [1 ]
235
- result .text = validate_result [2 ]
236
- result .undefined_concepts = undefined_cdo_concepts
237
-
238
- return result
239
+ return ValidationResult (
240
+ validate_result [0 ],
241
+ validate_result [1 ],
242
+ validate_result [2 ],
243
+ undefined_cdo_concepts ,
244
+ )
239
245
240
246
241
247
def main () -> None :
You can’t perform that action at this time.
0 commit comments