DbnStore::GetMetadata

Decodes the DBN metadata if it has not already been decoded and returns a reference to it.

Returns

const Metadata&

DBN Metadata about the file.

API method
const Metadata& GetMetadata();
Example usage
1
2
3
4
5
6
7
8
9
10
11
#include <databento/historical.hpp>
#include <iostream>

using namespace databento;

auto client =
    Historical::Builder().SetKey("$YOUR_API_KEY").Build();
DbnStore dbn_store = client.TimeseriesGetRangeToFile(
    "XNAS.ITCH", {"2024-06-24", "2024-06-29"}, {"META"},
    Schema::Trades, "META_20240624-20240629.dbn.zst");
std::cout << dbn_store.GetMetadata() << '\n';
Example response
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
Metadata {
    version = 3,
    dataset = "XNAS.ITCH",
    schema = trades,
    start = 2024-06-24T00:00:00.000000000Z,
    end = 2024-06-29T00:00:00.000000000Z,
    limit = 0,
    stype_in = raw_symbol,
    stype_out = instrument_id,
    ts_out = false,
    symbol_cstr_len = 71,
    symbols = { "META" },
    partial = {},
    not_found = {},
    mappings = {
        SymbolMapping { raw_symbol = "META", intervals = { MappingInterval { start_date = 2024-06-24, end_date = 2024-06-29, symbol = "10451" } } }
    }
}