Better stuff

This commit is contained in:
2026-08-06 07:42:08 +02:00
parent 480bd679b0
commit 5be80214fc
4 changed files with 75 additions and 8 deletions
+12 -7
View File
@@ -1,15 +1,10 @@
pub mod pump_fun;
use rust_decimal::Decimal;
use serde::{Deserialize, Serialize};
use tokio::sync::Mutex;
use crate::executor::pump_fun::PumpDevAccount;
use crate::account::Account;
#[derive(Debug, Clone, Serialize, Deserialize)]
#[serde(tag = "type")]
pub enum Account {
PumpDev(PumpDevAccount),
}
#[allow(async_fn_in_trait, unused_variables)]
pub trait Executor {
@@ -33,3 +28,13 @@ pub trait Executor {
Ok(())
}
}
impl Account {
pub fn executor(self) -> impl Executor {
match self {
Self::PumpDev(account) => pump_fun::PumpDev {
account: Mutex::new(account),
},
}
}
}