TSDuck v3.40-4120
MPEG Transport Stream Toolkit
Loading...
Searching...
No Matches
ts::VersionInfo::RegisterFeature Class Reference

A class to register a feature of the application. More...

#include <tsVersionInfo.h>

Public Types

using GetVersionFunc = UString(*)()
 Profile of a function return a version string.
 
enum  Support {
  ALWAYS ,
  SUPPORTED ,
  UNSUPPORTED
}
 Describe the level of support for a feature. More...
 

Public Member Functions

 RegisterFeature (const UString &option, const UString &name, Support support, GetVersionFunc get_version)
 Register a feature.
 

Detailed Description

A class to register a feature of the application.

The registration is performed using constructors. Thus, it is possible to perform a registration in the declaration of a static object.

Member Enumeration Documentation

◆ Support

Describe the level of support for a feature.

Enumerator
ALWAYS 

Feature is always supported, may ask version but no need to ask if supported.

SUPPORTED 

Optional feature, currently supported.

UNSUPPORTED 

Optional feature, not supported.

Constructor & Destructor Documentation

◆ RegisterFeature()

ts::VersionInfo::RegisterFeature::RegisterFeature ( const UString option,
const UString name,
Support  support,
GetVersionFunc  get_version 
)

Register a feature.

Parameters
[in]optionFeature name as used in command line options.
[in]nameFeature name as used on display.
[in]supportLevel of support.
[in]get_versionFunction returning the version of the feature. Can be null (no identified version).

The documentation for this class was generated from the following file: