TSDuck v3.38-3699
MPEG Transport Stream Toolkit
Loading...
Searching...
No Matches
tsSysUtils.h File Reference

Various system utilities. More...

Namespaces

namespace  ts
 TSDuck namespace, containing all TSDuck classes and functions.
 

Typedefs

using ts::ioctl_request_t = platform-dependent
 Portable type for ioctl() request parameter.
 

Functions

fs::path ts::CallerLibraryFile ()
 Get the name of the executable or shared library file containing the caller code.
 
UString ts::ClassName (const std::type_info &info)
 Get the name of a class from the type_info of an object.
 
fs::path ts::ExecutableFile ()
 Get the name of the current application executable file.
 
cn::milliseconds ts::GetProcessCpuTime ()
 Get the CPU time of the process in milliseconds.
 
size_t ts::GetProcessVirtualSize ()
 Get the virtual memory size of the process in bytes.
 
void ts::IgnorePipeSignal ()
 Ensure that writing to a broken pipe does not kill the current process.
 
bool ts::IsPrivilegedUser ()
 Check if the current user is privileged (root on UNIX, an administrator on Windows).
 
int ts::LastSysErrorCode ()
 Get the error code of the last operating system call.
 
bool ts::SetBinaryModeStdin (Report &report=(ts::CerrReport::Instance()))
 Put the standard input stream in binary mode.
 
bool ts::SetBinaryModeStdout (Report &report=(ts::CerrReport::Instance()))
 Put the standard output stream in binary mode.
 
template<class Rep , class Period >
void ts::SetTimersPrecision (cn::duration< Rep, Period > &precision)
 Request a minimum resolution for the system timers.
 
bool ts::StdErrIsTerminal ()
 Check if the standard error is a terminal.
 
bool ts::StdInIsTerminal ()
 Check if the standard input is a terminal.
 
bool ts::StdOutIsTerminal ()
 Check if the standard output is a terminal.
 
std::string ts::SysErrorCodeMessage (int code=LastSysErrorCode(), const std::error_category &category=std::system_category())
 Format a system error code into a string.
 

Detailed Description

Various system utilities.