Skip to content

Commit

Permalink
refactor(parser): type alias to graph module
Browse files Browse the repository at this point in the history
  • Loading branch information
cmdoret committed Nov 3, 2023
1 parent 8f1ce60 commit e90fd18
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
5 changes: 5 additions & 0 deletions gimie/graph/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
from typing import Tuple, TypeAlias, Union

from rdflib.term import Literal, URIRef

Property: TypeAlias = Tuple[URIRef, Union[URIRef, Literal]]
4 changes: 1 addition & 3 deletions gimie/parsers/abstract.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,7 @@
from functools import reduce
from typing import Iterable, Set, Tuple, TypeAlias, Union

from rdflib.term import Literal, URIRef

Property: TypeAlias = Tuple[URIRef, Union[URIRef, Literal]]
from gimie.graph import Property


class Parser(ABC):
Expand Down

0 comments on commit e90fd18

Please sign in to comment.