Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
OutputSelection Struct Reference

\variable OutputConfigurationInput::cliPipelines More...

#include <outputconfiguration.h>

Collaboration diagram for OutputSelection:

Classes

struct  Diagnostic
 Carries a source-positioned publication diagnostic without emitting it. More...
struct  Format
 \variable OutputSelection::Diagnostic::kind More...

Public Types

enum class  Mode { Compatibility , New }
 Identifies which configuration interpretation controls publication. More...

Public Member Functions

bool hasErrors () const
 Returns true if any diagnostic blocks publication.
const Format * findFormat (const QString &formatformat) const
 Returns the entry for the case-sensitive identity format, or {nullptr} if it is absent.

Static Public Member Functions

static OutputSelection resolve (const Config &configconfig, const OutputConfigurationInput &inputinput={})
 Resolves publication requests from config and the explicit input.

Public Attributes

Mode mode = Mode::Compatibility
QVector< Pipeline > pipelines
QVector< Format > formats
QVector< Diagnostic > diagnostics

Detailed Description

\variable OutputConfigurationInput::cliPipelines

The ordered command-line pipeline selection, or an empty list if absent.

\variable OutputConfigurationInput::cliFormats

The ordered command-line format selection, or an empty list if absent.

This selection may introduce formats absent from the configuration.

\variable OutputConfigurationInput::pipelineCapabilities

The capability records for pipelines known to the caller.

Supply one effective record per pipeline. Absence of a selected pipeline's record is an error, as is a record whose {available} value is false.

\inmodule QDoc

Resolves format requests and ownership independently of destination layout.

Explicit pipeline presence in a configuration file or include, or an explicit command-line selection, opts in to the new publication model. Without either, the result is a compatibility marker; existing runtime interpretation retains control.

The result retains the full configured format order, followed by CLI-only identities. Repeated identities keep their first occurrence. Identity tokens are trimmed and empty tokens are discarded; path values do not use this normalization. Requested flags record CLI replacement without losing configured positions needed by subsequent layout planning.

Template owns its declared formats before legacy, independently of pipeline order. Ownership and extension values are usable for requested formats only in New mode when hasErrors() returns false. Non-requested entries retain configured identity and position without requiring a usable owner.

Resolution never creates output, constructs generators, loads packages, or emits diagnostics. The caller handles errors before publication and emits migration notices outside the authored-documentation warning budget.

Definition at line 36 of file outputconfiguration.h.

Member Enumeration Documentation

◆ Mode

enum class OutputSelection::Mode
strong

Identifies which configuration interpretation controls publication.

\value Compatibility No explicit pipeline selection; use existing runtime behavior. \value New Explicit pipeline selection; use the resolved publication model.

Enumerator
Compatibility 
New 

Definition at line 38 of file outputconfiguration.h.

Member Function Documentation

◆ findFormat()

const OutputSelection::Format * OutputSelection::findFormat ( const QString & format) const
nodiscard

Returns the entry for the case-sensitive identity format, or {nullptr} if it is absent.

The entry may be configured but unrequested.

The result borrows storage from this selection and is valid only while that storage remains alive and unchanged. Looking up an entry does not validate it.

Definition at line 528 of file outputconfiguration.cpp.

◆ hasErrors()

bool OutputSelection::hasErrors ( ) const
nodiscard

Returns true if any diagnostic blocks publication.

Notices alone do not invalidate the selection or consume the documentation warning budget.

Definition at line 512 of file outputconfiguration.cpp.

◆ resolve()

OutputSelection OutputSelection::resolve ( const Config & config,
const OutputConfigurationInput & input = {} )
staticnodiscard

Resolves publication requests from config and the explicit input.

Returns diagnostics as data and leaves both inputs unchanged. Compatibility mode returns no format plan but can carry notices for new-only settings without explicit pipeline opt-in. In New mode, errors invalidate the result; callers must check hasErrors() before using requested owners or extensions.

Definition at line 370 of file outputconfiguration.cpp.

References Location::Location(), OutputSelection::Format::configured, OutputSelection::Diagnostic::Error, Legacy, mode, New, OutputSelection::Diagnostic::Notice, OutputSelection::Format::pipeline, PipelineCapabilities::pipeline, OutputSelection::Format::requested, and Template.

Referenced by OutputConfiguration::resolve().

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ diagnostics

QVector<Diagnostic> OutputSelection::diagnostics

Definition at line 62 of file outputconfiguration.h.

◆ formats

QVector<Format> OutputSelection::formats

Definition at line 61 of file outputconfiguration.h.

◆ mode

Mode OutputSelection::mode = Mode::Compatibility

Definition at line 59 of file outputconfiguration.h.

Referenced by resolve().

◆ pipelines

QVector<Pipeline> OutputSelection::pipelines

Definition at line 60 of file outputconfiguration.h.


The documentation for this struct was generated from the following files: