pub enum EdgeKind {
SameIdentity,
WorksAt,
MemberOf,
EmployedBy,
SubjectOf,
}Expand description
The closed v1 cross-service edge-kind registry
(cross-service-linking.md §9). Each kind fixes its endpoint types,
direction, temporality, inverse label, and sensitivity.
Variants§
SameIdentity
person ↔ worker — the same human across the two registries
(symmetric; the federation backbone powering single-view).
WorksAt
person → organization — a person works at an organization.
MemberOf
person → organization — a person is a member of an organization.
EmployedBy
worker → organization — a worker is employed by an organization
(carries a role).
SubjectOf
case → person — a case is about / has as its subject a person
(high sensitivity — §10).
Implementations§
Source§impl EdgeKind
impl EdgeKind
Sourcepub fn from_token(token: &str) -> Option<Self>
pub fn from_token(token: &str) -> Option<Self>
Parse a wire token into an EdgeKind, or None if unknown.
Sourcepub const fn is_symmetric(self) -> bool
pub const fn is_symmetric(self) -> bool
true for a symmetric kind (same_identity): direction is
irrelevant and the aggregator canonicalises the pair.
Sourcepub const fn is_temporal(self) -> bool
pub const fn is_temporal(self) -> bool
true if the edge is time-bounded (valid_from/valid_to
meaningful — affiliations). subject_of is “sometimes”; modelled
here as time-bounded-capable.
Sourcepub const fn inverse(self) -> Option<&'static str>
pub const fn inverse(self) -> Option<&'static str>
The inverse-direction label the aggregator stores for the far
endpoint, or None for a symmetric kind (its own inverse).
Sourcepub const fn sensitivity(self) -> Sensitivity
pub const fn sensitivity(self) -> Sensitivity
This kind’s sensitivity tier.
Sourcepub fn permits(self, from: EntityType, to: EntityType) -> bool
pub fn permits(self, from: EntityType, to: EntityType) -> bool
Validate that from/to are the endpoint types this kind permits
(§9). For the symmetric same_identity, either ordering of
{person, worker} is accepted.