Struct petgraph::visit::NodeFiltered
[−]
[src]
pub struct NodeFiltered<G, F>(pub G, pub F);
A node-filtering graph adaptor.
Methods
impl<F, G> NodeFiltered<G, F> where G: GraphBase, F: Fn(G::NodeId) -> bool
[src]
fn from_fn(graph: G, filter: F) -> Self
Create an NodeFiltered
adaptor from the closure filter
.
Trait Implementations
impl<G: Copy, F: Copy> Copy for NodeFiltered<G, F>
[src]
impl<G: Clone, F: Clone> Clone for NodeFiltered<G, F>
[src]
fn clone(&self) -> NodeFiltered<G, F>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl<G: Debug, F: Debug> Debug for NodeFiltered<G, F>
[src]
impl<G, F> GraphBase for NodeFiltered<G, F> where G: GraphBase
[src]
impl<'a, G, F> IntoNeighbors for &'a NodeFiltered<G, F> where G: IntoNeighbors, F: FilterNode<G::NodeId>
[src]
type Neighbors = NodeFilteredNeighbors<'a, G::Neighbors, F>
fn neighbors(self, n: G::NodeId) -> Self::Neighbors
Return an iterator of the neighbors of node a
.
impl<'a, G, F> IntoNeighborsDirected for &'a NodeFiltered<G, F> where G: IntoNeighborsDirected, F: FilterNode<G::NodeId>
[src]
type NeighborsDirected = NodeFilteredNeighbors<'a, G::NeighborsDirected, F>
fn neighbors_directed(self, n: G::NodeId, dir: Direction) -> Self::NeighborsDirected
impl<'a, G, F> IntoNodeIdentifiers for &'a NodeFiltered<G, F> where G: IntoNodeIdentifiers, F: FilterNode<G::NodeId>
[src]
type NodeIdentifiers = NodeFilteredNeighbors<'a, G::NodeIdentifiers, F>
fn node_identifiers(self) -> Self::NodeIdentifiers
impl<'a, G, F> IntoNodeReferences for &'a NodeFiltered<G, F> where G: IntoNodeReferences, F: FilterNode<G::NodeId>
[src]
type NodeRef = G::NodeRef
type NodeReferences = NodeFilteredNodes<'a, G::NodeReferences, F>
fn node_references(self) -> Self::NodeReferences
impl<'a, G, F> IntoEdgeReferences for &'a NodeFiltered<G, F> where G: IntoEdgeReferences, F: FilterNode<G::NodeId>
[src]
type EdgeRef = G::EdgeRef
type EdgeReferences = NodeFilteredEdgeReferences<'a, G, G::EdgeReferences, F>
fn edge_references(self) -> Self::EdgeReferences
impl<'a, G, F> IntoEdges for &'a NodeFiltered<G, F> where G: IntoEdges, F: FilterNode<G::NodeId>
[src]
type Edges = NodeFilteredEdges<'a, G, G::Edges, F>
fn edges(self, a: G::NodeId) -> Self::Edges
impl<G, F> DataMap for NodeFiltered<G, F> where G: DataMap, F: FilterNode<G::NodeId>
[src]
fn node_weight(&self, id: Self::NodeId) -> Option<&Self::NodeWeight>
fn edge_weight(&self, id: Self::EdgeId) -> Option<&Self::EdgeWeight>
impl<G, F> Data for NodeFiltered<G, F> where G: Data
[src]
type NodeWeight = G::NodeWeight
type EdgeWeight = G::EdgeWeight
impl<G, F> NodeIndexable for NodeFiltered<G, F> where G: NodeIndexable
[src]
fn node_bound(&self) -> usize
Return an upper bound of the node indices in the graph (suitable for the size of a bitmap). Read more
fn to_index(&self, a: Self::NodeId) -> usize
Convert a
to an integer index.
fn from_index(&self, i: usize) -> Self::NodeId
Convert i
to a node index