Coverage for src / lexigram / contracts / data / graph / enums.py: 0%

27 statements  

« prev     ^ index     » next       coverage.py v7.13.5, created at 2026-08-15 18:57 +0800

1"""Graph store enumerations.""" 

2 

3from __future__ import annotations 

4 

5from enum import StrEnum 

6 

7 

8class EdgeDirection(StrEnum): 

9 """Direction for edge traversal.""" 

10 

11 OUTGOING = "outgoing" 

12 INCOMING = "incoming" 

13 BOTH = "both" 

14 

15 

16class ReturnType(StrEnum): 

17 """What a traversal query returns.""" 

18 

19 NODES = "nodes" 

20 EDGES = "edges" 

21 PATHS = "paths" 

22 COUNT = "count" 

23 

24 

25class IndexKind(StrEnum): 

26 """Type of graph index.""" 

27 

28 BTREE = "btree" 

29 FULLTEXT = "fulltext" 

30 RANGE = "range" 

31 POINT = "point" 

32 TEXT = "text" 

33 VECTOR = "vector" 

34 

35 

36class ConstraintKind(StrEnum): 

37 """Type of graph schema constraint.""" 

38 

39 UNIQUE = "unique" 

40 EXISTS = "exists" 

41 NODE_KEY = "node_key" 

42 

43 

44class MergeAction(StrEnum): 

45 """Behavior when a merge finds an existing node/edge.""" 

46 

47 CREATE = "create" 

48 MATCH = "match" 

49 MERGE = "merge" 

50 

51 

52__all__ = [ 

53 "ConstraintKind", 

54 "EdgeDirection", 

55 "IndexKind", 

56 "MergeAction", 

57 "ReturnType", 

58]