Trait SettingSystemServiceSyncHandler

Source
pub trait SettingSystemServiceSyncHandler {
Show 31 methods // Required methods fn handle_get_setting_item(&self, id: String) -> Result<SettingItem>; fn handle_get_setting_items( &self, category: String, include_children: bool, ) -> Result<Vec<SettingItem>>; fn handle_search_setting_items( &self, filter_json: String, ) -> Result<BTreeMap<String, SettingSearchResult>>; fn handle_get_category_node(&self) -> Result<SettingTree>; fn handle_get_child_node( &self, parent: String, node_type: NodeType, param: String, tags: Vec<String>, ) -> Result<NodeList>; fn handle_set_setting_item(&self, key: String, val: String) -> Result<bool>; fn handle_set_setting_items( &self, key_values: BTreeMap<String, String>, ) -> Result<i32>; fn handle_restore_default( &self, module_name: String, category: String, ) -> Result<bool>; fn handle_restore_user_default( &self, user_id: String, module_name: String, category: String, ) -> Result<bool>; fn handle_update_module_version(&self, module_name: String) -> Result<bool>; fn handle_set_user_app_data( &self, user_id: String, category: String, setting_items: BTreeMap<String, SettingValue>, ) -> Result<i32>; fn handle_get_user_app_data( &self, user_id: String, category: String, setting_keys: Vec<String>, ) -> Result<AppData>; fn handle_remove_user_app_data( &self, user_id: String, category: String, setting_keys: Vec<String>, ) -> Result<i32>; fn handle_setting_item_notify( &self, key: String, contents: JSON, ) -> Result<bool>; fn handle_get_network_adapter_settings(&self) -> Result<NetworkSettings>; fn handle_get_lan_network_name(&self) -> Result<String>; fn handle_set_network_settings( &self, is_w_lan: bool, enable_d_h_c_p: bool, ip_address: String, sub_mask: String, gateway: String, main_d_n_s: String, sub_d_n_s: String, ) -> Result<bool>; fn handle_set_network_proxy( &self, proxy_server: String, proxy_port: String, ) -> Result<bool>; fn handle_connect_to_wifi( &self, profile_name: String, key: String, ) -> Result<bool>; fn handle_connect_to_appointed_wifi( &self, profile_name: String, auth: String, ciper: String, key_type: String, key: String, ) -> Result<bool>; fn handle_get_network_settings(&self) -> Result<RuyiNetworkSettings>; fn handle_get_network_status(&self) -> Result<RuyiNetworkStatus>; fn handle_ruyi_test_network(&self) -> Result<RuyiNetworkTestResult>; fn handle_ruyi_start_network_speed_test( &self, userindex: i32, ) -> Result<bool>; fn handle_ruyi_stop_network_speed_test( &self, userindex: i32, ) -> Result<bool>; fn handle_get_available_wifi(&self) -> Result<Vec<WifiEntity>>; fn handle_disconnect_wifi(&self) -> Result<bool>; fn handle_discover_bluetooth_device(&self) -> Result<bool>; fn handle_connect_bluetooth_device( &self, device_name: String, device_address: String, ) -> Result<bool>; fn handle_disconnect_bluetooth_device( &self, device_name: String, device_address: String, ) -> Result<bool>; fn handle_remove_bluetooth_device( &self, device_name: String, device_address: String, ) -> Result<bool>;
}

Required Methods§

Source

fn handle_get_setting_item(&self, id: String) -> Result<SettingItem>

Get a setting data of the module.

Source

fn handle_get_setting_items( &self, category: String, include_children: bool, ) -> Result<Vec<SettingItem>>

Get a list of setting data of the module.

Source

fn handle_search_setting_items( &self, filter_json: String, ) -> Result<BTreeMap<String, SettingSearchResult>>

Search a set of settings using a json format string. According to the format of json string your write, searching can be separated to 3 types: simple search, lambda search and complicated search. And each of they can be combined with the other.

Source

fn handle_get_category_node(&self) -> Result<SettingTree>

Get settings and categories in a tree

Source

fn handle_get_child_node( &self, parent: String, node_type: NodeType, param: String, tags: Vec<String>, ) -> Result<NodeList>

Get child nodes of specified setting item or setting category

Source

fn handle_set_setting_item(&self, key: String, val: String) -> Result<bool>

Set the specified setting’s “dataValue” with the new value

Source

fn handle_set_setting_items( &self, key_values: BTreeMap<String, String>, ) -> Result<i32>

Set a set of settings’ “dataValue”

Source

fn handle_restore_default( &self, module_name: String, category: String, ) -> Result<bool>

Restore a module setting to default

Source

fn handle_restore_user_default( &self, user_id: String, module_name: String, category: String, ) -> Result<bool>

@RestoreUserDefault_Summary

Source

fn handle_update_module_version(&self, module_name: String) -> Result<bool>

Update the module settings from an older version to the latest one

Source

fn handle_set_user_app_data( &self, user_id: String, category: String, setting_items: BTreeMap<String, SettingValue>, ) -> Result<i32>

@SetUserAppData_Summary

Source

fn handle_get_user_app_data( &self, user_id: String, category: String, setting_keys: Vec<String>, ) -> Result<AppData>

@GetUserAppData_Summary

Source

fn handle_remove_user_app_data( &self, user_id: String, category: String, setting_keys: Vec<String>, ) -> Result<i32>

@RemoveUserAppData_Summary

Source

fn handle_setting_item_notify( &self, key: String, contents: JSON, ) -> Result<bool>

Notify layer0 that a setting item has specific event

Source

fn handle_get_network_adapter_settings(&self) -> Result<NetworkSettings>

Source

fn handle_get_lan_network_name(&self) -> Result<String>

Source

fn handle_set_network_settings( &self, is_w_lan: bool, enable_d_h_c_p: bool, ip_address: String, sub_mask: String, gateway: String, main_d_n_s: String, sub_d_n_s: String, ) -> Result<bool>

Source

fn handle_set_network_proxy( &self, proxy_server: String, proxy_port: String, ) -> Result<bool>

Source

fn handle_connect_to_wifi( &self, profile_name: String, key: String, ) -> Result<bool>

Source

fn handle_connect_to_appointed_wifi( &self, profile_name: String, auth: String, ciper: String, key_type: String, key: String, ) -> Result<bool>

Source

fn handle_get_network_settings(&self) -> Result<RuyiNetworkSettings>

Source

fn handle_get_network_status(&self) -> Result<RuyiNetworkStatus>

Source

fn handle_ruyi_test_network(&self) -> Result<RuyiNetworkTestResult>

Source

fn handle_ruyi_start_network_speed_test(&self, userindex: i32) -> Result<bool>

Source

fn handle_ruyi_stop_network_speed_test(&self, userindex: i32) -> Result<bool>

Source

fn handle_get_available_wifi(&self) -> Result<Vec<WifiEntity>>

Source

fn handle_disconnect_wifi(&self) -> Result<bool>

Source

fn handle_discover_bluetooth_device(&self) -> Result<bool>

Source

fn handle_connect_bluetooth_device( &self, device_name: String, device_address: String, ) -> Result<bool>

Source

fn handle_disconnect_bluetooth_device( &self, device_name: String, device_address: String, ) -> Result<bool>

Source

fn handle_remove_bluetooth_device( &self, device_name: String, device_address: String, ) -> Result<bool>

Implementors§