DoorKeeper/include/components/tilestreamer.hpp

34 lines
811 B
C++
Raw Normal View History

#ifndef id9B1C02049E474F6997D367932C4C2D21
#define id9B1C02049E474F6997D367932C4C2D21
#include "primitivetypes.hpp"
#include <iostream>
#include <vector>
#include <algorithm>
#include <memory>
namespace dk {
template <typename T, size_t D>
class TileStreamer {
public:
typedef Vector<CoordinateScalarType, D> coords;
typedef std::unique_ptr<std::istream> StreamPtr;
explicit TileStreamer ( StreamPtr&& parStream );
TileStreamer ( const TileStreamer& ) = delete;
TileStreamer ( TileStreamer&& ) = default;
~TileStreamer ( void ) noexcept = default;
TileStreamer& operator= ( const TileStreamer& ) = delete;
void copy ( std::vector<T>& parDest, const coords& parFrom, const coords& parTo );
private:
StreamPtr m_stream;
};
} //namespace dk
#include "implem/tilestreamer.inl"
#endif