Trait dlc_manager::Oracle

source ·
pub trait Oracle {
    // Required methods
    fn get_public_key(&self) -> XOnlyPublicKey;
    fn get_announcement(
&self,
event_id: &str
) -> Result<OracleAnnouncement, Error>; fn get_attestation(&self, event_id: &str) -> Result<OracleAttestation, Error>; }
Expand description

Oracle trait provides access to oracle information.

Required Methods§

source

fn get_public_key(&self) -> XOnlyPublicKey

Returns the public key of the oracle.

source

fn get_announcement(&self, event_id: &str) -> Result<OracleAnnouncement, Error>

Returns the announcement for the event with the given id if found.

source

fn get_attestation(&self, event_id: &str) -> Result<OracleAttestation, Error>

Returns the attestation for the event with the given id if found.

Implementors§