summaryrefslogtreecommitdiff
path: root/test/src/mbgl/test/map_adapter.hpp
blob: 5bdab1d164ccc4f3dcbe1159cf614b2b050a2a3e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#pragma once

#include <mbgl/map/map.hpp>
#include <mbgl/map/map_impl.hpp>

namespace mbgl {

class FileSource;

// Non-public version of mbgl::Map that accepts a file source as parameter.
class MapAdapter : public Map {
public:
    explicit MapAdapter(RendererFrontend& frontend,
                        MapObserver& observer,
                        std::shared_ptr<FileSource> fileSource,
                        Scheduler& scheduler,
                        const MapOptions& options)
        : Map(std::make_unique<Map::Impl>(frontend, observer, scheduler, std::move(fileSource), options)) {}
};

} // namespace mbgl