[−][src]Struct ergo_node_interface::scanning::Scan
A Scan
is a name + scan_id for a given scan with extra methods for acquiring boxes.
Fields
name: String
id: ScanID
node_interface: NodeInterface
Implementations
impl Scan
[src]
pub fn new(name: &str, scan_id: &str, node_interface: &NodeInterface) -> Scan
[src]
Manually create a new Scan
struct. It is assumed that
a scan with the given id
has already been registered
with the Ergo Node and the developer is simply creating
a struct for the given scan.
pub fn register(
name: &String,
tracking_rule: JsonValue,
node_interface: &NodeInterface
) -> Result<Scan>
[src]
name: &String,
tracking_rule: JsonValue,
node_interface: &NodeInterface
) -> Result<Scan>
Register a new scan in the Ergo Node and builds/returns
a Scan
struct in a Result
.
pub fn get_boxes(&self) -> Result<Vec<ErgoBox>>
[src]
Returns all ErgoBox
es found by the scan
pub fn get_box(&self) -> Result<ErgoBox>
[src]
Returns the first ErgoBox
found by the scan
pub fn get_serialized_boxes(&self) -> Result<Vec<String>>
[src]
Returns all ErgoBox
es found by the scan
serialized and ready to be used as rawInputs
pub fn get_serialized_box(&self) -> Result<String>
[src]
Returns the first ErgoBox
found by the registered scan
serialized and ready to be used as a rawInput
pub fn save_scan_ids_locally(scans: Vec<Scan>) -> Result<bool>
[src]
Saves UTXO-set scans (specifically id) to local scanIDs.json
pub fn read_local_scan_ids(node: &NodeInterface) -> Result<Vec<Scan>>
[src]
Read UTXO-set scan ids from local scanIDs.json
pub fn serialize_p2pk_for_tracking(
node: &NodeInterface,
address: &P2PKAddressString
) -> Result<String>
[src]
node: &NodeInterface,
address: &P2PKAddressString
) -> Result<String>
Serialize a "P2PKAddressString" to be used within a scan tracking rule
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Scan
impl Send for Scan
impl Sync for Scan
impl Unpin for Scan
impl UnwindSafe for Scan
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,