TSDuck v3.38-3675
MPEG Transport Stream Toolkit
Loading...
Searching...
No Matches
ts::FileNameRate Class Reference

Representation of a file name and an associated repetition rate. More...

#include <tsFileNameRate.h>

Collaboration diagram for ts::FileNameRate:

Public Member Functions

 FileNameRate (const UString &name=UString(), cn::milliseconds rep=cn::milliseconds::zero())
 Default constructor.
 
bool operator< (const FileNameRate &other) const
 Comparison "less than" operator.
 
bool operator== (const FileNameRate &other) const
 Comparison operator.
 
bool scanFile (size_t retry=1, Report &report=(ts::NullReport::Instance()))
 Scan the file for update.
 

Public Attributes

UString display_name {}
 File name in display form.
 
Time file_date {}
 Last modification date of file.
 
UString file_name {}
 File name.
 
bool inline_xml = false
 File name contains inline XML text (not a real file name).
 
cn::milliseconds repetition {}
 Repetition rate in milliseconds.
 
size_t retry_count = 1
 Number of allowed retry in case of error when using the file.
 

Detailed Description

Representation of a file name and an associated repetition rate.

This is typically used to handle section files to inject into transport streams.

Constructor & Destructor Documentation

◆ FileNameRate()

ts::FileNameRate::FileNameRate ( const UString name = UString(),
cn::milliseconds  rep = cn::milliseconds::zero() 
)
explicit

Default constructor.

Parameters
[in]nameFile name.
[in]repRepetition rate in milliseconds.

Member Function Documentation

◆ operator==()

bool ts::FileNameRate::operator== ( const FileNameRate other) const

Comparison operator.

Parameters
[in]otherOther instance to compare.
Returns
True if this instance is equal to other.

◆ operator<()

bool ts::FileNameRate::operator< ( const FileNameRate other) const

Comparison "less than" operator.

It does not really makes sense. Only defined to allow usage in containers.

Parameters
[in]otherOther instance to compare.
Returns
True if this instance is less than to other.

◆ scanFile()

bool ts::FileNameRate::scanFile ( size_t  retry = 1,
Report report = (ts::NullReport::Instance()) 
)

Scan the file for update.

Update the modification date of the file in file_date.

Parameters
[in]retryNumber of allowed retry in case of error when using the file.
[in]reportWhere to report a verbose message when a file changed.
Returns
True if the file has changed or is scanned for the first time or has been deleted.

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