Struct ethcore_rpc::SignerService
[−]
[src]
pub struct SignerService { /* fields omitted */ }
Manages communication with Signer crate
Methods
impl SignerService
[src]
fn new<F>(new_token: F, address: Option<(String, u16)>) -> Self where F: Fn() -> Result<String, String> + Send + Sync + 'static
Creates new Signer Service given function to generate new tokens.
fn is_valid_web_proxy_access_token(&self, token: &String) -> bool
Checks if the token is valid web proxy access token.
fn generate_web_proxy_access_token(&self) -> String
Generates a new web proxy access token.
fn generate_token(&self) -> Result<String, String>
Generates new signer authorization token.
fn queue(&self) -> Arc<ConfirmationsQueue>
Returns a reference to ConfirmationsQueue
fn address(&self) -> Option<(String, u16)>
Returns signer address (if signer enabled) or None
otherwise
fn is_enabled(&self) -> bool
Returns true if Signer is enabled.
Methods from Deref<Target=ConfirmationsQueue>
fn start_listening<F>(&self, listener: F) -> Result<(), QueueError> where F: Fn(QueueEvent) -> ()
Blocks the thread and starts listening for notifications regarding all actions in the queue.
For each event, listener
callback will be invoked.
This method can be used only once (only single consumer of events can exist).
fn finish(&self)
Notifies consumer that the communcation is over. No more events will be sent after this function is invoked.
Trait Implementations
impl Deref for SignerService
[src]
type Target = ConfirmationsQueue
The resulting type after dereferencing
fn deref(&self) -> &Self::Target
The method called to dereference a value