Description: snapshot of https://github.com/rvaser/biosoup/tree/4be6880b62a8e9fc2322ede3f69f82384f99499e
Forwarded: not-needed
--- /dev/null
+++ libbioparser-dev/vendor/biosoup/CMakeLists.txt
@@ -0,0 +1,33 @@
+cmake_minimum_required(VERSION 3.9)
+
+project(biosoup VERSION 0.8.1
+                LANGUAGES CXX
+                DESCRIPTION "Biosoup is a c++ collection of header only data structures used for storage and logging in bioinformatics tools.")
+
+set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -pedantic")
+set(CMAKE_CXX_STANDARD 11)
+set(CMAKE_CXX_STANDARD_REQUIRED ON)
+set(CMAKE_CXX_EXTENSIONS OFF)
+
+set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib)
+set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib)
+set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/bin)
+
+add_library(${PROJECT_NAME} INTERFACE)
+
+target_include_directories(${PROJECT_NAME} INTERFACE
+  $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>)
+
+option(biosoup_build_tests "Build biosoup unit tests" OFF)
+if (biosoup_build_tests)
+  find_package(GTest REQUIRED)
+  add_executable(${PROJECT_NAME}_test
+    test/nucleic_acid_test.cpp
+    test/overlap_test.cpp
+    test/progress_bar_test.cpp
+    test/sequence_test.cpp
+    test/timer_test.cpp)
+  target_link_libraries(${PROJECT_NAME}_test
+    ${PROJECT_NAME}
+    GTest::Main)
+endif ()
--- /dev/null
+++ libbioparser-dev/vendor/biosoup/include/biosoup/sequence.hpp
@@ -0,0 +1,89 @@
+// Copyright (c) 2020 Robert Vaser
+
+#ifndef BIOSOUP_SEQUENCE_HPP_
+#define BIOSOUP_SEQUENCE_HPP_
+
+#include <algorithm>
+#include <atomic>
+#include <cctype>
+#include <cstdint>
+#include <string>
+
+namespace biosoup {
+
+struct Sequence {
+ public:
+  Sequence() = default;
+
+  Sequence(const std::string& name, const std::string& data)
+      : Sequence(name.c_str(), name.size(), data.c_str(), data.size()) {}
+
+  Sequence(
+      const char* name, std::uint32_t name_len,
+      const char* data, std::uint32_t data_len)
+      : id(num_objects++),
+        name(name, name_len),
+        data(data, data_len),
+        quality() {}
+
+  Sequence(
+      const std::string& name,
+      const std::string& data,
+      const std::string& quality)
+      : Sequence(
+          name.c_str(), name.size(),
+          data.c_str(), data.size(),
+          quality.c_str(), quality.size()) {}
+
+  Sequence(
+      const char* name, std::uint32_t name_len,
+      const char* data, std::uint32_t data_len,
+      const char* quality, std::uint32_t quality_len)
+      : id(num_objects++),
+        name(name, name_len),
+        data(data, data_len),
+        quality(quality, quality_len) {}
+
+  Sequence(const Sequence&) = default;
+  Sequence& operator=(const Sequence&) = default;
+
+  Sequence(Sequence&&) = default;
+  Sequence& operator=(Sequence&&) = default;
+
+  ~Sequence() = default;
+
+  void ReverseAndComplement() {  // (optional) Watson-Crick base pairing
+    for (auto& it : data) {
+      switch (static_cast<char>(std::toupper(static_cast<unsigned char>(it)))) {
+        case 'A': it = 'T'; break;
+        case 'C': it = 'G'; break;
+        case 'G': it = 'C'; break;
+        case 'T': case 'U': it = 'A'; break;
+        case 'R': it = 'Y'; break;  // A || G
+        case 'Y': it = 'R'; break;  // C || T (U)
+        case 'K': it = 'M'; break;  // G || T (U)
+        case 'M': it = 'K'; break;  // A || C
+        case 'S': break;  // C || G
+        case 'W': break;  // A || T (U)
+        case 'B': it = 'V'; break;  // !A
+        case 'D': it = 'H'; break;  // !C
+        case 'H': it = 'D'; break;  // !G
+        case 'V': it = 'B'; break;  // !T (!U)
+        default: break;  // N || -
+      }
+    }
+    std::reverse(data.begin(), data.end());
+    std::reverse(quality.begin(), quality.end());
+  }
+
+  static std::atomic<std::uint32_t> num_objects;
+
+  std::uint32_t id;  // (optional) initialize num_objects to 0
+  std::string name;
+  std::string data;
+  std::string quality;  // (optional) Phred quality scores
+};
+
+}  // namespace biosoup
+
+#endif  // BIOSOUP_SEQUENCE_HPP_
--- /dev/null
+++ libbioparser-dev/vendor/biosoup/include/biosoup/overlap.hpp
@@ -0,0 +1,80 @@
+// Copyright (c) 2020 Robert Vaser
+
+#ifndef BIOSOUP_OVERLAP_HPP_
+#define BIOSOUP_OVERLAP_HPP_
+
+#include <cstdint>
+#include <string>
+
+namespace biosoup {
+
+struct Overlap {
+ public:
+  Overlap() = default;
+
+  Overlap(
+      std::uint64_t lhs_id, std::uint32_t lhs_begin, std::uint32_t lhs_end,
+      std::uint64_t rhs_id, std::uint32_t rhs_begin, std::uint32_t rhs_end,
+      std::uint32_t score,
+      bool strand = true)
+      : lhs_id(lhs_id),
+        lhs_begin(lhs_begin),
+        lhs_end(lhs_end),
+        rhs_id(rhs_id),
+        rhs_begin(rhs_begin),
+        rhs_end(rhs_end),
+        score(score),
+        strand(strand),
+        alignment() {}
+
+  Overlap(
+      std::uint64_t lhs_id, std::uint32_t lhs_begin, std::uint32_t lhs_end,
+      std::uint64_t rhs_id, std::uint32_t rhs_begin, std::uint32_t rhs_end,
+      std::uint32_t score,
+      const std::string& alignment,
+      bool strand = true)
+      : Overlap(
+          lhs_id, lhs_begin, lhs_end,
+          rhs_id, rhs_begin, rhs_end,
+          score,
+          alignment.c_str(), alignment.size(),
+          strand) {}
+
+  Overlap(
+      std::uint64_t lhs_id, std::uint32_t lhs_begin, std::uint32_t lhs_end,
+      std::uint64_t rhs_id, std::uint32_t rhs_begin, std::uint32_t rhs_end,
+      std::uint32_t score,
+      const char* alignment, std::uint32_t alignment_len,
+      bool strand = true)
+      : lhs_id(lhs_id),
+        lhs_begin(lhs_begin),
+        lhs_end(lhs_end),
+        rhs_id(rhs_id),
+        rhs_begin(rhs_begin),
+        rhs_end(rhs_end),
+        score(score),
+        strand(strand),
+        alignment(alignment, alignment_len) {}
+
+  Overlap(const Overlap&) = default;
+  Overlap& operator=(const Overlap&) = default;
+
+  Overlap(Overlap&&) = default;
+  Overlap& operator=(Overlap&&) = default;
+
+  ~Overlap() = default;
+
+  std::uint32_t lhs_id;
+  std::uint32_t lhs_begin;
+  std::uint32_t lhs_end;
+  std::uint32_t rhs_id;
+  std::uint32_t rhs_begin;
+  std::uint32_t rhs_end;
+  std::uint32_t score;  // based on k-mer matches or alignment score
+  bool strand;  // (optional) Watson-Crick strand
+  std::string alignment;  // (optional) cigar string
+};
+
+}  // namespace biosoup
+
+#endif  // BIOSOUP_OVERLAP_HPP_
