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
use super::output_request::*;
use crate::base::*;
use cyfs_base::*;
use std::path::PathBuf;

pub struct UtilInputRequestCommon {
    // 请求路径,可为空
    pub req_path: Option<String>,

    pub source: RequestSourceInfo,

    // 用以默认行为
    pub target: Option<ObjectId>,

    pub flags: u32,
}

// get device
pub struct UtilGetDeviceInputRequest {
    pub common: UtilInputRequestCommon,
}

pub type UtilGetDeviceInputResponse = UtilGetDeviceOutputResponse;

// get zone
pub struct UtilGetZoneInputRequest {
    pub common: UtilInputRequestCommon,

    pub object_id: Option<ObjectId>,
    pub object_raw: Option<Vec<u8>>,
}

pub type UtilGetZoneInputResponse = UtilGetZoneOutputResponse;

// resolve_ood
pub struct UtilResolveOODInputRequest {
    pub common: UtilInputRequestCommon,

    pub object_id: ObjectId,
    pub owner_id: Option<ObjectId>,
}

pub type UtilResolveOODInputResponse = UtilResolveOODOutputResponse;

// get_ood_status
pub struct UtilGetOODStatusInputRequest {
    pub common: UtilInputRequestCommon,
}

pub type UtilGetOODStatusInputResponse = UtilGetOODStatusOutputResponse;

// get_noc_stat
pub struct UtilGetNOCInfoInputRequest {
    pub common: UtilInputRequestCommon,
}

pub type UtilGetNOCInfoInputResponse = UtilGetNOCInfoOutputResponse;

// get_device_static_info
pub struct UtilGetDeviceStaticInfoInputRequest {
    pub common: UtilInputRequestCommon,
}

pub type UtilGetDeviceStaticInfoInputResponse = UtilGetDeviceStaticInfoOutputResponse;

// get_network_access_info
pub struct UtilGetNetworkAccessInfoInputRequest {
    pub common: UtilInputRequestCommon,
}

pub type UtilGetNetworkAccessInfoInputResponse = UtilGetNetworkAccessInfoOutputResponse;

// get_system_info
pub struct UtilGetSystemInfoInputRequest {
    pub common: UtilInputRequestCommon,
}

pub type UtilGetSystemInfoInputResponse = UtilGetSystemInfoOutputResponse;

// get_version_info
pub struct UtilGetVersionInfoInputRequest {
    pub common: UtilInputRequestCommon,
}

pub type UtilGetVersionInfoInputResponse = UtilGetVersionInfoOutputResponse;

pub struct UtilBuildFileInputRequest {
    pub common: UtilInputRequestCommon,
    pub local_path: PathBuf,
    pub owner: ObjectId,
    pub chunk_size: u32,
}

pub type UtilBuildFileInputResponse = UtilBuildFileOutputResponse;

pub struct UtilBuildDirFromObjectMapInputRequest {
    pub common: UtilInputRequestCommon,
    pub object_map_id: ObjectId,
    pub dir_type: BuildDirType,
}

pub type UtilBuildDirFromObjectMapInputResponse = UtilBuildDirFromObjectMapOutputResponse;