Friendly LWM2M client
wpp::FwUpdater Class Referenceabstract

#include <FwUpdater.h>

+ Collaboration diagram for wpp::FwUpdater:

Public Member Functions

 FwUpdater ()=default
 
virtual ~FwUpdater ()=default
 
virtual void startUpdating ()=0
 Request to start updating the firmware. For notify that the update is completed, isUpdated() method should return true. For notify update result, lastUpdateResult() method should return the result of the update process. More...
 
virtual bool isUpdated ()=0
 Returns true if the update process is completed. For notify update result, lastUpdateResult() method should return the result of the update process. Regardless of the reason for the termination, whether it is a complete firmware update or a update error. More...
 
virtual FwUpdRes lastUpdateResult ()=0
 Contains the result of the last update process. This method is called whenever the FwExternalDl is registered to get information about the result of the last update. If there were no updates, the method should return R_INITIAL Possible results when update is successful: R_INITIAL, R_FW_UPD_SUCCESS Possible results when error occured: R_FW_UPD_FAIL, R_INTEGRITY_CHECK_FAIL. More...
 
virtual void reset ()=0
 Returns the name and version of the last installed firmware package. These methods return the value of the last working firmware. If the update process was unsuccessful, these methods should return the value of the previous firmware. They can be called regardless of the state of the Downloader. Calling reset() does not affect the value they return. The returned value always corresponds to the version and name of the last successfully installed package. More...
 

Detailed Description

Definition at line 8 of file FwUpdater.h.

Constructor & Destructor Documentation

◆ FwUpdater()

wpp::FwUpdater::FwUpdater ( )
default

◆ ~FwUpdater()

virtual wpp::FwUpdater::~FwUpdater ( )
virtualdefault

Member Function Documentation

◆ isUpdated()

virtual bool wpp::FwUpdater::isUpdated ( )
pure virtual

Returns true if the update process is completed. For notify update result, lastUpdateResult() method should return the result of the update process. Regardless of the reason for the termination, whether it is a complete firmware update or a update error.

◆ lastUpdateResult()

virtual FwUpdRes wpp::FwUpdater::lastUpdateResult ( )
pure virtual

Contains the result of the last update process. This method is called whenever the FwExternalDl is registered to get information about the result of the last update. If there were no updates, the method should return R_INITIAL Possible results when update is successful: R_INITIAL, R_FW_UPD_SUCCESS Possible results when error occured: R_FW_UPD_FAIL, R_INTEGRITY_CHECK_FAIL.

+ Here is the caller graph for this function:

◆ reset()

virtual void wpp::FwUpdater::reset ( )
pure virtual

Returns the name and version of the last installed firmware package. These methods return the value of the last working firmware. If the update process was unsuccessful, these methods should return the value of the previous firmware. They can be called regardless of the state of the Downloader. Calling reset() does not affect the value they return. The returned value always corresponds to the version and name of the last successfully installed package.

Reset the update process. This methos can not be called when the updeate process is started. All the information about the previous updating process is cleared. So lastUpdateResult() should return R_INITIAL.

◆ startUpdating()

virtual void wpp::FwUpdater::startUpdating ( )
pure virtual

Request to start updating the firmware. For notify that the update is completed, isUpdated() method should return true. For notify update result, lastUpdateResult() method should return the result of the update process.