Struct bitcoin_qt::RPCConsole

source ·
pub struct RPCConsole { /* private fields */ }
Expand description

| Local Bitcoin RPC console. |

Implementations§

source§

impl RPCConsole

source

pub fn rpc_execute_command_line( node: Rc<RefCell<dyn NodeInterface>>, str_result: &mut String, str_command: &String, pstr_filtered_out: Option<*mut String>, wallet_model: Option<*const WalletModel> ) -> bool

source

pub fn tabs(&self) -> Vec<TabTypes>

source

pub fn message(&mut self, category: i32, msg: &String)

| Append the message to the message widget |

source

pub fn cmd_request( &mut self, command: &String, wallet_model: *const WalletModel )

| For RPC command executor |

source

pub fn time_duration_field(&self, time_now: u64, time_at_event: u64) -> String

| Helper for the output of a time duration | field. Inputs are UNIX epoch times. |

source

pub fn rpc_parse_command_line( &mut self, node: Rc<RefCell<dyn NodeInterface>>, str_result: &mut String, str_command: &String, execute: bool, pstr_filtered_out: *mut String, wallet_model: *const WalletModel ) -> bool

| Split shell command line into a list | of arguments and optionally execute | the command(s). | | Aims to emulate \c bash and friends. | | - Command nesting is possible with parenthesis; | for example: validateaddress(getnewaddress()) | | - Arguments are delimited with whitespace | or comma | | - Extra whitespace at the beginning | and end and between arguments will be | ignored | | - Text can be “double” or ‘single’ quoted | | - The backslash \c \ is used as escape | character | | - Outside quotes, any character can | be escaped | | - Within double quotes, only escape | \c “ and backslashes before a \c “ or another | backslash | | - Within single quotes, no escaping | is possible and no special interpretation | takes place | | ———– | @param[in] node | | optional node to execute command on | ––––– | @param[out] strResult | | stringified result from the executed | command(chain) | ––––– | @param[in] strCommand | | Command line to split | ––––– | @param[in] fExecute | | set true if you want the command to be | executed | ––––– | @param[out] pstrFilteredOut | | Command line, filtered to remove any | sensitive data |

source

pub fn new( node: Rc<RefCell<dyn NodeInterface>>, platform_style: &PlatformStyle, parent: *mut u32 ) -> Self

source

pub fn event_filter(&mut self, obj: *mut u32, event: *mut u32) -> bool

source

pub fn set_client_model( &mut self, model: *mut ClientModel, bestblock_height: Option<i32>, bestblock_date: Option<i64>, verification_progress: Option<f64> )

source

pub fn font_bigger(&mut self)

source

pub fn font_smaller(&mut self)

source

pub fn set_font_size(&mut self, new_size: i32)

source

pub fn clear(&mut self, keep_prompt: Option<bool>)

source

pub fn key_press_event(&mut self, event: *mut u32)

source

pub fn change_event(&mut self, e: *mut u32)

source

pub fn message_with_html(&mut self, category: i32, message: &String, html: bool)

source

pub fn update_network_state(&mut self)

| Update UI with latest network info from | model. |

source

pub fn set_num_connections(&mut self, count: i32)

| Set number of connections shown in the | UI |

source

pub fn set_network_active(&mut self, network_active: bool)

| Set network state shown in the UI |

source

pub fn set_num_blocks( &mut self, count: i32, block_date: &u32, n_verification_progress: f64, headers: bool )

| Set number of blocks and last block date | shown in the UI |

source

pub fn set_mempool_size(&mut self, number_of_txs: i64, dyn_usage: usize)

| Set size (number of transactions and | memory usage) of the mempool in the UI |

source

pub fn on_line_edit_return_pressed(&mut self)

source

pub fn browse_history(&mut self, offset: i32)

| Go forward or back in history |

source

pub fn start_executor(&mut self)

source

pub fn on_tab_widget_current_changed(&mut self, index: i32)

source

pub fn on_open_debug_logfile_button_clicked(&mut self)

| open the debug.log from the current | datadir |

source

pub fn scroll_to_end(&mut self)

| Scroll console view to end |

source

pub fn on_sld_graph_range_value_changed(&mut self, value: i32)

| change the time range of the network | traffic graph |

source

pub fn set_traffic_graph_range(&mut self, mins: i32)

source

pub fn update_traffic_stats( &mut self, total_bytes_in: u64, total_bytes_out: u64 )

| update traffic statistics |

source

pub fn update_detail_widget(&mut self)

| show detailed information on ui about | selected node |

source

pub fn resize_event(&mut self, event: *mut u32)

source

pub fn show_event(&mut self, event: *mut u32)

source

pub fn hide_event(&mut self, event: *mut u32)

source

pub fn show_peers_table_context_menu(&mut self, point: &u32)

| Show custom context menu on Peers tab |

source

pub fn show_ban_table_context_menu(&mut self, point: &u32)

| Show custom context menu on Bans tab |

source

pub fn disconnect_selected_node(&mut self)

| Disconnect a selected node on the Peers | tab |

source

pub fn ban_selected_node(&mut self, bantime: i32)

| Ban a selected node on the Peers tab |

source

pub fn unban_selected_node(&mut self)

| Unban a selected node on the Bans tab |

source

pub fn clear_selected_node(&mut self)

| clear the selected node |

source

pub fn show_or_hide_ban_table_if_required(&mut self)

| Hides ban table if no bans are present |

source

pub fn set_tab_focus(&mut self, tab_type: TabTypes)

| set which tab has the focus (is visible) |

source

pub fn tab_title(&self, tab_type: TabTypes) -> String

source

pub fn tab_shortcut(&self, tab_type: TabTypes) -> u32

source

pub fn update_alerts(&mut self, warnings: &String)

Trait Implementations§

source§

impl Drop for RPCConsole

source§

fn drop(&mut self)

Executes the destructor for this type. Read more
source§

impl EventFilter for RPCConsole

source§

fn event_filter(&mut self, obj: *mut u32, event: *mut u32) -> bool

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

const: unstable · source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

const: unstable · source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<T, U> CastInto<U> for Twhere U: CastFrom<T>,

§

unsafe fn cast_into(self) -> U

Performs the conversion. Read more
source§

impl<T> From<T> for T

const: unstable · source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere U: From<T>,

const: unstable · source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<T> Pointable for T

§

const ALIGN: usize = mem::align_of::<T>()

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
§

impl<T> StaticUpcast<T> for T

§

unsafe fn static_upcast(ptr: Ptr<T>) -> Ptr<T>

Convert type of a const pointer. Read more
source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
const: unstable · source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
const: unstable · source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for Twhere V: MultiLane<T>,

§

fn vzip(self) -> V