Atlas Game Manager
A game manager for f95 and dlsite written in c++
Loading...
Searching...
No Matches
atlas::AtlasRemote Class Referencefinal

Manages all remote connections to the Atlas remote server. More...

#include <AtlasRemote.hpp>

Inheritance diagram for atlas::AtlasRemote:

Signals

void checkRemoteSignal ()
 Emitted when the remote should be checked.
 
void triggerDownloadFor (const std::uint64_t timestamp)
 Asks the remote to download the timestamp file.
 
void triggerParseFor (const std::uint64_t timestamp)
 

Public Member Functions

 AtlasRemote ()
 
void triggerCheckRemote ()
 

Private Slots

void processUpdateFile (const std::uint64_t update_time)
 Updates the local DB with the updates available.
 
void downloadUpdate (const std::uint64_t update_time)
 
void handleManifestError (QNetworkReply::NetworkError error, QNetworkReply *reply)
 
void handleDownloadError (QNetworkReply::NetworkError error, QNetworkReply *reply)
 
void handleJsonResponse (QNetworkReply *reply)
 Handles manifest requests from the server.
 
void handleDownloader (QNetworkReply *reply)
 Handles download responses from the remote.
 
void check ()
 Causes the remote to go through a full check. Asking for new updates and processing them.
 

Private Member Functions

void downloadManifest ()
 
void downloadUpdates ()
 
void processPendingUpdates ()
 
void markComplete (const std::uint64_t update_time, const bool yes=true)
 
std::vector< std::pair< std::uint64_t, std::uint64_t > > getUpdatesList () const
 Returns a list of all updates.
 
std::uint64_t getNextUpdateTime () const
 Returns the next update to process. Returns 0 if no updates to process.
 

Private Attributes

QThread m_thread {}
 
QNetworkAccessManager m_manager {}
 

Detailed Description

Manages all remote connections to the Atlas remote server.

Constructor & Destructor Documentation

◆ AtlasRemote()

atlas::AtlasRemote::AtlasRemote ( )

Member Function Documentation

◆ check

void atlas::AtlasRemote::check ( )
privateslot

Causes the remote to go through a full check. Asking for new updates and processing them.

◆ checkRemoteSignal

void atlas::AtlasRemote::checkRemoteSignal ( )
signal

Emitted when the remote should be checked.

◆ downloadManifest()

void atlas::AtlasRemote::downloadManifest ( )
private

◆ downloadUpdate

void atlas::AtlasRemote::downloadUpdate ( const std::uint64_t update_time)
privateslot

◆ downloadUpdates()

void atlas::AtlasRemote::downloadUpdates ( )
private

◆ getNextUpdateTime()

std::uint64_t atlas::AtlasRemote::getNextUpdateTime ( ) const
private

Returns the next update to process. Returns 0 if no updates to process.

◆ getUpdatesList()

std::vector< std::pair< std::uint64_t, std::uint64_t > > atlas::AtlasRemote::getUpdatesList ( ) const
private

Returns a list of all updates.

◆ handleDownloader

void atlas::AtlasRemote::handleDownloader ( QNetworkReply * reply)
privateslot

Handles download responses from the remote.

◆ handleDownloadError

void atlas::AtlasRemote::handleDownloadError ( QNetworkReply::NetworkError error,
QNetworkReply * reply )
privateslot

◆ handleJsonResponse

void atlas::AtlasRemote::handleJsonResponse ( QNetworkReply * reply)
privateslot

Handles manifest requests from the server.

◆ handleManifestError

void atlas::AtlasRemote::handleManifestError ( QNetworkReply::NetworkError error,
QNetworkReply * reply )
privateslot

◆ markComplete()

void atlas::AtlasRemote::markComplete ( const std::uint64_t update_time,
const bool yes = true )
private

◆ processPendingUpdates()

void atlas::AtlasRemote::processPendingUpdates ( )
private

◆ processUpdateFile

void atlas::AtlasRemote::processUpdateFile ( const std::uint64_t update_time)
privateslot

Updates the local DB with the updates available.

◆ triggerCheckRemote()

void atlas::AtlasRemote::triggerCheckRemote ( )

◆ triggerDownloadFor

void atlas::AtlasRemote::triggerDownloadFor ( const std::uint64_t timestamp)
signal

Asks the remote to download the timestamp file.

◆ triggerParseFor

void atlas::AtlasRemote::triggerParseFor ( const std::uint64_t timestamp)
signal

Member Data Documentation

◆ m_manager

QNetworkAccessManager atlas::AtlasRemote::m_manager {}
private

◆ m_thread

QThread atlas::AtlasRemote::m_thread {}
private

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