arcstk::v_1_0_0::ToC class final

Table of contents of a compact disc.

Constructors, destructors, conversion operators

ToC(const ToCData& toc_data) explicit
Constructor.
ToC(const ToCData& toc_data, const std::vector<std::string>& filenames)
Constructor.
~ToC() noexcept
Default destructor.

Public functions

auto complete() const -> bool noexcept
TRUE iff offsets and non-zero leadout are present, otherwise FALS.
auto equals(const ToC& rhs) const -> bool noexcept
TRUE iff this instance is equal to another instance.
auto filenames() const -> std::vector<std::string>
Filenames of this ToC.
auto is_single_file() const -> bool noexcept
TRUE iff the ToC specifies exactly one audiofile, otherwise FALSE.
auto leadout() const -> AudioSize noexcept
Leadout LBA frame of this ToC.
auto offsets() const -> std::vector<AudioSize>
Offsets of this ToC.
void set_leadout(const AudioSize leadout) noexcept
Set the leadout LBA frame of this ToC.
auto total_tracks() const -> int noexcept
Total tracks in this ToC.

Function documentation

arcstk::v_1_0_0::ToC::ToC(const ToCData& toc_data) explicit

Constructor.

Parameters
toc_data in The ToC data to construct a ToC from

arcstk::v_1_0_0::ToC::ToC(const ToCData& toc_data, const std::vector<std::string>& filenames)

Constructor.

Parameters
toc_data in The ToC data to construct a ToC from
filenames in Audio filenames

bool arcstk::v_1_0_0::ToC::complete() const noexcept

TRUE iff offsets and non-zero leadout are present, otherwise FALS.

Returns TRUE iff ToC contains complete toc information otherwise FALSE

bool arcstk::v_1_0_0::ToC::equals(const ToC& rhs) const noexcept

TRUE iff this instance is equal to another instance.

Parameters
rhs in Instance to check for equality
Returns TRUE iff rhs == this

std::vector<std::string> arcstk::v_1_0_0::ToC::filenames() const

Filenames of this ToC.

Returns Filenames

bool arcstk::v_1_0_0::ToC::is_single_file() const noexcept

TRUE iff the ToC specifies exactly one audiofile, otherwise FALSE.

Returns TRUE iff the ToC has exactly one audio file, otherwise FALSE

However, the filenames() returned may be more than 1, but they will be all identical. This is possible when the parsed metadata source specifies a file for each track.

This will be FALSE in case where multiple non-identical filenames were specified by the metadata source.

AudioSize arcstk::v_1_0_0::ToC::leadout() const noexcept

Leadout LBA frame of this ToC.

Returns Leadout LBA frame

If the leadout is unknown, the AudioSize returned is zero().

std::vector<AudioSize> arcstk::v_1_0_0::ToC::offsets() const

Offsets of this ToC.

Returns Offsets

void arcstk::v_1_0_0::ToC::set_leadout(const AudioSize leadout) noexcept

Set the leadout LBA frame of this ToC.

Parameters
leadout in The leadout frame to set

int arcstk::v_1_0_0::ToC::total_tracks() const noexcept

Total tracks in this ToC.

Returns Total tracks