(rpc_path: PathBuf, promise_secret: &[u8; 32])
| 39 | |
| 40 | impl State { |
| 41 | pub fn new(rpc_path: PathBuf, promise_secret: &[u8; 32]) -> Self { |
| 42 | let api = Arc::new(ClnApiRpc::new(rpc_path.clone())); |
| 43 | let sender = ClnSender::new(rpc_path); |
| 44 | let lsps2_handler = Arc::new(Lsps2ServiceHandler::new(api, promise_secret)); |
| 45 | let lsps_service = Arc::new(LspsService::builder().with_protocol(lsps2_handler).build()); |
| 46 | Self { |
| 47 | lsps_service, |
| 48 | sender, |
| 49 | lsps2_enabled: true, |
| 50 | } |
| 51 | } |
| 52 | } |
| 53 | |
| 54 | impl ServiceState for State { |
nothing calls this directly
no test coverage detected