Open Search
    ProgressMonitorInterface Class Reference

    #include <progressmonitor.h>

    Inheritance diagram for ProgressMonitorInterface:

    Detailed Description

    Allows to be informed during time-intensive source control operations such as file sync. The monitor is called frequently during the operation.

    Public Member Functions

    MAXON_METHOD Result< void > Initialize (const String &command, const ArrayInterface< String > &arguments)
     
    MAXON_METHOD Result< void > TotalBytesToProcess (UInt bytes)
     
    MAXON_METHOD Result< void > FinishedBytesToProcess (UInt bytes)
     
    MAXON_METHOD Result< void > Finalize ()
     

    Private Member Functions

     MAXON_INTERFACE (ProgressMonitorInterface, MAXON_REFERENCE_NORMAL, "net.maxon.misc.interface.progressmonitor")
     

    Member Function Documentation

    ◆ MAXON_INTERFACE()

    MAXON_INTERFACE ( ProgressMonitorInterface  ,
    MAXON_REFERENCE_NORMAL  ,
    "net.maxon.misc.interface.progressmonitor"   
    )
    private

    ◆ Initialize()

    MAXON_METHOD Result<void> Initialize ( const String command,
    const ArrayInterface< String > &  arguments 
    )

    Called before the source control operation.

    Parameters
    [in]commandThe command string of the operation.
    [in]argumentsThe set of arguments used with the command.
    Returns
    OK on success.

    ◆ TotalBytesToProcess()

    MAXON_METHOD Result<void> TotalBytesToProcess ( UInt  bytes)

    Called once for the command. Note that this function might not be executed at all, or is executed after the operation is already progressing, such as a a download being partially complete, which is indicated by a call to FinishedBytesToProcess() before calling TotalBytesToProcess().

    Parameters
    [in]bytesThe total number of bytes for the operation.
    Returns
    OK on success.

    ◆ FinishedBytesToProcess()

    MAXON_METHOD Result<void> FinishedBytesToProcess ( UInt  bytes)

    Called frequently, multiple times during the operation. Note that this function might not be executed at all. The sum of all reported finished bytes equals the total amount of bytes for a successful operation.

    Parameters
    [in]bytesThe number of progress in bytes since the last call to TotalBytesToProcess().
    Returns
    OK on success.

    ◆ Finalize()

    MAXON_METHOD Result<void> Finalize ( )

    This method is called after the source control operation terminated successfully.

    Returns
    OK on success.