Return the number of contigs by which the two paths overlap. */
| 471 | |
| 472 | /** Return the number of contigs by which the two paths overlap. */ |
| 473 | static unsigned |
| 474 | getOverlap( |
| 475 | const OverlapMap& pmap, |
| 476 | graph_traits<Graph>::vertex_descriptor u, |
| 477 | graph_traits<Graph>::vertex_descriptor v) |
| 478 | { |
| 479 | if (isPath(u) && isPath(v)) { |
| 480 | // Both vertices are paths. |
| 481 | OverlapMap::const_iterator it = pmap.find(edge_descriptor(u, v)); |
| 482 | return it == pmap.end() ? 0 : it->second; |
| 483 | } else { |
| 484 | // One of the two vertices is a contig. |
| 485 | return 0; |
| 486 | } |
| 487 | } |
| 488 | |
| 489 | /** Merge a sequence of overlapping paths. */ |
| 490 | static ContigPath |
no test coverage detected