Ignore:
Timestamp:
May 19, 2017, 1:13:41 PM (8 years ago)
Author:
Frederik Heber <frederik.heber@…>
Branches:
ForceAnnealing_goodresults, ForceAnnealing_tocheck
Children:
53ef16e
Parents:
adbeca
Message:

Edges may be added and removed in BoostGraphCreator.

  • TESTS: added unit test case on this.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Graph/BoostGraphCreator.hpp

    radbeca r94791a  
    6161  //!> typedef for vertex iterator
    6262  typedef boost::graph_traits<UndirectedGraph>::vertex_iterator vertex_iter;
     63  //!> typedef for a Edge
     64  typedef boost::graph_traits<UndirectedGraph>::edge_descriptor Edge;
     65  //!> typedef for edge iterator
     66  typedef boost::graph_traits<UndirectedGraph>::edge_iterator edge_iter;
    6367
    6468  //!> typedef for a node id
     
    145149      );
    146150
     151  /** Finds a given edge by its two atomic indices.
     152   *
     153   * \param _firstid first atomic id of edge
     154   * \param _secondid second atomic id of edge
     155   * \return edge descriptor in graph or empty descriptor
     156   */
     157  Edge findEdge(const atomId_t &_firstid, const atomId_t &_secondid);
     158
     159  /** Allows to remove a present edge in the graph.
     160   *
     161   * \param _firstid first atomic id of edge
     162   * \param _secondid second atomic id of edge
     163   * \return true - edge found and removed, false - else
     164   */
     165  bool removeEdge(const atomId_t &_firstid, const atomId_t &_secondid);
     166
     167  /** Adds an edge to the graph if not already present.
     168   *
     169   * \param _firstid first atomic id of edge
     170   * \param _secondid second atomic id of edge
     171   * \return true - edge not found thus added, false - else
     172   */
     173  bool addEdge(const atomId_t &_firstid, const atomId_t &_secondid);
     174
    147175private:
    148176  //!> internal graph that is created by creator functions
Note: See TracChangeset for help on using the changeset viewer.