dap_reactor/models/
attach.rs1use super::*;
2
3#[derive(Debug, Clone, PartialEq, Eq)]
4pub struct AttachArguments {
5 pub restart: Option<Value>,
6}
7
8impl From<AttachArguments> for Value {
9 fn from(args: AttachArguments) -> Self {
10 let AttachArguments { restart } = args;
11
12 let restart = utils::attribute_optional("__restart", restart);
13
14 utils::finalize_object(restart)
15 }
16}
17
18impl From<&Map<String, Value>> for AttachArguments {
19 fn from(map: &Map<String, Value>) -> Self {
20 let restart = utils::get_optional(map, "__restart");
21
22 Self { restart }
23 }
24}