1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
pub mod errors;
mod instructions;
pub mod state;
use {anchor_lang::prelude::*, instructions::*, state::*};
declare_id!("EikDpw2iRwqMrDwGBxAdbdfVAURkvDajZLWrFoYc2dc5");
#[program]
pub mod cronos {
use super::*;
pub fn admin_create_daemon(
ctx: Context<AdminCreateDaemon>,
daemon_bump: u8,
fee_bump: u8,
) -> ProgramResult {
admin_create_daemon::handler(ctx, daemon_bump, fee_bump)
}
pub fn admin_schedule_health_check(
ctx: Context<AdminScheduleHealthCheck>,
bump: u8,
) -> ProgramResult {
admin_schedule_health_check::handler(ctx, bump)
}
pub fn config_update_admin(
ctx: Context<ConfigUpdateAdmin>,
new_admin: Pubkey,
) -> ProgramResult {
config_update_admin::handler(ctx, new_admin)
}
pub fn config_update_program_fee(
ctx: Context<ConfigUpdateProgramFee>,
new_program_fee: u64,
) -> ProgramResult {
config_update_program_fee::handler(ctx, new_program_fee)
}
pub fn config_update_worker_fee(
ctx: Context<ConfigUpdateWorkerFee>,
new_worker_fee: u64,
) -> ProgramResult {
config_update_worker_fee::handler(ctx, new_worker_fee)
}
pub fn daemon_create(
ctx: Context<DaemonCreate>,
daemon_bump: u8,
fee_bump: u8,
) -> ProgramResult {
daemon_create::handler(ctx, daemon_bump, fee_bump)
}
pub fn daemon_invoke(
ctx: Context<DaemonInvoke>,
instruction_data: InstructionData,
) -> ProgramResult {
daemon_invoke::handler(ctx, instruction_data)
}
pub fn fee_collect(ctx: Context<FeeCollect>) -> ProgramResult {
fee_collect::handler(ctx)
}
pub fn initialize(
ctx: Context<Initialize>,
authority_bump: u8,
config_bump: u8,
health_bump: u8,
treasury_bump: u8,
) -> ProgramResult {
initialize::handler(ctx, authority_bump, config_bump, health_bump, treasury_bump)
}
pub fn health_check(ctx: Context<HealthCheck>) -> ProgramResult {
health_check::handler(ctx)
}
pub fn task_cancel(ctx: Context<TaskCancel>) -> ProgramResult {
task_cancel::handler(ctx)
}
pub fn task_create(
ctx: Context<TaskCreate>,
instruction_data: InstructionData,
execute_at: u64,
repeat_every: u64,
repeat_until: u64,
bump: u8,
) -> ProgramResult {
task_create::handler(
ctx,
instruction_data,
execute_at,
repeat_every,
repeat_until,
bump,
)
}
pub fn task_execute(ctx: Context<TaskProcess>) -> ProgramResult {
task_execute::handler(ctx)
}
}