pub enum Sort {
Show 13 variants
Entity,
Physical,
Animate,
Human,
Plant,
Place,
Time,
Abstract,
Information,
Event,
Celestial,
Value,
Group,
}Expand description
Semantic sorts for type checking.
Variants§
Entity
Top of the hierarchy; any individual.
Physical
Concrete, spatially located objects.
Animate
Living beings capable of self-motion.
Human
Persons with intentional agency.
Plant
Non-animal living organisms.
Place
Locations and regions.
Time
Temporal intervals and points.
Abstract
Non-physical, conceptual entities.
Information
Propositional content and data.
Event
Occurrences and happenings.
Celestial
Stars, planets, and astronomical bodies.
Value
Numeric or monetary amounts.
Group
Collections of individuals.
Implementations§
Source§impl Sort
impl Sort
Sourcepub fn is_compatible_with(self, other: Sort) -> bool
pub fn is_compatible_with(self, other: Sort) -> bool
Check if this sort can be used where other is expected.
Sort compatibility follows a subsumption hierarchy:
- Human ⊆ Animate ⊆ Physical ⊆ Entity
- Plant ⊆ Animate ⊆ Physical ⊆ Entity
- Everything ⊆ Entity
For example, a Human noun can fill an Animate slot, but not vice versa.
Trait Implementations§
impl Copy for Sort
impl Eq for Sort
impl StructuralPartialEq for Sort
Auto Trait Implementations§
impl Freeze for Sort
impl RefUnwindSafe for Sort
impl Send for Sort
impl Sync for Sort
impl Unpin for Sort
impl UnwindSafe for Sort
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more