pub enum RelationalAtom {
Name(TaskName),
Project(ProjectName),
Tag(TagName),
}Expand description
A typed relational atom per QRY-004.
Each variant carries the validated identifier that the atom’s
predicate compares against. The relational filter flag
(--child-of etc.) decides whether the relation walked is
direct or transitive.
Variants§
Name(TaskName)
name:<TaskName>: the target task’s name equals the
given identifier.
Project(ProjectName)
project:<ProjectName>: the target task’s owning project
name equals the given identifier.
Tag(TagName)
tag:<TagName>: the target task’s owning project carries
the given tag.
Implementations§
Source§impl RelationalAtom
impl RelationalAtom
Sourcepub fn matches(
&self,
project_name: &ProjectName,
task_name: &TaskName,
project_tags: &BTreeSet<TagName>,
) -> bool
pub fn matches( &self, project_name: &ProjectName, task_name: &TaskName, project_tags: &BTreeSet<TagName>, ) -> bool
Evaluate this atom against a candidate target task per
QRY-004.
task_name is the task’s own name; project_name is the
task’s owning project; project_tags is the project’s
tags: set. Returns true iff the atom’s predicate
matches the task.
Trait Implementations§
Source§impl Clone for RelationalAtom
impl Clone for RelationalAtom
Source§fn clone(&self) -> RelationalAtom
fn clone(&self) -> RelationalAtom
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RelationalAtom
impl Debug for RelationalAtom
Source§impl Hash for RelationalAtom
impl Hash for RelationalAtom
Source§impl PartialEq for RelationalAtom
impl PartialEq for RelationalAtom
Source§fn eq(&self, other: &RelationalAtom) -> bool
fn eq(&self, other: &RelationalAtom) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for RelationalAtom
impl StructuralPartialEq for RelationalAtom
Auto Trait Implementations§
impl Freeze for RelationalAtom
impl RefUnwindSafe for RelationalAtom
impl Send for RelationalAtom
impl Sync for RelationalAtom
impl Unpin for RelationalAtom
impl UnsafeUnpin for RelationalAtom
impl UnwindSafe for RelationalAtom
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