RaftLib  0.3a
C++ Stream Processing Template Library
Static Public Member Functions | List of all members
GraphTools Class Reference

Static Public Member Functions

static void BFS (std::set< raft::kernel * > &source_kernels, edge_func func, void *data=nullptr, bool connected_error=false)
 
static void BFS (std::vector< raft::kernel * > &source_kernels, edge_func func, void *data=nullptr, bool connected_error=false)
 

Member Function Documentation

void GraphTools::BFS ( std::set< raft::kernel * > &  source_kernels,
edge_func  func,
void *  data = nullptr,
bool  connected_error = false 
)
static

BFS - perform a breadth first search of the graph given by 'source_kernels'. The function 'func' matches the typedef above and is called on each edge of the graph exactly once. For state between calls, the user can define a data struct and pass it via the void ptr data which is passed to the func.

Parameters
source_kernels- set of source kernels.
func- edge_func, funciton to be called
data- void*, data struct for persistent state
connected_error,throwan error if not connected

graphtools.cpp -

Author
: Jonathan Beard
Version
: Sat Sep 20 13:15:09 2014

Copyright 2014 Jonathan Beard

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at:

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Here is the caller graph for this function:

void GraphTools::BFS ( std::vector< raft::kernel * > &  source_kernels,
edge_func  func,
void *  data = nullptr,
bool  connected_error = false 
)
static

BFS - perform a breadth first search of the graph given by 'source_kernels'. The function 'func' matches the typedef above and is called on each edge of the graph exactly once. For state between calls, the user can define a data struct and pass it via the void ptr data which is passed to the func.

Parameters
source_kernels- set of source kernels.
func- edge_func, funciton to be called
data- void*, data struct for persistent state
connected_error,throwan error if not connected

The documentation for this class was generated from the following files: