Struct issue_states::resolution::IssueStateSet
source · pub struct IssueStateSet<C>where
C: Condition,{ /* private fields */ }
Expand description
Set of issue states
This set of issue states is intended for the efficient computation of an issue’s state.
Implementations§
source§impl<C> IssueStateSet<C>where
C: Condition,
impl<C> IssueStateSet<C>where
C: Condition,
sourcepub fn from_set(states: BTreeSet<Arc<IssueState<C>>>) -> Result<Self>
pub fn from_set(states: BTreeSet<Arc<IssueState<C>>>) -> Result<Self>
Create an issue state set from a orderd set of issue states
Note:
The set provided must be the (transitive) closure of all its elements regarding its relations to other sets: if a state is in the set, all states related to it must also be in the set. No explicit checking is performed to assert this property.
sourcepub fn iter(&self) -> Iter<'_, Arc<IssueState<C>>>
pub fn iter(&self) -> Iter<'_, Arc<IssueState<C>>>
Get an iterator for iterating over the issue states within the set
This iterator will yield an issue state only after all its dependencies.
Trait Implementations§
source§impl<C> Default for IssueStateSet<C>where
C: Condition,
impl<C> Default for IssueStateSet<C>where
C: Condition,
source§impl<C> From<Vec<Arc<IssueState<C>>, Global>> for IssueStateSet<C>where
C: Condition,
impl<C> From<Vec<Arc<IssueState<C>>, Global>> for IssueStateSet<C>where
C: Condition,
Create an issue state set directly from a vector
Warning
Within the vector, the states must appear ordered by dependency: all dependencies of a state must appear before the state itself!
source§impl<C> Resolvable<C> for IssueStateSet<C>where
C: Condition,
impl<C> Resolvable<C> for IssueStateSet<C>where
C: Condition,
source§fn issue_state(&self, issue: &C::Issue) -> Result<Option<Arc<IssueState<C>>>>
fn issue_state(&self, issue: &C::Issue) -> Result<Option<Arc<IssueState<C>>>>
Resolve the state for a given issue Read more