QXmpp Version: 1.10.0
Classes | Public Types | Public Member Functions | Properties | Friends | List of all members
QXmppFileUpload Class Reference

Provides progress of stateless file sharing uploads. More...

Inherits QObject.

Classes

class  FileResult
 Contains QXmppFileShare of the uploaded file and possible data blobs containing referenced thumbnails. More...
 

Public Types

using Result = std::variant< FileResult, QXmpp::Cancelled, QXmppError >
 Contains FileResult (successfully finished), QXmpp::Cancelled (manually cancelled) or QXmppError (an error occured while uploading).
 

Public Member Functions

float progress () const
 
Q_SIGNAL void progressChanged ()
 Emitted when new bytes have been transferred.
 
void cancel ()
 Cancels the file transfer. finished() will be emitted.
 
bool isFinished () const
 Returns whether the file transfer is finished.
 
quint64 bytesTransferred () const
 Returns the number of bytes that have been uploaded or downloaded.
 
quint64 bytesTotal () const
 Returns the number of bytes that totally need to be transferred.
 
Result result () const
 Returns the result of the upload. More...
 
Q_SIGNAL void finished ()
 

Properties

float progress
 Progress of the file upload between 0.0 and 1.0.
 

Friends

class QXmppFileSharingManager
 

Detailed Description

Provides progress of stateless file sharing uploads.

Since
QXmpp 1.5

Member Function Documentation

◆ finished()

QXmppFileUpload::finished ( )

Emitted when the upload has finished.

◆ progress()

float QXmppFileUpload::progress ( ) const

Returns the current progress between 0.0 and 1.0.

◆ result()

QXmppFileUpload::Result QXmppFileUpload::result ( ) const

Returns the result of the upload.

The upload must be finished when calling this.


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