14 : _versions_db(url, use_url_as_local_path, download_callback), _keep_trying(true)
36 throw std::runtime_error(error_str);
39 bool update_available(
false);
44 auto &versions_vec((comp ==
FIRMWARE) ?
52 if (current_version < experimental_update.
ver)
54 versions_vec[experimental_update.
ver] = experimental_update;
55 update_available =
true;
62 if (current_version < recommened_update.
ver)
64 versions_vec[recommened_update.
ver] = recommened_update;
65 update_available =
true;
72 if (current_version < required_update.
ver)
74 versions_vec[required_update.
ver] = required_update;
75 update_available =
true;
81 return update_available;
93 auto query_status = up_handler.
query_versions(dev_name, part, policy, required_version);
99 result.
ver = required_version;
101 std::stringstream ss;
119 auto found = std::find_if( software_versions.begin(),
120 software_versions.end(),
121 [policy](
const version_to_info::value_type & ver_info ) {
122 return ver_info.second.policy == policy;
124 if( found != software_versions.end() )
126 info = found->second;
135 auto found = std::find_if( firmware_versions.begin(),
136 firmware_versions.end(),
137 [policy](
const version_to_info::value_type & ver_info ) {
138 return ver_info.second.policy == policy;
140 if( found != firmware_versions.end() )
142 info = found->second;
version_to_info firmware_versions
GLsizei const GLchar *const * string
bool get_version_description(const component_part_type component, const version &version, std::string &version_description)
sw_update::version firmware_version
def info(name, value, persistent=False)
version_to_info software_versions
const char * get_info(rs2_camera_info info) const
std::string serial_number
std::string to_string(const component_part_type &component)
versions_db_manager _versions_db
bool supports(rs2_camera_info info) const
std::string name_for_display
std::function< callback_result(uint64_t dl_current_bytes, uint64_t dl_total_bytes)> user_callback_func_type
bool get_version_download_link(const component_part_type component, const version &version, std::string &dl_link)
update_profile _update_profile
bool try_parse_update(versions_db_manager &up_handler, const std::string &dev_name, update_policy_type policy, component_part_type part, version_info &result)
update_policy_type policy
sw_update::version software_version
dev_updates_profile(const device &dev, const std::string &url, const bool use_url_as_local_path=false, http::user_callback_func_type download_callback=http::user_callback_func_type())
#define RS2_API_FULL_VERSION_STR
query_status_type query_versions(const std::string &device_name, component_part_type component, const update_policy_type policy, version &out_version)
std::string download_link
bool get_version_release_notes(const component_part_type component, const version &version, std::string &version_release_notes_link)
bool get_fw_update(update_policy_type policy, version_info &info) const
bool get_sw_update(update_policy_type policy, version_info &info) const
bool retrieve_updates(component_part_type comp)