Skip to main content

Module profile_export

Module profile_export 

Source
Expand description

Export of saved profiles into third-party ballistic profile files.

Currently the ArcherBC2 .a7p format — the outbound half of crate::profile_import, written from the same protobuf wire specification with no upstream schema files or code vendored (the a7p package as distributed is GPL-3.0, this crate is MIT OR Apache-2.0).

Export is LOSSY in one direction the importer never had to worry about: a saved profile holds a good deal the format has no slot for. Every export therefore returns the bytes AND NotCarried — the full list of ProfileData fields that did not make it, and whether this particular profile had anything in them. See a7p.rs’s module doc for why the list is unconditional.

Structs§

A7pExport
A .a7p file plus everything the caller has to be told about it.
NotCarried
One ProfileData field the .a7p format has no place for.

Enums§

A7pExportError
Why an export could not happen at all. Distinct from the lossy-but-successful outcomes above: these are profiles that cannot be expressed as a .a7p file without inventing something.

Constants§

CARRIED_FIELDS
The ProfileData fields this encoder DOES put in the file. The complement of the not-carried list; the two partition the struct, and not_carried_and_carried_cover_every_profile_field proves it.

Functions§

export_a7p
Encode a saved profile as an ArcherBC2 .a7p file.