use crate::events::{RoundId, Timestamp}; multiversx_sc::imports!(); multiversx_sc::derive_imports!(); #[type_abi] #[derive(NestedEncode, NestedDecode, TopEncode, TopDecode, Clone)] pub struct TokenPair { pub from: ManagedBuffer, pub to: ManagedBuffer, } #[type_abi] #[derive(NestedEncode, NestedDecode, TopEncode, TopDecode)] pub struct PriceFeed { pub round_id: RoundId, pub from: ManagedBuffer, pub to: ManagedBuffer, pub timestamp: Timestamp, pub price: BigUint, pub decimals: u8, } #[type_abi] #[derive(TopEncode, TopDecode, Debug, PartialEq, Eq)] pub struct TimestampedPrice { pub price: BigUint, pub timestamp: Timestamp, pub decimals: u8, } #[type_abi] #[derive(NestedEncode, NestedDecode, TopEncode, TopDecode, Debug, PartialEq, Eq)] pub struct OracleStatus { pub accepted_submissions: u64, pub total_submissions: u64, }