1//===----------------------------------------------------------------------===//
2// DuckDB
3//
4// duckdb/common/file_opener.hpp
5//
6//
7//===----------------------------------------------------------------------===//
8
9#pragma once
10
11#include "duckdb/common/string.hpp"
12#include "duckdb/common/winapi.hpp"
13
14namespace duckdb {
15
16class ClientContext;
17class Value;
18
19//! Abstract type that provide client-specific context to FileSystem.
20class FileOpener {
21public:
22 virtual ~FileOpener() {};
23
24 virtual bool TryGetCurrentSetting(const string &key, Value &result) = 0;
25 virtual ClientContext *TryGetClientContext() = 0;
26
27 DUCKDB_API static ClientContext *TryGetClientContext(FileOpener *opener);
28 DUCKDB_API static bool TryGetCurrentSetting(FileOpener *opener, const string &key, Value &result);
29};
30
31} // namespace duckdb
32