]> git.proxmox.com Git - rustc.git/blame - vendor/windows-sys/src/Windows/Win32/NetworkManagement/WindowsConnectionManager/mod.rs
New upstream version 1.67.1+dfsg1
[rustc.git] / vendor / windows-sys / src / Windows / Win32 / NetworkManagement / WindowsConnectionManager / mod.rs
CommitLineData
487cf647 1#[cfg_attr(windows, link(name = "windows"))]
5e7ed085 2extern "system" {
04454e1e 3 #[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`, `\"Win32_Foundation\"`*"]
5e7ed085
FG
4 #[cfg(feature = "Win32_Foundation")]
5 pub fn FreeInterfaceContextTable(interfacecontexttable: *const NET_INTERFACE_CONTEXT_TABLE);
04454e1e 6 #[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`, `\"Win32_Foundation\"`*"]
5e7ed085 7 #[cfg(feature = "Win32_Foundation")]
04454e1e
FG
8 pub fn GetInterfaceContextTableForHostName(hostname: ::windows_sys::core::PCWSTR, proxyname: ::windows_sys::core::PCWSTR, flags: u32, connectionprofilefilterrawdata: *const u8, connectionprofilefilterrawdatasize: u32, interfacecontexttable: *mut *mut NET_INTERFACE_CONTEXT_TABLE) -> ::windows_sys::core::HRESULT;
9 #[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
10 pub fn OnDemandGetRoutingHint(destinationhostname: ::windows_sys::core::PCWSTR, interfaceindex: *mut u32) -> ::windows_sys::core::HRESULT;
11 #[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`, `\"Win32_Foundation\"`*"]
5e7ed085
FG
12 #[cfg(feature = "Win32_Foundation")]
13 pub fn OnDemandRegisterNotification(callback: ONDEMAND_NOTIFICATION_CALLBACK, callbackcontext: *const ::core::ffi::c_void, registrationhandle: *mut super::super::Foundation::HANDLE) -> ::windows_sys::core::HRESULT;
04454e1e 14 #[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`, `\"Win32_Foundation\"`*"]
5e7ed085
FG
15 #[cfg(feature = "Win32_Foundation")]
16 pub fn OnDemandUnRegisterNotification(registrationhandle: super::super::Foundation::HANDLE) -> ::windows_sys::core::HRESULT;
04454e1e 17 #[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
5e7ed085 18 pub fn WcmFreeMemory(pmemory: *mut ::core::ffi::c_void);
04454e1e 19 #[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
5e7ed085 20 pub fn WcmGetProfileList(preserved: *mut ::core::ffi::c_void, ppprofilelist: *mut *mut WCM_PROFILE_INFO_LIST) -> u32;
04454e1e
FG
21 #[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
22 pub fn WcmQueryProperty(pinterface: *const ::windows_sys::core::GUID, strprofilename: ::windows_sys::core::PCWSTR, property: WCM_PROPERTY, preserved: *mut ::core::ffi::c_void, pdwdatasize: *mut u32, ppdata: *mut *mut u8) -> u32;
23 #[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`, `\"Win32_Foundation\"`*"]
5e7ed085
FG
24 #[cfg(feature = "Win32_Foundation")]
25 pub fn WcmSetProfileList(pprofilelist: *const WCM_PROFILE_INFO_LIST, dwposition: u32, fignoreunknownprofiles: super::super::Foundation::BOOL, preserved: *mut ::core::ffi::c_void) -> u32;
04454e1e
FG
26 #[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
27 pub fn WcmSetProperty(pinterface: *const ::windows_sys::core::GUID, strprofilename: ::windows_sys::core::PCWSTR, property: WCM_PROPERTY, preserved: *mut ::core::ffi::c_void, dwdatasize: u32, pbdata: *const u8) -> u32;
5e7ed085 28}
487cf647
FG
29#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
30pub const NET_INTERFACE_FLAG_CONNECT_IF_NEEDED: u32 = 1u32;
31#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
32pub const NET_INTERFACE_FLAG_NONE: u32 = 0u32;
33#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
34pub const WCM_API_VERSION: u32 = 1u32;
35#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
36pub const WCM_API_VERSION_1_0: u32 = 1u32;
37#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
38pub const WCM_MAX_PROFILE_NAME: u32 = 256u32;
39#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
40pub const WCM_UNKNOWN_DATAPLAN_STATUS: u32 = 4294967295u32;
41#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
42pub type WCM_CONNECTION_COST = i32;
43#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
44pub const WCM_CONNECTION_COST_UNKNOWN: WCM_CONNECTION_COST = 0i32;
45#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
46pub const WCM_CONNECTION_COST_UNRESTRICTED: WCM_CONNECTION_COST = 1i32;
47#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
48pub const WCM_CONNECTION_COST_FIXED: WCM_CONNECTION_COST = 2i32;
49#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
50pub const WCM_CONNECTION_COST_VARIABLE: WCM_CONNECTION_COST = 4i32;
51#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
52pub const WCM_CONNECTION_COST_OVERDATALIMIT: WCM_CONNECTION_COST = 65536i32;
53#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
54pub const WCM_CONNECTION_COST_CONGESTED: WCM_CONNECTION_COST = 131072i32;
55#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
56pub const WCM_CONNECTION_COST_ROAMING: WCM_CONNECTION_COST = 262144i32;
57#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
58pub const WCM_CONNECTION_COST_APPROACHINGDATALIMIT: WCM_CONNECTION_COST = 524288i32;
59#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
60pub type WCM_CONNECTION_COST_SOURCE = i32;
61#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
62pub const WCM_CONNECTION_COST_SOURCE_DEFAULT: WCM_CONNECTION_COST_SOURCE = 0i32;
63#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
64pub const WCM_CONNECTION_COST_SOURCE_GP: WCM_CONNECTION_COST_SOURCE = 1i32;
65#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
66pub const WCM_CONNECTION_COST_SOURCE_USER: WCM_CONNECTION_COST_SOURCE = 2i32;
67#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
68pub const WCM_CONNECTION_COST_SOURCE_OPERATOR: WCM_CONNECTION_COST_SOURCE = 3i32;
69#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
70pub type WCM_MEDIA_TYPE = i32;
71#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
72pub const wcm_media_unknown: WCM_MEDIA_TYPE = 0i32;
73#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
74pub const wcm_media_ethernet: WCM_MEDIA_TYPE = 1i32;
75#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
76pub const wcm_media_wlan: WCM_MEDIA_TYPE = 2i32;
77#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
78pub const wcm_media_mbn: WCM_MEDIA_TYPE = 3i32;
79#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
80pub const wcm_media_invalid: WCM_MEDIA_TYPE = 4i32;
81#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
82pub const wcm_media_max: WCM_MEDIA_TYPE = 5i32;
83#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
84pub type WCM_PROPERTY = i32;
85#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
86pub const wcm_global_property_domain_policy: WCM_PROPERTY = 0i32;
87#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
88pub const wcm_global_property_minimize_policy: WCM_PROPERTY = 1i32;
89#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
90pub const wcm_global_property_roaming_policy: WCM_PROPERTY = 2i32;
91#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
92pub const wcm_global_property_powermanagement_policy: WCM_PROPERTY = 3i32;
93#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
94pub const wcm_intf_property_connection_cost: WCM_PROPERTY = 4i32;
95#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
96pub const wcm_intf_property_dataplan_status: WCM_PROPERTY = 5i32;
97#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
98pub const wcm_intf_property_hotspot_profile: WCM_PROPERTY = 6i32;
5e7ed085 99#[repr(C)]
04454e1e 100#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
5e7ed085
FG
101pub struct NET_INTERFACE_CONTEXT {
102 pub InterfaceIndex: u32,
04454e1e 103 pub ConfigurationName: ::windows_sys::core::PWSTR,
5e7ed085 104}
5e7ed085 105impl ::core::marker::Copy for NET_INTERFACE_CONTEXT {}
5e7ed085
FG
106impl ::core::clone::Clone for NET_INTERFACE_CONTEXT {
107 fn clone(&self) -> Self {
108 *self
109 }
110}
111#[repr(C)]
04454e1e 112#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`, `\"Win32_Foundation\"`*"]
5e7ed085
FG
113#[cfg(feature = "Win32_Foundation")]
114pub struct NET_INTERFACE_CONTEXT_TABLE {
115 pub InterfaceContextHandle: super::super::Foundation::HANDLE,
116 pub NumberOfEntries: u32,
117 pub InterfaceContextArray: *mut NET_INTERFACE_CONTEXT,
118}
119#[cfg(feature = "Win32_Foundation")]
120impl ::core::marker::Copy for NET_INTERFACE_CONTEXT_TABLE {}
121#[cfg(feature = "Win32_Foundation")]
122impl ::core::clone::Clone for NET_INTERFACE_CONTEXT_TABLE {
123 fn clone(&self) -> Self {
124 *self
125 }
126}
5e7ed085 127#[repr(C)]
04454e1e 128#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`, `\"Win32_Foundation\"`*"]
5e7ed085
FG
129#[cfg(feature = "Win32_Foundation")]
130pub struct WCM_BILLING_CYCLE_INFO {
131 pub StartDate: super::super::Foundation::FILETIME,
132 pub Duration: WCM_TIME_INTERVAL,
133 pub Reset: super::super::Foundation::BOOL,
134}
135#[cfg(feature = "Win32_Foundation")]
136impl ::core::marker::Copy for WCM_BILLING_CYCLE_INFO {}
137#[cfg(feature = "Win32_Foundation")]
138impl ::core::clone::Clone for WCM_BILLING_CYCLE_INFO {
139 fn clone(&self) -> Self {
140 *self
141 }
142}
5e7ed085 143#[repr(C)]
04454e1e 144#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
5e7ed085
FG
145pub struct WCM_CONNECTION_COST_DATA {
146 pub ConnectionCost: u32,
147 pub CostSource: WCM_CONNECTION_COST_SOURCE,
148}
149impl ::core::marker::Copy for WCM_CONNECTION_COST_DATA {}
150impl ::core::clone::Clone for WCM_CONNECTION_COST_DATA {
151 fn clone(&self) -> Self {
152 *self
153 }
154}
5e7ed085 155#[repr(C)]
04454e1e 156#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`, `\"Win32_Foundation\"`*"]
5e7ed085
FG
157#[cfg(feature = "Win32_Foundation")]
158pub struct WCM_DATAPLAN_STATUS {
159 pub UsageData: WCM_USAGE_DATA,
160 pub DataLimitInMegabytes: u32,
161 pub InboundBandwidthInKbps: u32,
162 pub OutboundBandwidthInKbps: u32,
163 pub BillingCycle: WCM_BILLING_CYCLE_INFO,
164 pub MaxTransferSizeInMegabytes: u32,
165 pub Reserved: u32,
166}
167#[cfg(feature = "Win32_Foundation")]
168impl ::core::marker::Copy for WCM_DATAPLAN_STATUS {}
169#[cfg(feature = "Win32_Foundation")]
170impl ::core::clone::Clone for WCM_DATAPLAN_STATUS {
171 fn clone(&self) -> Self {
172 *self
173 }
174}
5e7ed085 175#[repr(C)]
04454e1e 176#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`, `\"Win32_Foundation\"`*"]
5e7ed085
FG
177#[cfg(feature = "Win32_Foundation")]
178pub struct WCM_POLICY_VALUE {
179 pub fValue: super::super::Foundation::BOOL,
180 pub fIsGroupPolicy: super::super::Foundation::BOOL,
181}
182#[cfg(feature = "Win32_Foundation")]
183impl ::core::marker::Copy for WCM_POLICY_VALUE {}
184#[cfg(feature = "Win32_Foundation")]
185impl ::core::clone::Clone for WCM_POLICY_VALUE {
186 fn clone(&self) -> Self {
187 *self
188 }
189}
190#[repr(C)]
04454e1e 191#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
5e7ed085
FG
192pub struct WCM_PROFILE_INFO {
193 pub strProfileName: [u16; 256],
194 pub AdapterGUID: ::windows_sys::core::GUID,
195 pub Media: WCM_MEDIA_TYPE,
196}
197impl ::core::marker::Copy for WCM_PROFILE_INFO {}
198impl ::core::clone::Clone for WCM_PROFILE_INFO {
199 fn clone(&self) -> Self {
200 *self
201 }
202}
203#[repr(C)]
04454e1e 204#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
5e7ed085
FG
205pub struct WCM_PROFILE_INFO_LIST {
206 pub dwNumberOfItems: u32,
207 pub ProfileInfo: [WCM_PROFILE_INFO; 1],
208}
209impl ::core::marker::Copy for WCM_PROFILE_INFO_LIST {}
210impl ::core::clone::Clone for WCM_PROFILE_INFO_LIST {
211 fn clone(&self) -> Self {
212 *self
213 }
214}
5e7ed085 215#[repr(C)]
04454e1e 216#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
5e7ed085
FG
217pub struct WCM_TIME_INTERVAL {
218 pub wYear: u16,
219 pub wMonth: u16,
220 pub wDay: u16,
221 pub wHour: u16,
222 pub wMinute: u16,
223 pub wSecond: u16,
224 pub wMilliseconds: u16,
225}
226impl ::core::marker::Copy for WCM_TIME_INTERVAL {}
227impl ::core::clone::Clone for WCM_TIME_INTERVAL {
228 fn clone(&self) -> Self {
229 *self
230 }
231}
5e7ed085 232#[repr(C)]
04454e1e 233#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`, `\"Win32_Foundation\"`*"]
5e7ed085
FG
234#[cfg(feature = "Win32_Foundation")]
235pub struct WCM_USAGE_DATA {
236 pub UsageInMegabytes: u32,
237 pub LastSyncTime: super::super::Foundation::FILETIME,
238}
239#[cfg(feature = "Win32_Foundation")]
240impl ::core::marker::Copy for WCM_USAGE_DATA {}
241#[cfg(feature = "Win32_Foundation")]
242impl ::core::clone::Clone for WCM_USAGE_DATA {
243 fn clone(&self) -> Self {
244 *self
245 }
246}
487cf647
FG
247#[doc = "*Required features: `\"Win32_NetworkManagement_WindowsConnectionManager\"`*"]
248pub type ONDEMAND_NOTIFICATION_CALLBACK = ::core::option::Option<unsafe extern "system" fn(param0: *const ::core::ffi::c_void)>;