Enum paralegal_spdg::traverse::EdgeSelection
source · pub enum EdgeSelection {
Data,
Control,
Both,
}
Expand description
Which type of edges should be considered for a given traversal
Variants§
Data
Consider only edges with crate::EdgeKind::Data
Control
Consider only edges with crate::EdgeKind::Control
Both
Consider both data and control flow edges in any combination
Implementations§
source§impl EdgeSelection
impl EdgeSelection
sourcepub const fn is_data(&self) -> bool
pub const fn is_data(&self) -> bool
Returns true if the enum is EdgeSelection::Data otherwise false
sourcepub const fn is_control(&self) -> bool
pub const fn is_control(&self) -> bool
Returns true if the enum is EdgeSelection::Control otherwise false
source§impl EdgeSelection
impl EdgeSelection
sourcepub fn use_control(self) -> bool
pub fn use_control(self) -> bool
Does this selection admit edges of type crate::EdgeKind::Control
sourcepub fn use_data(self) -> bool
pub fn use_data(self) -> bool
Does this selection admit edges of type crate::EdgeKind::Data
sourcepub fn filter_graph<G: IntoEdgeReferences + Data<EdgeWeight = EdgeInfo>>(
self,
g: G
) -> EdgeFiltered<G, fn(_: G::EdgeRef) -> bool>
pub fn filter_graph<G: IntoEdgeReferences + Data<EdgeWeight = EdgeInfo>>( self, g: G ) -> EdgeFiltered<G, fn(_: G::EdgeRef) -> bool>
Create a graph adaptor that implements this edge selection.
Trait Implementations§
source§impl Clone for EdgeSelection
impl Clone for EdgeSelection
source§fn clone(&self) -> EdgeSelection
fn clone(&self) -> EdgeSelection
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl PartialEq<EdgeSelection> for EdgeSelection
impl PartialEq<EdgeSelection> for EdgeSelection
source§fn eq(&self, other: &EdgeSelection) -> bool
fn eq(&self, other: &EdgeSelection) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Copy for EdgeSelection
impl Eq for EdgeSelection
impl StructuralEq for EdgeSelection
impl StructuralPartialEq for EdgeSelection
Auto Trait Implementations§
impl RefUnwindSafe for EdgeSelection
impl Send for EdgeSelection
impl Sync for EdgeSelection
impl Unpin for EdgeSelection
impl UnwindSafe for EdgeSelection
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
source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.