libzypp  17.31.0
internal::ProgressData Struct Reference

Public Member Functions

 ProgressData (CURL *_curl, time_t _timeout=0, const zypp::Url &_url=zypp::Url(), zypp::ByteCount expectedFileSize_r=0, zypp::callback::SendReport< zypp::media::DownloadProgressReport > *_report=nullptr)
 
void updateStats (double dltotal=0.0, double dlnow=0.0)
 
int reportProgress () const
 

Public Attributes

CURL * curl
 
zypp::Url url
 
time_t timeout
 
bool reached
 
bool fileSizeExceeded
 
zypp::callback::SendReport< zypp::media::DownloadProgressReport > * report
 
zypp::ByteCount _expectedFileSize
 
time_t _timeStart = 0
 Start total stats. More...
 
time_t _timeLast = 0
 Start last period(~1sec) More...
 
time_t _timeRcv = 0
 Start of no-data timeout. More...
 
time_t _timeNow = 0
 Now. More...
 
double _dnlTotal = 0.0
 Bytes to download or 0 if unknown. More...
 
double _dnlLast = 0.0
 Bytes downloaded at period start. More...
 
double _dnlNow = 0.0
 Bytes downloaded now. More...
 
int _dnlPercent = 0
 Percent completed or 0 if _dnlTotal is unknown. More...
 
double _drateTotal = 0.0
 Download rate so far. More...
 
double _drateLast = 0.0
 Download rate in last period. More...
 
double drate_period
 
double dload_period
 
long secs
 
double drate_avg
 
time_t ltime
 
double dload
 
double uload
 

Detailed Description

Definition at line 45 of file MediaCurl.cc.

Constructor & Destructor Documentation

◆ ProgressData()

internal::ProgressData::ProgressData ( CURL *  _curl,
time_t  _timeout = 0,
const zypp::Url _url = zypp::Url(),
zypp::ByteCount  expectedFileSize_r = 0,
zypp::callback::SendReport< zypp::media::DownloadProgressReport > *  _report = nullptr 
)

Definition at line 96 of file MediaCurl.cc.

Member Function Documentation

◆ updateStats()

void internal::ProgressData::updateStats ( double  dltotal = 0.0,
double  dlnow = 0.0 
)

Definition at line 106 of file MediaCurl.cc.

◆ reportProgress()

int internal::ProgressData::reportProgress ( ) const

Definition at line 149 of file MediaCurl.cc.

Member Data Documentation

◆ curl

CURL* internal::ProgressData::curl

Definition at line 51 of file MediaCurl.cc.

◆ url

zypp::Url internal::ProgressData::url

Definition at line 52 of file MediaCurl.cc.

◆ timeout

time_t internal::ProgressData::timeout

Definition at line 53 of file MediaCurl.cc.

◆ reached

bool internal::ProgressData::reached

Definition at line 54 of file MediaCurl.cc.

◆ fileSizeExceeded

bool internal::ProgressData::fileSizeExceeded

Definition at line 55 of file MediaCurl.cc.

◆ report

Definition at line 56 of file MediaCurl.cc.

◆ _expectedFileSize

zypp::ByteCount internal::ProgressData::_expectedFileSize

Definition at line 57 of file MediaCurl.cc.

◆ _timeStart

time_t internal::ProgressData::_timeStart = 0

Start total stats.

Definition at line 59 of file MediaCurl.cc.

◆ _timeLast

time_t internal::ProgressData::_timeLast = 0

Start last period(~1sec)

Definition at line 60 of file MediaCurl.cc.

◆ _timeRcv

time_t internal::ProgressData::_timeRcv = 0

Start of no-data timeout.

Definition at line 61 of file MediaCurl.cc.

◆ _timeNow

time_t internal::ProgressData::_timeNow = 0

Now.

Definition at line 62 of file MediaCurl.cc.

◆ _dnlTotal

double internal::ProgressData::_dnlTotal = 0.0

Bytes to download or 0 if unknown.

Definition at line 64 of file MediaCurl.cc.

◆ _dnlLast

double internal::ProgressData::_dnlLast = 0.0

Bytes downloaded at period start.

Definition at line 65 of file MediaCurl.cc.

◆ _dnlNow

double internal::ProgressData::_dnlNow = 0.0

Bytes downloaded now.

Definition at line 66 of file MediaCurl.cc.

◆ _dnlPercent

int internal::ProgressData::_dnlPercent = 0

Percent completed or 0 if _dnlTotal is unknown.

Definition at line 68 of file MediaCurl.cc.

◆ _drateTotal

double internal::ProgressData::_drateTotal = 0.0

Download rate so far.

Definition at line 70 of file MediaCurl.cc.

◆ _drateLast

double internal::ProgressData::_drateLast = 0.0

Download rate in last period.

Definition at line 71 of file MediaCurl.cc.

◆ drate_period

double internal::ProgressData::drate_period

Definition at line 79 of file MediaCurl.cc.

◆ dload_period

double internal::ProgressData::dload_period

Definition at line 81 of file MediaCurl.cc.

◆ secs

long internal::ProgressData::secs

Definition at line 83 of file MediaCurl.cc.

◆ drate_avg

double internal::ProgressData::drate_avg

Definition at line 85 of file MediaCurl.cc.

◆ ltime

time_t internal::ProgressData::ltime

Definition at line 87 of file MediaCurl.cc.

◆ dload

double internal::ProgressData::dload

Definition at line 89 of file MediaCurl.cc.

◆ uload

double internal::ProgressData::uload

Definition at line 91 of file MediaCurl.cc.


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