readPbfStore - multiple declarations

Function readPbfStore

Read one complete in-memory PBF directly into a compact editable OSM store.

bool readPbfStore(
  scope const(ubyte)[] input,
  out OsmStore store,
  out PbfReadSummary summary,
  out PbfStoreReadStatus status
) @safe;

The complete input must remain alive only for this call. The returned store owns its IDs, coordinates, metadata, tags, Way references, Relation members, strings, primary indexes and parent indexes.

Construction is transactional at the public boundary: on any PBF or store-semantic failure, store is null and summary is reset. status retains the applicable diagnostics.

The selected M6 path is single-writer and uses one reusable PbfReaderWorkspace. It does not allocate a worker queue or block-local staging stores. This keeps temporary memory bounded by the largest reader workspace plus the growing durable store. Parallel staging was deliberately not made part of this API; see ADR 0024.

Function readPbfStore

Read one complete bounded ByteSource directly into an editable OSM store.

bool readPbfStore(
  scope transport.source.ByteSource inputSource,
  out OsmStore store,
  out PbfReadSummary summary,
  out PbfSourceStoreReadStatus status
) @safe;

PBF framing is consumed incrementally through transport-d. The parser keeps only current-block/reusable decode scratch; it does not materialize the complete encoded source. Accepted semantic values are copied immediately into the candidate store.

Construction is transactional at the public boundary. On transport, PBF or store-semantic failure, store remains null and summary remains reset. status preserves the applicable source/PBF and store diagnostics.

Parameters

NameDescription
inputSource Generic transport-d byte source. The source itself must remain valid only for this synchronous call.
store Receives the fully built store on success, otherwise null.
summary Receives complete decoded counts on success.
status Receives combined source/PBF/store diagnostics.

Returns

true only after the complete source was validated and committed to the returned store.