libzypp 17.31.23
zyppng::DetectMetalinkState Struct Reference

#include </home/abuild/rpmbuild/BUILD/libzypp-17.31.23/zypp-curl/ng/network/private/downloaderstates/detectmeta_p.h>

Inheritance diagram for zyppng::DetectMetalinkState:

Public Types

using Request = DownloadPrivateBase::Request
 

Public Member Functions

 DetectMetalinkState (DownloadPrivate &parent)
 
void enter ()
 
void exit ()
 
void onRequestStarted (NetworkRequest &)
 
void onRequestProgress (NetworkRequest &, off_t, off_t dlnow, off_t, off_t)
 
void onRequestFinished (NetworkRequest &req, const NetworkRequestError &err)
 
const NetworkRequestErrorerror () const
 
SignalProxy< void() > sigFinished ()
 
bool toMetalinkGuard () const
 
std::shared_ptr< DlMetaLinkInfoStatetoDlMetaLinkInfoState ()
 
bool toSimpleDownloadGuard () const
 

Public Attributes

std::shared_ptr< Request_request
 

Private Attributes

NetworkRequestError _error
 
bool _gotMetalink = false
 
Signal< void() > _sigFinished
 

Detailed Description

State implementation for the metalink detection phase, this state issues a HEAD request while setting the magic "Accept: *\/\*, application/metalink+xml, application/metalink4+xml" header in the request to figure out if a metalink file is available or not.

In order to use metalink support the server needs to correctly return the metalink file content type, otherwise we proceed to not downloading a metalink file

Definition at line 37 of file detectmeta_p.h.

Member Typedef Documentation

◆ Request

Constructor & Destructor Documentation

◆ DetectMetalinkState()

zyppng::DetectMetalinkState::DetectMetalinkState ( DownloadPrivate parent)

Definition at line 19 of file detectmeta_p.cc.

Member Function Documentation

◆ enter()

void zyppng::DetectMetalinkState::enter ( )

Definition at line 23 of file detectmeta_p.cc.

◆ exit()

void zyppng::DetectMetalinkState::exit ( )

Definition at line 44 of file detectmeta_p.cc.

◆ onRequestStarted()

void zyppng::DetectMetalinkState::onRequestStarted ( NetworkRequest )

Definition at line 52 of file detectmeta_p.cc.

◆ onRequestProgress()

void zyppng::DetectMetalinkState::onRequestProgress ( NetworkRequest ,
off_t  ,
off_t  dlnow,
off_t  ,
off_t   
)

Definition at line 57 of file detectmeta_p.cc.

◆ onRequestFinished()

void zyppng::DetectMetalinkState::onRequestFinished ( NetworkRequest req,
const NetworkRequestError err 
)

Definition at line 62 of file detectmeta_p.cc.

◆ error()

const NetworkRequestError & zyppng::DetectMetalinkState::error ( ) const
inline

Definition at line 51 of file detectmeta_p.h.

◆ sigFinished()

SignalProxy< void() > zyppng::DetectMetalinkState::sigFinished ( )
inline

Definition at line 55 of file detectmeta_p.h.

◆ toMetalinkGuard()

bool zyppng::DetectMetalinkState::toMetalinkGuard ( ) const
inline

Definition at line 59 of file detectmeta_p.h.

◆ toDlMetaLinkInfoState()

std::shared_ptr< DlMetaLinkInfoState > zyppng::DetectMetalinkState::toDlMetaLinkInfoState ( )

Definition at line 81 of file detectmeta_p.cc.

◆ toSimpleDownloadGuard()

bool zyppng::DetectMetalinkState::toSimpleDownloadGuard ( ) const

Definition at line 89 of file detectmeta_p.cc.

Member Data Documentation

◆ _request

std::shared_ptr<Request> zyppng::DetectMetalinkState::_request

Definition at line 71 of file detectmeta_p.h.

◆ _error

NetworkRequestError zyppng::DetectMetalinkState::_error
private

Definition at line 74 of file detectmeta_p.h.

◆ _gotMetalink

bool zyppng::DetectMetalinkState::_gotMetalink = false
private

Definition at line 75 of file detectmeta_p.h.

◆ _sigFinished

Signal< void () > zyppng::DetectMetalinkState::_sigFinished
private

Definition at line 76 of file detectmeta_p.h.


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