pGraph View for deferring pGraph operations which can be flushed later. More...
Public Member Functions | |
lazy_graph_view (view_container_type *vcont) | |
Constructs a view that can reference all the elements of the passed container. The view takes ownership of the container. More... | |
lazy_graph_view (view_container_type const &vcont) | |
Constructs a view that can reference all the elements of the passed container. The view does not take ownership of the container. More... | |
lazy_graph_view (view_container_type const &vcont, indexed_domain< size_t > const &dom, f_ident< size_t > const &mf) | |
Constructs a view that can reference all the elements of the passed container. The view takes ownership of the container. More... | |
lazy_graph_view (view_container_type *vcont, indexed_domain< size_t > const &dom, f_ident< size_t > const &mf) | |
Constructs a view that can reference all the elements of the passed container. The view does not take ownership of the container. More... | |
lazy_graph_view (lazy_graph_view const &other) | |
Constructs a copy of the passed lazy_graph_view. | |
void | add_vertex (void) |
Adds a vertex to the pGraph with the given property. More... | |
void | add_vertex (vertex_property const &vp) |
Adds a vertex to the pGraph with the given property. More... | |
void | add_vertex (vertex_descriptor const &vd, vertex_property const &vp) |
Adds a vertex to the pGraph with the given property and descriptor. More... | |
void | delete_vertex (vertex_descriptor const &vd) |
Deletes a vertex from the pGraph with the given descriptor. This method is asynchronous. More... | |
void | migrate (vertex_descriptor const &vd, size_t location) |
Stores a request for migration of given vertex for future commit. More... | |
void | flush (void) |
Flushes out all pending requests to the pGraph. More... | |
size_t | size (void) const |
bool | is_valid (void) const |
view_container_type * | get_container (void) const |
view_container_type & | container (void) |
view_container_type & | container (void) const |
domain_type const & | domain (void) const |
domain_type & | domain (void) |
void | set_domain (domain_type const &dom) |
map_func_type const & | mapfunc (void) const |
bool | empty (void) const |
Returns true if the view does not reference any element. | |
Public Types | |
typedef PG::vertex_property | vertex_property |
typedef PG::vertex_descriptor | vertex_descriptor |
typedef PG | view_container_type |
typedef indexed_domain< size_t > | domain_type |
typedef f_ident< size_t > | map_func_type |
typedef mf_type_helper::index_type | index_type |
typedef mf_type_helper::gid_type | gid_type |
typedef std::size_t | size_type |
Public Attributes | |
PG * | m_ptr |
sptr_type | m_sptr |
Protected Member Functions | |
PG * | container_ptr (void) const |
Returns the container's pointer. | |
pGraph View for deferring pGraph operations which can be flushed later.
Used when modifications to the graph need to be made while an algorithm is actively executing on said graph. Deferring the modifications keeps the graph in a consistent state for all operations being applied. Provides a subset of the interface of a graph_view.
PG | The type of pGraph to which the deferred commits will be applied. |
stapl::lazy_graph_view< PG >::lazy_graph_view | ( | view_container_type * | vcont | ) |
Constructs a view that can reference all the elements of the passed container. The view takes ownership of the container.
vcont | pointer to the container used to forward the operations. |
stapl::lazy_graph_view< PG >::lazy_graph_view | ( | view_container_type const & | vcont | ) |
Constructs a view that can reference all the elements of the passed container. The view does not take ownership of the container.
vcont | reference to the container used to forward the operations. |
stapl::lazy_graph_view< PG >::lazy_graph_view | ( | view_container_type const & | vcont, |
indexed_domain< size_t > const & | dom, | ||
f_ident< size_t > const & | mf | ||
) |
Constructs a view that can reference all the elements of the passed container. The view takes ownership of the container.
This constructor is required by the view_packing implementation of repeat_view over the lazy_graph_view.
vcont | reference to the container used to forward the operations. |
dom | domain of the view, should be equal to the domain of the container. |
mf | mapping function of the view. |
stapl::lazy_graph_view< PG >::lazy_graph_view | ( | view_container_type * | vcont, |
indexed_domain< size_t > const & | dom, | ||
f_ident< size_t > const & | mf | ||
) |
Constructs a view that can reference all the elements of the passed container. The view does not take ownership of the container.
This constructor is required by the view_packing implementation of repeat_view over the lazy_graph_view.
vcont | pointer to the container used to forward the operations. |
dom | domain of the view, should be equal to the domain of the container. |
mf | mapping function of the view. |
void stapl::lazy_graph_view< PG >::add_vertex | ( | void | ) |
Adds a vertex to the pGraph with the given property.
vp | Property of the vertex. |
Vertex-descriptor is assigned automatically by the pGraph. This method is asynchronous. The vertex is added at the calling location, which is also the home location for the vertex. Stores the request for future commit.
void stapl::lazy_graph_view< PG >::add_vertex | ( | vertex_property const & | vp | ) |
Adds a vertex to the pGraph with the given property.
vp | Property of the vertex. |
Vertex-descriptor is assigned automatically by the pGraph. This method is asynchronous. The vertex is added at the calling location, which is also the home location for the vertex. Stores the request for future commit.
void stapl::lazy_graph_view< PG >::add_vertex | ( | vertex_descriptor const & | vd, |
vertex_property const & | vp | ||
) |
Adds a vertex to the pGraph with the given property and descriptor.
gid | descriptor of the vertex. |
vp | Property of the vertex. |
This method is asynchronous. The vertex is added at the calling location. An async is sent to the home-location of the vertex. Stores the request for future commit.
void stapl::lazy_graph_view< PG >::delete_vertex | ( | vertex_descriptor const & | vd | ) |
Deletes a vertex from the pGraph with the given descriptor. This method is asynchronous.
gid | descriptor of the vertex. Stores the request for future commit. |
void stapl::lazy_graph_view< PG >::migrate | ( | vertex_descriptor const & | vd, |
size_t | location | ||
) |
Stores a request for migration of given vertex for future commit.
vd | The descriptor of the vertex to be migrated. |
location | The location where the vertex needs to be migrated. |
void stapl::lazy_graph_view< PG >::flush | ( | void | ) |
Flushes out all pending requests to the pGraph.
|
inherited |
|
inherited |