Boost  v1.57.0
doxygen for www.boost.org
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
boost::graph::distributed::named_graph< Graph, Vertex, Edge, Config >::lazy_add_vertex Struct Reference

Data structure returned from add_vertex that will "lazily" add the vertex, either when it is converted to a vertex_descriptor or when the most recent copy has been destroyed. More...

#include <named_graph.hpp>

Collaboration diagram for boost::graph::distributed::named_graph< Graph, Vertex, Edge, Config >::lazy_add_vertex:

Public Member Functions

 lazy_add_vertex (named_graph &self, const vertex_name_type &name)
 Construct a new lazyily-added vertex. More...
 
 lazy_add_vertex (const lazy_add_vertex &other)
 Transfer responsibility for adding the vertex from the source of the copy to the newly-constructed opbject. More...
 
 ~lazy_add_vertex ()
 If the vertex has not been added yet, add it. More...
 
 operator vertex_descriptor () const
 Add the vertex and return its descriptor. More...
 
vertex_descriptor commit () const
 Add the vertex and return its descriptor. More...
 

Protected Attributes

named_graphself
 
vertex_name_type name
 
bool committed
 

Detailed Description

template<typename Graph, typename Vertex, typename Edge, typename Config>
struct boost::graph::distributed::named_graph< Graph, Vertex, Edge, Config >::lazy_add_vertex

Data structure returned from add_vertex that will "lazily" add the vertex, either when it is converted to a vertex_descriptor or when the most recent copy has been destroyed.

Constructor & Destructor Documentation

template<typename Graph, typename Vertex, typename Edge, typename Config>
boost::graph::distributed::named_graph< Graph, Vertex, Edge, Config >::lazy_add_vertex::lazy_add_vertex ( named_graph self,
const vertex_name_type name 
)
inline

Construct a new lazyily-added vertex.

template<typename Graph, typename Vertex, typename Edge, typename Config>
boost::graph::distributed::named_graph< Graph, Vertex, Edge, Config >::lazy_add_vertex::lazy_add_vertex ( const lazy_add_vertex other)
inline

Transfer responsibility for adding the vertex from the source of the copy to the newly-constructed opbject.

References boost::graph::distributed::named_graph< Graph, Vertex, Edge, Config >::lazy_add_vertex::committed.

template<typename Graph , typename Vertex , typename Edge , typename Config >
boost::graph::distributed::named_graph< Graph, Vertex, Edge, Config >::lazy_add_vertex::~lazy_add_vertex ( )

If the vertex has not been added yet, add it.

If this vertex has already been created or will be created by someone else, or if someone threw an exception, we will not create the vertex now.

Add the vertex locally

Ask the owner of the vertex to add a vertex with this name

References boost::graph::distributed::add_vertex(), boost::iostreams::gzip::flags::name, boost::detail::parallel::owner(), boost::process_group(), boost::graph::distributed::process_id(), and boost::graph::distributed::send().

Member Function Documentation

template<typename Graph , typename Vertex , typename Edge , typename Config >
named_graph< Graph, Vertex, Edge, Config >::vertex_descriptor boost::graph::distributed::named_graph< Graph, Vertex, Edge, Config >::lazy_add_vertex::commit ( ) const

Add the vertex and return its descriptor.

This can only be called once, and only when this object is responsible for creating the vertex.

Add the vertex locally

Ask the owner of the vertex to add a vertex with this name

References boost::graph::distributed::add_vertex(), BOOST_ASSERT, boost::iostreams::gzip::flags::name, boost::detail::parallel::owner(), boost::process_group(), boost::graph::distributed::process_id(), and boost::graph::distributed::send_oob_with_reply().

template<typename Graph, typename Vertex, typename Edge, typename Config>
boost::graph::distributed::named_graph< Graph, Vertex, Edge, Config >::lazy_add_vertex::operator vertex_descriptor ( ) const
inline

Add the vertex and return its descriptor.

This conversion can only occur once, and only when this object is responsible for creating the vertex.

Member Data Documentation

template<typename Graph, typename Vertex, typename Edge, typename Config>
bool boost::graph::distributed::named_graph< Graph, Vertex, Edge, Config >::lazy_add_vertex::committed
mutableprotected
template<typename Graph, typename Vertex, typename Edge, typename Config>
vertex_name_type boost::graph::distributed::named_graph< Graph, Vertex, Edge, Config >::lazy_add_vertex::name
protected
template<typename Graph, typename Vertex, typename Edge, typename Config>
named_graph& boost::graph::distributed::named_graph< Graph, Vertex, Edge, Config >::lazy_add_vertex::self
protected

The documentation for this struct was generated from the following file: