Skip to main content

PathSet

Struct PathSet 

Source
pub struct PathSet {
    pub reads: BTreeSet<String>,
    pub listings: BTreeSet<String>,
    pub present: BTreeSet<String>,
    pub absent: BTreeSet<String>,
    pub written: BTreeSet<String>,
}

Fields§

§reads: BTreeSet<String>

Files whose content the task read.

§listings: BTreeSet<String>

Directories it listed; . is the workspace root.

§present: BTreeSet<String>

Paths it found, without reading them. A file among them is keyed by its content all the same: a tool that compares timestamps, as tsc --build does, decides by a file it never reads.

§absent: BTreeSet<String>

Paths it looked for and did not find.

§written: BTreeSet<String>

Paths it wrote in the directories it listed, left out of their listings: they are there after it runs, and need not be before.

Implementations§

Source§

impl PathSet

Source

pub fn from_accesses( accesses: &[Access], exclusions: &Exclusions<'_>, root: &Path, ) -> Self

The path set of a task’s recorded accesses, in the order it made them. root is the workspace root, to tell a directory opened for listing from a file opened for reading.

Source

pub fn is_relative(&self) -> bool

Whether every path it names lies within the workspace: relative, and never through ...

Source

pub fn is_empty(&self) -> bool

Source

pub fn changed_since( &self, root: &Path, started: SystemTime, outputs: &[&Outputs], ) -> Option<&str>

A path the set keys that changed after started, when the task ran: keyed by how it is now, a recording would key the task by what was left there rather than by what the task saw.

A file read or found changed if it was written. A listing, which keys its entries’ names and kinds, changed if an entry was added, removed or renamed, which moves the directory’s own modification time; what is written inside an entry does not change it, though it moves the entry’s change time. Where the task wrote into the directory, its time moves with the task’s own writes, so there an entry other than the task’s writes and outputs changed it: a file whose change time moved, by being added, moved in or rewritten, or a subdirectory created after started, by its birth time, which a file system without one cannot tell. A removal there, or a subdirectory moved in, cannot be told from the task’s own writes.

Source

pub fn digest(&self) -> Result<String>

Trait Implementations§

Source§

impl Clone for PathSet

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for PathSet

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for PathSet

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl<'de> Deserialize<'de> for PathSet

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Eq for PathSet

Source§

impl PartialEq for PathSet

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl Serialize for PathSet

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for PathSet

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.