Refactor graph writing code in contractor

This commit is contained in:
Patrick Niklaus
2017-04-02 23:02:57 +00:00
committed by Patrick Niklaus
parent 90c194fc81
commit ef3fcdc6e6
11 changed files with 172 additions and 221 deletions
+6 -6
View File
@@ -95,10 +95,10 @@ inline void writeTurnData(const boost::filesystem::path &path,
}
// reads .osrm.tls
template <bool UseShareMemory>
template <storage::Ownership Ownership>
inline void readTurnLaneDescriptions(const boost::filesystem::path &path,
typename util::ShM<std::uint32_t, UseShareMemory>::vector &turn_offsets,
typename util::ShM<extractor::guidance::TurnLaneType::Mask, UseShareMemory>::vector &turn_masks)
typename util::ShM<std::uint32_t, Ownership>::vector &turn_offsets,
typename util::ShM<extractor::guidance::TurnLaneType::Mask, Ownership>::vector &turn_masks)
{
const auto fingerprint = storage::io::FileReader::HasNoFingerprint;
storage::io::FileReader reader{path, fingerprint};
@@ -108,10 +108,10 @@ inline void readTurnLaneDescriptions(const boost::filesystem::path &path,
}
// writes .osrm.tls
template <bool UseShareMemory>
template <storage::Ownership Ownership>
inline void writeTurnLaneDescriptions(const boost::filesystem::path &path,
const typename util::ShM<std::uint32_t, UseShareMemory>::vector &turn_offsets,
const typename util::ShM<extractor::guidance::TurnLaneType::Mask, UseShareMemory>::vector &turn_masks)
const typename util::ShM<std::uint32_t, Ownership>::vector &turn_offsets,
const typename util::ShM<extractor::guidance::TurnLaneType::Mask, Ownership>::vector &turn_masks)
{
const auto fingerprint = storage::io::FileWriter::HasNoFingerprint;
storage::io::FileWriter writer{path, fingerprint};