1 #[cfg(feature = "ApplicationModel_UserActivities_Core")]
5 pub struct IUserActivity(::windows
::core
::IUnknown
);
6 unsafe impl ::windows
::core
::Interface
for IUserActivity
{
7 type Vtable
= IUserActivity_Vtbl
;
9 impl ::core
::clone
::Clone
for IUserActivity
{
10 fn clone(&self) -> Self {
14 unsafe impl ::windows
::core
::ComInterface
for IUserActivity
{
15 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0xfc103e9e_2cab_4d36_aea2_b4bb556cef0f);
19 pub struct IUserActivity_Vtbl
{
20 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
21 pub State
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut UserActivityState
) -> ::windows
::core
::HRESULT
,
22 pub ActivityId
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>) -> ::windows
::core
::HRESULT
,
23 pub VisualElements
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
24 #[cfg(feature = "Foundation")]
25 pub ContentUri
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
26 #[cfg(not(feature = "Foundation"))]
28 #[cfg(feature = "Foundation")]
29 pub SetContentUri
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
30 #[cfg(not(feature = "Foundation"))]
32 pub ContentType
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>) -> ::windows
::core
::HRESULT
,
33 pub SetContentType
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>) -> ::windows
::core
::HRESULT
,
34 #[cfg(feature = "Foundation")]
35 pub FallbackUri
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
36 #[cfg(not(feature = "Foundation"))]
38 #[cfg(feature = "Foundation")]
39 pub SetFallbackUri
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
40 #[cfg(not(feature = "Foundation"))]
41 SetFallbackUri
: usize,
42 #[cfg(feature = "Foundation")]
43 pub ActivationUri
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
44 #[cfg(not(feature = "Foundation"))]
46 #[cfg(feature = "Foundation")]
47 pub SetActivationUri
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
48 #[cfg(not(feature = "Foundation"))]
49 SetActivationUri
: usize,
50 pub ContentInfo
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
51 pub SetContentInfo
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
52 #[cfg(feature = "Foundation")]
53 pub SaveAsync
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
54 #[cfg(not(feature = "Foundation"))]
56 pub CreateSession
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
60 pub struct IUserActivity2(::windows
::core
::IUnknown
);
61 unsafe impl ::windows
::core
::Interface
for IUserActivity2
{
62 type Vtable
= IUserActivity2_Vtbl
;
64 impl ::core
::clone
::Clone
for IUserActivity2
{
65 fn clone(&self) -> Self {
69 unsafe impl ::windows
::core
::ComInterface
for IUserActivity2
{
70 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0x9dc40c62_08c4_47ac_aa9c_2bb2221c55fd);
74 pub struct IUserActivity2_Vtbl
{
75 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
76 pub ToJson
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>) -> ::windows
::core
::HRESULT
,
80 pub struct IUserActivity3(::windows
::core
::IUnknown
);
81 unsafe impl ::windows
::core
::Interface
for IUserActivity3
{
82 type Vtable
= IUserActivity3_Vtbl
;
84 impl ::core
::clone
::Clone
for IUserActivity3
{
85 fn clone(&self) -> Self {
89 unsafe impl ::windows
::core
::ComInterface
for IUserActivity3
{
90 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0xe7697744_e1a2_5147_8e06_55f1eeef271c);
94 pub struct IUserActivity3_Vtbl
{
95 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
96 pub IsRoamable
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut bool
) -> ::windows
::core
::HRESULT
,
97 pub SetIsRoamable
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: bool
) -> ::windows
::core
::HRESULT
,
101 pub struct IUserActivityAttribution(::windows
::core
::IUnknown
);
102 unsafe impl ::windows
::core
::Interface
for IUserActivityAttribution
{
103 type Vtable
= IUserActivityAttribution_Vtbl
;
105 impl ::core
::clone
::Clone
for IUserActivityAttribution
{
106 fn clone(&self) -> Self {
110 unsafe impl ::windows
::core
::ComInterface
for IUserActivityAttribution
{
111 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0x34a5c8b5_86dd_4aec_a491_6a4faea5d22e);
115 pub struct IUserActivityAttribution_Vtbl
{
116 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
117 #[cfg(feature = "Foundation")]
118 pub IconUri
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
119 #[cfg(not(feature = "Foundation"))]
121 #[cfg(feature = "Foundation")]
122 pub SetIconUri
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
123 #[cfg(not(feature = "Foundation"))]
125 pub AlternateText
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>) -> ::windows
::core
::HRESULT
,
126 pub SetAlternateText
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>) -> ::windows
::core
::HRESULT
,
127 pub AddImageQuery
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut bool
) -> ::windows
::core
::HRESULT
,
128 pub SetAddImageQuery
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: bool
) -> ::windows
::core
::HRESULT
,
132 pub struct IUserActivityAttributionFactory(::windows
::core
::IUnknown
);
133 unsafe impl ::windows
::core
::Interface
for IUserActivityAttributionFactory
{
134 type Vtable
= IUserActivityAttributionFactory_Vtbl
;
136 impl ::core
::clone
::Clone
for IUserActivityAttributionFactory
{
137 fn clone(&self) -> Self {
141 unsafe impl ::windows
::core
::ComInterface
for IUserActivityAttributionFactory
{
142 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0xe62bd252_c566_4f42_9974_916c4d76377e);
146 pub struct IUserActivityAttributionFactory_Vtbl
{
147 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
148 #[cfg(feature = "Foundation")]
149 pub CreateWithUri
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, iconuri
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
150 #[cfg(not(feature = "Foundation"))]
151 CreateWithUri
: usize,
155 pub struct IUserActivityChannel(::windows
::core
::IUnknown
);
156 unsafe impl ::windows
::core
::Interface
for IUserActivityChannel
{
157 type Vtable
= IUserActivityChannel_Vtbl
;
159 impl ::core
::clone
::Clone
for IUserActivityChannel
{
160 fn clone(&self) -> Self {
164 unsafe impl ::windows
::core
::ComInterface
for IUserActivityChannel
{
165 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0xbac0f8b8_a0e4_483b_b948_9cbabd06070c);
169 pub struct IUserActivityChannel_Vtbl
{
170 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
171 #[cfg(feature = "Foundation")]
172 pub GetOrCreateUserActivityAsync
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, activityid
: ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
173 #[cfg(not(feature = "Foundation"))]
174 GetOrCreateUserActivityAsync
: usize,
175 #[cfg(feature = "Foundation")]
176 pub DeleteActivityAsync
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, activityid
: ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
177 #[cfg(not(feature = "Foundation"))]
178 DeleteActivityAsync
: usize,
179 #[cfg(feature = "Foundation")]
180 pub DeleteAllActivitiesAsync
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
181 #[cfg(not(feature = "Foundation"))]
182 DeleteAllActivitiesAsync
: usize,
186 pub struct IUserActivityChannel2(::windows
::core
::IUnknown
);
187 unsafe impl ::windows
::core
::Interface
for IUserActivityChannel2
{
188 type Vtable
= IUserActivityChannel2_Vtbl
;
190 impl ::core
::clone
::Clone
for IUserActivityChannel2
{
191 fn clone(&self) -> Self {
195 unsafe impl ::windows
::core
::ComInterface
for IUserActivityChannel2
{
196 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0x1698e35b_eb7e_4ea0_bf17_a459e8be706c);
200 pub struct IUserActivityChannel2_Vtbl
{
201 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
202 #[cfg(feature = "Foundation_Collections")]
203 pub GetRecentUserActivitiesAsync
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, maxuniqueactivities
: i32, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
204 #[cfg(not(feature = "Foundation_Collections"))]
205 GetRecentUserActivitiesAsync
: usize,
206 #[cfg(feature = "Foundation_Collections")]
207 pub GetSessionHistoryItemsForUserActivityAsync
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, activityid
: ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>, starttime
: super::super::Foundation
::DateTime
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
208 #[cfg(not(feature = "Foundation_Collections"))]
209 GetSessionHistoryItemsForUserActivityAsync
: usize,
213 pub struct IUserActivityChannelStatics(::windows
::core
::IUnknown
);
214 unsafe impl ::windows
::core
::Interface
for IUserActivityChannelStatics
{
215 type Vtable
= IUserActivityChannelStatics_Vtbl
;
217 impl ::core
::clone
::Clone
for IUserActivityChannelStatics
{
218 fn clone(&self) -> Self {
222 unsafe impl ::windows
::core
::ComInterface
for IUserActivityChannelStatics
{
223 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0xc8c005ab_198d_4d80_abb2_c9775ec4a729);
227 pub struct IUserActivityChannelStatics_Vtbl
{
228 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
229 pub GetDefault
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
233 pub struct IUserActivityChannelStatics2(::windows
::core
::IUnknown
);
234 unsafe impl ::windows
::core
::Interface
for IUserActivityChannelStatics2
{
235 type Vtable
= IUserActivityChannelStatics2_Vtbl
;
237 impl ::core
::clone
::Clone
for IUserActivityChannelStatics2
{
238 fn clone(&self) -> Self {
242 unsafe impl ::windows
::core
::ComInterface
for IUserActivityChannelStatics2
{
243 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0x8e87de30_aa4f_4624_9ad0_d40f3ba0317c);
247 pub struct IUserActivityChannelStatics2_Vtbl
{
248 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
249 pub DisableAutoSessionCreation
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
250 #[cfg(feature = "Security_Credentials")]
251 pub TryGetForWebAccount
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, account
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
252 #[cfg(not(feature = "Security_Credentials"))]
253 TryGetForWebAccount
: usize,
257 pub struct IUserActivityChannelStatics3(::windows
::core
::IUnknown
);
258 unsafe impl ::windows
::core
::Interface
for IUserActivityChannelStatics3
{
259 type Vtable
= IUserActivityChannelStatics3_Vtbl
;
261 impl ::core
::clone
::Clone
for IUserActivityChannelStatics3
{
262 fn clone(&self) -> Self {
266 unsafe impl ::windows
::core
::ComInterface
for IUserActivityChannelStatics3
{
267 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0x53bc4ddb_bbdf_5984_802a_5305874e205c);
271 pub struct IUserActivityChannelStatics3_Vtbl
{
272 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
273 #[cfg(feature = "System")]
274 pub GetForUser
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, user
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
275 #[cfg(not(feature = "System"))]
278 #[doc = "*Required features: `\"ApplicationModel_UserActivities\"`*"]
280 pub struct IUserActivityContentInfo(::windows
::core
::IUnknown
);
281 impl IUserActivityContentInfo
{
282 pub fn ToJson(&self) -> ::windows
::core
::Result
<::windows
::core
::HSTRING
> {
285 let mut result__
= ::windows
::core
::zeroed
::<::windows
::core
::HSTRING
>();
286 (::windows
::core
::Interface
::vtable(this
).ToJson
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
290 ::windows
::imp
::interface_hierarchy
!(IUserActivityContentInfo
, ::windows
::core
::IUnknown
, ::windows
::core
::IInspectable
);
291 impl ::core
::cmp
::PartialEq
for IUserActivityContentInfo
{
292 fn eq(&self, other
: &Self) -> bool
{
296 impl ::core
::cmp
::Eq
for IUserActivityContentInfo {}
297 impl ::core
::fmt
::Debug
for IUserActivityContentInfo
{
298 fn fmt(&self, f
: &mut ::core
::fmt
::Formatter
<'_
>) -> ::core
::fmt
::Result
{
299 f
.debug_tuple("IUserActivityContentInfo").field(&self.0).finish()
302 impl ::windows
::core
::RuntimeType
for IUserActivityContentInfo
{
303 const SIGNATURE
: ::windows
::imp
::ConstBuffer
= ::windows
::imp
::ConstBuffer
::from_slice(b
"{b399e5ad-137f-409d-822d-e1af27ce08dc}");
305 unsafe impl ::windows
::core
::Interface
for IUserActivityContentInfo
{
306 type Vtable
= IUserActivityContentInfo_Vtbl
;
308 impl ::core
::clone
::Clone
for IUserActivityContentInfo
{
309 fn clone(&self) -> Self {
313 unsafe impl ::windows
::core
::ComInterface
for IUserActivityContentInfo
{
314 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0xb399e5ad_137f_409d_822d_e1af27ce08dc);
318 pub struct IUserActivityContentInfo_Vtbl
{
319 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
320 pub ToJson
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>) -> ::windows
::core
::HRESULT
,
324 pub struct IUserActivityContentInfoStatics(::windows
::core
::IUnknown
);
325 unsafe impl ::windows
::core
::Interface
for IUserActivityContentInfoStatics
{
326 type Vtable
= IUserActivityContentInfoStatics_Vtbl
;
328 impl ::core
::clone
::Clone
for IUserActivityContentInfoStatics
{
329 fn clone(&self) -> Self {
333 unsafe impl ::windows
::core
::ComInterface
for IUserActivityContentInfoStatics
{
334 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0x9988c34b_0386_4bc9_968a_8200b004144f);
338 pub struct IUserActivityContentInfoStatics_Vtbl
{
339 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
340 pub FromJson
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
344 pub struct IUserActivityFactory(::windows
::core
::IUnknown
);
345 unsafe impl ::windows
::core
::Interface
for IUserActivityFactory
{
346 type Vtable
= IUserActivityFactory_Vtbl
;
348 impl ::core
::clone
::Clone
for IUserActivityFactory
{
349 fn clone(&self) -> Self {
353 unsafe impl ::windows
::core
::ComInterface
for IUserActivityFactory
{
354 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0x7c385758_361d_4a67_8a3b_34ca2978f9a3);
358 pub struct IUserActivityFactory_Vtbl
{
359 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
360 pub CreateWithActivityId
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, activityid
: ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
364 pub struct IUserActivityRequest(::windows
::core
::IUnknown
);
365 unsafe impl ::windows
::core
::Interface
for IUserActivityRequest
{
366 type Vtable
= IUserActivityRequest_Vtbl
;
368 impl ::core
::clone
::Clone
for IUserActivityRequest
{
369 fn clone(&self) -> Self {
373 unsafe impl ::windows
::core
::ComInterface
for IUserActivityRequest
{
374 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0xa0ef6355_cf35_4ff0_8833_50cb4b72e06d);
378 pub struct IUserActivityRequest_Vtbl
{
379 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
380 pub SetUserActivity
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, activity
: *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
384 pub struct IUserActivityRequestManager(::windows
::core
::IUnknown
);
385 unsafe impl ::windows
::core
::Interface
for IUserActivityRequestManager
{
386 type Vtable
= IUserActivityRequestManager_Vtbl
;
388 impl ::core
::clone
::Clone
for IUserActivityRequestManager
{
389 fn clone(&self) -> Self {
393 unsafe impl ::windows
::core
::ComInterface
for IUserActivityRequestManager
{
394 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0x0c30be4e_903d_48d6_82d4_4043ed57791b);
398 pub struct IUserActivityRequestManager_Vtbl
{
399 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
400 #[cfg(feature = "Foundation")]
401 pub UserActivityRequested
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, handler
: *mut ::core
::ffi
::c_void
, result__
: *mut super::super::Foundation
::EventRegistrationToken
) -> ::windows
::core
::HRESULT
,
402 #[cfg(not(feature = "Foundation"))]
403 UserActivityRequested
: usize,
404 #[cfg(feature = "Foundation")]
405 pub RemoveUserActivityRequested
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, token
: super::super::Foundation
::EventRegistrationToken
) -> ::windows
::core
::HRESULT
,
406 #[cfg(not(feature = "Foundation"))]
407 RemoveUserActivityRequested
: usize,
411 pub struct IUserActivityRequestManagerStatics(::windows
::core
::IUnknown
);
412 unsafe impl ::windows
::core
::Interface
for IUserActivityRequestManagerStatics
{
413 type Vtable
= IUserActivityRequestManagerStatics_Vtbl
;
415 impl ::core
::clone
::Clone
for IUserActivityRequestManagerStatics
{
416 fn clone(&self) -> Self {
420 unsafe impl ::windows
::core
::ComInterface
for IUserActivityRequestManagerStatics
{
421 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0xc0392df1_224a_432c_81e5_0c76b4c4cefa);
425 pub struct IUserActivityRequestManagerStatics_Vtbl
{
426 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
427 pub GetForCurrentView
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
431 pub struct IUserActivityRequestedEventArgs(::windows
::core
::IUnknown
);
432 unsafe impl ::windows
::core
::Interface
for IUserActivityRequestedEventArgs
{
433 type Vtable
= IUserActivityRequestedEventArgs_Vtbl
;
435 impl ::core
::clone
::Clone
for IUserActivityRequestedEventArgs
{
436 fn clone(&self) -> Self {
440 unsafe impl ::windows
::core
::ComInterface
for IUserActivityRequestedEventArgs
{
441 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0xa4cc7a4c_8229_4cfd_a3bc_c61d318575a4);
445 pub struct IUserActivityRequestedEventArgs_Vtbl
{
446 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
447 pub Request
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
448 #[cfg(feature = "Foundation")]
449 pub GetDeferral
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
450 #[cfg(not(feature = "Foundation"))]
455 pub struct IUserActivitySession(::windows
::core
::IUnknown
);
456 unsafe impl ::windows
::core
::Interface
for IUserActivitySession
{
457 type Vtable
= IUserActivitySession_Vtbl
;
459 impl ::core
::clone
::Clone
for IUserActivitySession
{
460 fn clone(&self) -> Self {
464 unsafe impl ::windows
::core
::ComInterface
for IUserActivitySession
{
465 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0xae434d78_24fa_44a3_ad48_6eda61aa1924);
469 pub struct IUserActivitySession_Vtbl
{
470 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
471 pub ActivityId
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>) -> ::windows
::core
::HRESULT
,
475 pub struct IUserActivitySessionHistoryItem(::windows
::core
::IUnknown
);
476 unsafe impl ::windows
::core
::Interface
for IUserActivitySessionHistoryItem
{
477 type Vtable
= IUserActivitySessionHistoryItem_Vtbl
;
479 impl ::core
::clone
::Clone
for IUserActivitySessionHistoryItem
{
480 fn clone(&self) -> Self {
484 unsafe impl ::windows
::core
::ComInterface
for IUserActivitySessionHistoryItem
{
485 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0xe8d59bd3_3e5d_49fd_98d7_6da97521e255);
489 pub struct IUserActivitySessionHistoryItem_Vtbl
{
490 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
491 pub UserActivity
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
492 #[cfg(feature = "Foundation")]
493 pub StartTime
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut super::super::Foundation
::DateTime
) -> ::windows
::core
::HRESULT
,
494 #[cfg(not(feature = "Foundation"))]
496 #[cfg(feature = "Foundation")]
497 pub EndTime
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
498 #[cfg(not(feature = "Foundation"))]
503 pub struct IUserActivityStatics(::windows
::core
::IUnknown
);
504 unsafe impl ::windows
::core
::Interface
for IUserActivityStatics
{
505 type Vtable
= IUserActivityStatics_Vtbl
;
507 impl ::core
::clone
::Clone
for IUserActivityStatics
{
508 fn clone(&self) -> Self {
512 unsafe impl ::windows
::core
::ComInterface
for IUserActivityStatics
{
513 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0x8c8fd333_0e09_47f6_9ac7_95cf5c39367b);
517 pub struct IUserActivityStatics_Vtbl
{
518 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
519 pub TryParseFromJson
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, json
: ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
520 #[cfg(feature = "Foundation_Collections")]
521 pub TryParseFromJsonArray
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, json
: ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
522 #[cfg(not(feature = "Foundation_Collections"))]
523 TryParseFromJsonArray
: usize,
524 #[cfg(feature = "Foundation_Collections")]
525 pub ToJsonArray
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, activities
: *mut ::core
::ffi
::c_void
, result__
: *mut ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>) -> ::windows
::core
::HRESULT
,
526 #[cfg(not(feature = "Foundation_Collections"))]
531 pub struct IUserActivityVisualElements(::windows
::core
::IUnknown
);
532 unsafe impl ::windows
::core
::Interface
for IUserActivityVisualElements
{
533 type Vtable
= IUserActivityVisualElements_Vtbl
;
535 impl ::core
::clone
::Clone
for IUserActivityVisualElements
{
536 fn clone(&self) -> Self {
540 unsafe impl ::windows
::core
::ComInterface
for IUserActivityVisualElements
{
541 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0x94757513_262f_49ef_bbbf_9b75d2e85250);
545 pub struct IUserActivityVisualElements_Vtbl
{
546 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
547 pub DisplayText
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>) -> ::windows
::core
::HRESULT
,
548 pub SetDisplayText
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>) -> ::windows
::core
::HRESULT
,
549 pub Description
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>) -> ::windows
::core
::HRESULT
,
550 pub SetDescription
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>) -> ::windows
::core
::HRESULT
,
551 #[cfg(feature = "UI")]
552 pub BackgroundColor
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut super::super::UI
::Color
) -> ::windows
::core
::HRESULT
,
553 #[cfg(not(feature = "UI"))]
554 BackgroundColor
: usize,
555 #[cfg(feature = "UI")]
556 pub SetBackgroundColor
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: super::super::UI
::Color
) -> ::windows
::core
::HRESULT
,
557 #[cfg(not(feature = "UI"))]
558 SetBackgroundColor
: usize,
559 pub Attribution
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
560 pub SetAttribution
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
561 #[cfg(feature = "UI_Shell")]
562 pub SetContent
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
563 #[cfg(not(feature = "UI_Shell"))]
565 #[cfg(feature = "UI_Shell")]
566 pub Content
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut *mut ::core
::ffi
::c_void
) -> ::windows
::core
::HRESULT
,
567 #[cfg(not(feature = "UI_Shell"))]
572 pub struct IUserActivityVisualElements2(::windows
::core
::IUnknown
);
573 unsafe impl ::windows
::core
::Interface
for IUserActivityVisualElements2
{
574 type Vtable
= IUserActivityVisualElements2_Vtbl
;
576 impl ::core
::clone
::Clone
for IUserActivityVisualElements2
{
577 fn clone(&self) -> Self {
581 unsafe impl ::windows
::core
::ComInterface
for IUserActivityVisualElements2
{
582 const IID
: ::windows
::core
::GUID
= ::windows
::core
::GUID
::from_u128(0xcaae7fc7_3eef_4359_825c_9d51b9220de3);
586 pub struct IUserActivityVisualElements2_Vtbl
{
587 pub base__
: ::windows
::core
::IInspectable_Vtbl
,
588 pub AttributionDisplayText
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, result__
: *mut ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>) -> ::windows
::core
::HRESULT
,
589 pub SetAttributionDisplayText
: unsafe extern "system" fn(this
: *mut ::core
::ffi
::c_void
, value
: ::std
::mem
::MaybeUninit
<::windows
::core
::HSTRING
>) -> ::windows
::core
::HRESULT
,
591 #[doc = "*Required features: `\"ApplicationModel_UserActivities\"`*"]
593 pub struct UserActivity(::windows
::core
::IUnknown
);
595 pub fn State(&self) -> ::windows
::core
::Result
<UserActivityState
> {
598 let mut result__
= ::windows
::core
::zeroed
::<UserActivityState
>();
599 (::windows
::core
::Interface
::vtable(this
).State
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
602 pub fn ActivityId(&self) -> ::windows
::core
::Result
<::windows
::core
::HSTRING
> {
605 let mut result__
= ::windows
::core
::zeroed
::<::windows
::core
::HSTRING
>();
606 (::windows
::core
::Interface
::vtable(this
).ActivityId
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
609 pub fn VisualElements(&self) -> ::windows
::core
::Result
<UserActivityVisualElements
> {
612 let mut result__
= ::windows
::core
::zeroed
::<UserActivityVisualElements
>();
613 (::windows
::core
::Interface
::vtable(this
).VisualElements
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
616 #[doc = "*Required features: `\"Foundation\"`*"]
617 #[cfg(feature = "Foundation")]
618 pub fn ContentUri(&self) -> ::windows
::core
::Result
<super::super::Foundation
::Uri
> {
621 let mut result__
= ::windows
::core
::zeroed
::<super::super::Foundation
::Uri
>();
622 (::windows
::core
::Interface
::vtable(this
).ContentUri
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
625 #[doc = "*Required features: `\"Foundation\"`*"]
626 #[cfg(feature = "Foundation")]
627 pub fn SetContentUri(&self, value
: &super::super::Foundation
::Uri
) -> ::windows
::core
::Result
<()> {
629 unsafe { (::windows::core::Interface::vtable(this).SetContentUri)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(value)).ok() }
631 pub fn ContentType(&self) -> ::windows
::core
::Result
<::windows
::core
::HSTRING
> {
634 let mut result__
= ::windows
::core
::zeroed
::<::windows
::core
::HSTRING
>();
635 (::windows
::core
::Interface
::vtable(this
).ContentType
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
638 pub fn SetContentType(&self, value
: &::windows
::core
::HSTRING
) -> ::windows
::core
::Result
<()> {
640 unsafe { (::windows::core::Interface::vtable(this).SetContentType)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(value)).ok() }
642 #[doc = "*Required features: `\"Foundation\"`*"]
643 #[cfg(feature = "Foundation")]
644 pub fn FallbackUri(&self) -> ::windows
::core
::Result
<super::super::Foundation
::Uri
> {
647 let mut result__
= ::windows
::core
::zeroed
::<super::super::Foundation
::Uri
>();
648 (::windows
::core
::Interface
::vtable(this
).FallbackUri
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
651 #[doc = "*Required features: `\"Foundation\"`*"]
652 #[cfg(feature = "Foundation")]
653 pub fn SetFallbackUri(&self, value
: &super::super::Foundation
::Uri
) -> ::windows
::core
::Result
<()> {
655 unsafe { (::windows::core::Interface::vtable(this).SetFallbackUri)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(value)).ok() }
657 #[doc = "*Required features: `\"Foundation\"`*"]
658 #[cfg(feature = "Foundation")]
659 pub fn ActivationUri(&self) -> ::windows
::core
::Result
<super::super::Foundation
::Uri
> {
662 let mut result__
= ::windows
::core
::zeroed
::<super::super::Foundation
::Uri
>();
663 (::windows
::core
::Interface
::vtable(this
).ActivationUri
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
666 #[doc = "*Required features: `\"Foundation\"`*"]
667 #[cfg(feature = "Foundation")]
668 pub fn SetActivationUri(&self, value
: &super::super::Foundation
::Uri
) -> ::windows
::core
::Result
<()> {
670 unsafe { (::windows::core::Interface::vtable(this).SetActivationUri)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(value)).ok() }
672 pub fn ContentInfo(&self) -> ::windows
::core
::Result
<IUserActivityContentInfo
> {
675 let mut result__
= ::windows
::core
::zeroed
::<IUserActivityContentInfo
>();
676 (::windows
::core
::Interface
::vtable(this
).ContentInfo
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
679 pub fn SetContentInfo
<P0
>(&self, value
: P0
) -> ::windows
::core
::Result
<()>
681 P0
: ::windows
::core
::TryIntoParam
<IUserActivityContentInfo
>,
684 unsafe { (::windows::core::Interface::vtable(this).SetContentInfo)(::windows::core::Interface::as_raw(this), value.try_into_param()?.abi()).ok() }
686 #[doc = "*Required features: `\"Foundation\"`*"]
687 #[cfg(feature = "Foundation")]
688 pub fn SaveAsync(&self) -> ::windows
::core
::Result
<super::super::Foundation
::IAsyncAction
> {
691 let mut result__
= ::windows
::core
::zeroed
::<super::super::Foundation
::IAsyncAction
>();
692 (::windows
::core
::Interface
::vtable(this
).SaveAsync
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
695 pub fn CreateSession(&self) -> ::windows
::core
::Result
<UserActivitySession
> {
698 let mut result__
= ::windows
::core
::zeroed
::<UserActivitySession
>();
699 (::windows
::core
::Interface
::vtable(this
).CreateSession
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
702 pub fn ToJson(&self) -> ::windows
::core
::Result
<::windows
::core
::HSTRING
> {
703 let this
= &::windows
::core
::ComInterface
::cast
::<IUserActivity2
>(self)?
;
705 let mut result__
= ::windows
::core
::zeroed
::<::windows
::core
::HSTRING
>();
706 (::windows
::core
::Interface
::vtable(this
).ToJson
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
709 pub fn IsRoamable(&self) -> ::windows
::core
::Result
<bool
> {
710 let this
= &::windows
::core
::ComInterface
::cast
::<IUserActivity3
>(self)?
;
712 let mut result__
= ::windows
::core
::zeroed
::<bool
>();
713 (::windows
::core
::Interface
::vtable(this
).IsRoamable
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
716 pub fn SetIsRoamable(&self, value
: bool
) -> ::windows
::core
::Result
<()> {
717 let this
= &::windows
::core
::ComInterface
::cast
::<IUserActivity3
>(self)?
;
718 unsafe { (::windows::core::Interface::vtable(this).SetIsRoamable)(::windows::core::Interface::as_raw(this), value).ok() }
720 pub fn CreateWithActivityId(activityid
: &::windows
::core
::HSTRING
) -> ::windows
::core
::Result
<UserActivity
> {
721 Self::IUserActivityFactory(|this
| unsafe {
722 let mut result__
= ::windows
::core
::zeroed
::<UserActivity
>();
723 (::windows
::core
::Interface
::vtable(this
).CreateWithActivityId
)(::windows
::core
::Interface
::as_raw(this
), ::core
::mem
::transmute_copy(activityid
), &mut result__
).from_abi(result__
)
726 pub fn TryParseFromJson(json
: &::windows
::core
::HSTRING
) -> ::windows
::core
::Result
<UserActivity
> {
727 Self::IUserActivityStatics(|this
| unsafe {
728 let mut result__
= ::windows
::core
::zeroed
::<UserActivity
>();
729 (::windows
::core
::Interface
::vtable(this
).TryParseFromJson
)(::windows
::core
::Interface
::as_raw(this
), ::core
::mem
::transmute_copy(json
), &mut result__
).from_abi(result__
)
732 #[doc = "*Required features: `\"Foundation_Collections\"`*"]
733 #[cfg(feature = "Foundation_Collections")]
734 pub fn TryParseFromJsonArray(json
: &::windows
::core
::HSTRING
) -> ::windows
::core
::Result
<super::super::Foundation
::Collections
::IVector
<UserActivity
>> {
735 Self::IUserActivityStatics(|this
| unsafe {
736 let mut result__
= ::windows
::core
::zeroed
::<super::super::Foundation
::Collections
::IVector
<UserActivity
>>();
737 (::windows
::core
::Interface
::vtable(this
).TryParseFromJsonArray
)(::windows
::core
::Interface
::as_raw(this
), ::core
::mem
::transmute_copy(json
), &mut result__
).from_abi(result__
)
740 #[doc = "*Required features: `\"Foundation_Collections\"`*"]
741 #[cfg(feature = "Foundation_Collections")]
742 pub fn ToJsonArray
<P0
>(activities
: P0
) -> ::windows
::core
::Result
<::windows
::core
::HSTRING
>
744 P0
: ::windows
::core
::TryIntoParam
<super::super::Foundation
::Collections
::IIterable
<UserActivity
>>,
746 Self::IUserActivityStatics(|this
| unsafe {
747 let mut result__
= ::windows
::core
::zeroed
::<::windows
::core
::HSTRING
>();
748 (::windows
::core
::Interface
::vtable(this
).ToJsonArray
)(::windows
::core
::Interface
::as_raw(this
), activities
.try_into_param()?
.abi(), &mut result__
).from_abi(result__
)
752 pub fn IUserActivityFactory
<R
, F
: FnOnce(&IUserActivityFactory
) -> ::windows
::core
::Result
<R
>>(callback
: F
) -> ::windows
::core
::Result
<R
> {
753 static SHARED
: ::windows
::imp
::FactoryCache
<UserActivity
, IUserActivityFactory
> = ::windows
::imp
::FactoryCache
::new();
754 SHARED
.call(callback
)
757 pub fn IUserActivityStatics
<R
, F
: FnOnce(&IUserActivityStatics
) -> ::windows
::core
::Result
<R
>>(callback
: F
) -> ::windows
::core
::Result
<R
> {
758 static SHARED
: ::windows
::imp
::FactoryCache
<UserActivity
, IUserActivityStatics
> = ::windows
::imp
::FactoryCache
::new();
759 SHARED
.call(callback
)
762 impl ::core
::cmp
::PartialEq
for UserActivity
{
763 fn eq(&self, other
: &Self) -> bool
{
767 impl ::core
::cmp
::Eq
for UserActivity {}
768 impl ::core
::fmt
::Debug
for UserActivity
{
769 fn fmt(&self, f
: &mut ::core
::fmt
::Formatter
<'_
>) -> ::core
::fmt
::Result
{
770 f
.debug_tuple("UserActivity").field(&self.0).finish()
773 impl ::windows
::core
::RuntimeType
for UserActivity
{
774 const SIGNATURE
: ::windows
::imp
::ConstBuffer
= ::windows
::imp
::ConstBuffer
::from_slice(b
"rc(Windows.ApplicationModel.UserActivities.UserActivity;{fc103e9e-2cab-4d36-aea2-b4bb556cef0f})");
776 impl ::core
::clone
::Clone
for UserActivity
{
777 fn clone(&self) -> Self {
781 unsafe impl ::windows
::core
::Interface
for UserActivity
{
782 type Vtable
= IUserActivity_Vtbl
;
784 unsafe impl ::windows
::core
::ComInterface
for UserActivity
{
785 const IID
: ::windows
::core
::GUID
= <IUserActivity
as ::windows
::core
::ComInterface
>::IID
;
787 impl ::windows
::core
::RuntimeName
for UserActivity
{
788 const NAME
: &'
static str = "Windows.ApplicationModel.UserActivities.UserActivity";
790 ::windows
::imp
::interface_hierarchy
!(UserActivity
, ::windows
::core
::IUnknown
, ::windows
::core
::IInspectable
);
791 unsafe impl ::core
::marker
::Send
for UserActivity {}
792 unsafe impl ::core
::marker
::Sync
for UserActivity {}
793 #[doc = "*Required features: `\"ApplicationModel_UserActivities\"`*"]
795 pub struct UserActivityAttribution(::windows
::core
::IUnknown
);
796 impl UserActivityAttribution
{
797 pub fn new() -> ::windows
::core
::Result
<Self> {
798 Self::IActivationFactory(|f
| f
.ActivateInstance
::<Self>())
800 fn IActivationFactory
<R
, F
: FnOnce(&::windows
::imp
::IGenericFactory
) -> ::windows
::core
::Result
<R
>>(callback
: F
) -> ::windows
::core
::Result
<R
> {
801 static SHARED
: ::windows
::imp
::FactoryCache
<UserActivityAttribution
, ::windows
::imp
::IGenericFactory
> = ::windows
::imp
::FactoryCache
::new();
802 SHARED
.call(callback
)
804 #[doc = "*Required features: `\"Foundation\"`*"]
805 #[cfg(feature = "Foundation")]
806 pub fn IconUri(&self) -> ::windows
::core
::Result
<super::super::Foundation
::Uri
> {
809 let mut result__
= ::windows
::core
::zeroed
::<super::super::Foundation
::Uri
>();
810 (::windows
::core
::Interface
::vtable(this
).IconUri
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
813 #[doc = "*Required features: `\"Foundation\"`*"]
814 #[cfg(feature = "Foundation")]
815 pub fn SetIconUri(&self, value
: &super::super::Foundation
::Uri
) -> ::windows
::core
::Result
<()> {
817 unsafe { (::windows::core::Interface::vtable(this).SetIconUri)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(value)).ok() }
819 pub fn AlternateText(&self) -> ::windows
::core
::Result
<::windows
::core
::HSTRING
> {
822 let mut result__
= ::windows
::core
::zeroed
::<::windows
::core
::HSTRING
>();
823 (::windows
::core
::Interface
::vtable(this
).AlternateText
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
826 pub fn SetAlternateText(&self, value
: &::windows
::core
::HSTRING
) -> ::windows
::core
::Result
<()> {
828 unsafe { (::windows::core::Interface::vtable(this).SetAlternateText)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(value)).ok() }
830 pub fn AddImageQuery(&self) -> ::windows
::core
::Result
<bool
> {
833 let mut result__
= ::windows
::core
::zeroed
::<bool
>();
834 (::windows
::core
::Interface
::vtable(this
).AddImageQuery
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
837 pub fn SetAddImageQuery(&self, value
: bool
) -> ::windows
::core
::Result
<()> {
839 unsafe { (::windows::core::Interface::vtable(this).SetAddImageQuery)(::windows::core::Interface::as_raw(this), value).ok() }
841 #[doc = "*Required features: `\"Foundation\"`*"]
842 #[cfg(feature = "Foundation")]
843 pub fn CreateWithUri(iconuri
: &super::super::Foundation
::Uri
) -> ::windows
::core
::Result
<UserActivityAttribution
> {
844 Self::IUserActivityAttributionFactory(|this
| unsafe {
845 let mut result__
= ::windows
::core
::zeroed
::<UserActivityAttribution
>();
846 (::windows
::core
::Interface
::vtable(this
).CreateWithUri
)(::windows
::core
::Interface
::as_raw(this
), ::core
::mem
::transmute_copy(iconuri
), &mut result__
).from_abi(result__
)
850 pub fn IUserActivityAttributionFactory
<R
, F
: FnOnce(&IUserActivityAttributionFactory
) -> ::windows
::core
::Result
<R
>>(callback
: F
) -> ::windows
::core
::Result
<R
> {
851 static SHARED
: ::windows
::imp
::FactoryCache
<UserActivityAttribution
, IUserActivityAttributionFactory
> = ::windows
::imp
::FactoryCache
::new();
852 SHARED
.call(callback
)
855 impl ::core
::cmp
::PartialEq
for UserActivityAttribution
{
856 fn eq(&self, other
: &Self) -> bool
{
860 impl ::core
::cmp
::Eq
for UserActivityAttribution {}
861 impl ::core
::fmt
::Debug
for UserActivityAttribution
{
862 fn fmt(&self, f
: &mut ::core
::fmt
::Formatter
<'_
>) -> ::core
::fmt
::Result
{
863 f
.debug_tuple("UserActivityAttribution").field(&self.0).finish()
866 impl ::windows
::core
::RuntimeType
for UserActivityAttribution
{
867 const SIGNATURE
: ::windows
::imp
::ConstBuffer
= ::windows
::imp
::ConstBuffer
::from_slice(b
"rc(Windows.ApplicationModel.UserActivities.UserActivityAttribution;{34a5c8b5-86dd-4aec-a491-6a4faea5d22e})");
869 impl ::core
::clone
::Clone
for UserActivityAttribution
{
870 fn clone(&self) -> Self {
874 unsafe impl ::windows
::core
::Interface
for UserActivityAttribution
{
875 type Vtable
= IUserActivityAttribution_Vtbl
;
877 unsafe impl ::windows
::core
::ComInterface
for UserActivityAttribution
{
878 const IID
: ::windows
::core
::GUID
= <IUserActivityAttribution
as ::windows
::core
::ComInterface
>::IID
;
880 impl ::windows
::core
::RuntimeName
for UserActivityAttribution
{
881 const NAME
: &'
static str = "Windows.ApplicationModel.UserActivities.UserActivityAttribution";
883 ::windows
::imp
::interface_hierarchy
!(UserActivityAttribution
, ::windows
::core
::IUnknown
, ::windows
::core
::IInspectable
);
884 unsafe impl ::core
::marker
::Send
for UserActivityAttribution {}
885 unsafe impl ::core
::marker
::Sync
for UserActivityAttribution {}
886 #[doc = "*Required features: `\"ApplicationModel_UserActivities\"`*"]
888 pub struct UserActivityChannel(::windows
::core
::IUnknown
);
889 impl UserActivityChannel
{
890 #[doc = "*Required features: `\"Foundation\"`*"]
891 #[cfg(feature = "Foundation")]
892 pub fn GetOrCreateUserActivityAsync(&self, activityid
: &::windows
::core
::HSTRING
) -> ::windows
::core
::Result
<super::super::Foundation
::IAsyncOperation
<UserActivity
>> {
895 let mut result__
= ::windows
::core
::zeroed
::<super::super::Foundation
::IAsyncOperation
<UserActivity
>>();
896 (::windows
::core
::Interface
::vtable(this
).GetOrCreateUserActivityAsync
)(::windows
::core
::Interface
::as_raw(this
), ::core
::mem
::transmute_copy(activityid
), &mut result__
).from_abi(result__
)
899 #[doc = "*Required features: `\"Foundation\"`*"]
900 #[cfg(feature = "Foundation")]
901 pub fn DeleteActivityAsync(&self, activityid
: &::windows
::core
::HSTRING
) -> ::windows
::core
::Result
<super::super::Foundation
::IAsyncAction
> {
904 let mut result__
= ::windows
::core
::zeroed
::<super::super::Foundation
::IAsyncAction
>();
905 (::windows
::core
::Interface
::vtable(this
).DeleteActivityAsync
)(::windows
::core
::Interface
::as_raw(this
), ::core
::mem
::transmute_copy(activityid
), &mut result__
).from_abi(result__
)
908 #[doc = "*Required features: `\"Foundation\"`*"]
909 #[cfg(feature = "Foundation")]
910 pub fn DeleteAllActivitiesAsync(&self) -> ::windows
::core
::Result
<super::super::Foundation
::IAsyncAction
> {
913 let mut result__
= ::windows
::core
::zeroed
::<super::super::Foundation
::IAsyncAction
>();
914 (::windows
::core
::Interface
::vtable(this
).DeleteAllActivitiesAsync
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
917 #[doc = "*Required features: `\"Foundation_Collections\"`*"]
918 #[cfg(feature = "Foundation_Collections")]
919 pub fn GetRecentUserActivitiesAsync(&self, maxuniqueactivities
: i32) -> ::windows
::core
::Result
<super::super::Foundation
::IAsyncOperation
<super::super::Foundation
::Collections
::IVector
<UserActivitySessionHistoryItem
>>> {
920 let this
= &::windows
::core
::ComInterface
::cast
::<IUserActivityChannel2
>(self)?
;
922 let mut result__
= ::windows
::core
::zeroed
::<super::super::Foundation
::IAsyncOperation
<super::super::Foundation
::Collections
::IVector
<UserActivitySessionHistoryItem
>>>();
923 (::windows
::core
::Interface
::vtable(this
).GetRecentUserActivitiesAsync
)(::windows
::core
::Interface
::as_raw(this
), maxuniqueactivities
, &mut result__
).from_abi(result__
)
926 #[doc = "*Required features: `\"Foundation_Collections\"`*"]
927 #[cfg(feature = "Foundation_Collections")]
928 pub fn GetSessionHistoryItemsForUserActivityAsync(&self, activityid
: &::windows
::core
::HSTRING
, starttime
: super::super::Foundation
::DateTime
) -> ::windows
::core
::Result
<super::super::Foundation
::IAsyncOperation
<super::super::Foundation
::Collections
::IVector
<UserActivitySessionHistoryItem
>>> {
929 let this
= &::windows
::core
::ComInterface
::cast
::<IUserActivityChannel2
>(self)?
;
931 let mut result__
= ::windows
::core
::zeroed
::<super::super::Foundation
::IAsyncOperation
<super::super::Foundation
::Collections
::IVector
<UserActivitySessionHistoryItem
>>>();
932 (::windows
::core
::Interface
::vtable(this
).GetSessionHistoryItemsForUserActivityAsync
)(::windows
::core
::Interface
::as_raw(this
), ::core
::mem
::transmute_copy(activityid
), starttime
, &mut result__
).from_abi(result__
)
935 pub fn GetDefault() -> ::windows
::core
::Result
<UserActivityChannel
> {
936 Self::IUserActivityChannelStatics(|this
| unsafe {
937 let mut result__
= ::windows
::core
::zeroed
::<UserActivityChannel
>();
938 (::windows
::core
::Interface
::vtable(this
).GetDefault
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
941 pub fn DisableAutoSessionCreation() -> ::windows
::core
::Result
<()> {
942 Self::IUserActivityChannelStatics2(|this
| unsafe { (::windows::core::Interface::vtable(this).DisableAutoSessionCreation)(::windows::core::Interface::as_raw(this)).ok() }
)
944 #[doc = "*Required features: `\"Security_Credentials\"`*"]
945 #[cfg(feature = "Security_Credentials")]
946 pub fn TryGetForWebAccount(account
: &super::super::Security
::Credentials
::WebAccount
) -> ::windows
::core
::Result
<UserActivityChannel
> {
947 Self::IUserActivityChannelStatics2(|this
| unsafe {
948 let mut result__
= ::windows
::core
::zeroed
::<UserActivityChannel
>();
949 (::windows
::core
::Interface
::vtable(this
).TryGetForWebAccount
)(::windows
::core
::Interface
::as_raw(this
), ::core
::mem
::transmute_copy(account
), &mut result__
).from_abi(result__
)
952 #[doc = "*Required features: `\"System\"`*"]
953 #[cfg(feature = "System")]
954 pub fn GetForUser(user
: &super::super::System
::User
) -> ::windows
::core
::Result
<UserActivityChannel
> {
955 Self::IUserActivityChannelStatics3(|this
| unsafe {
956 let mut result__
= ::windows
::core
::zeroed
::<UserActivityChannel
>();
957 (::windows
::core
::Interface
::vtable(this
).GetForUser
)(::windows
::core
::Interface
::as_raw(this
), ::core
::mem
::transmute_copy(user
), &mut result__
).from_abi(result__
)
961 pub fn IUserActivityChannelStatics
<R
, F
: FnOnce(&IUserActivityChannelStatics
) -> ::windows
::core
::Result
<R
>>(callback
: F
) -> ::windows
::core
::Result
<R
> {
962 static SHARED
: ::windows
::imp
::FactoryCache
<UserActivityChannel
, IUserActivityChannelStatics
> = ::windows
::imp
::FactoryCache
::new();
963 SHARED
.call(callback
)
966 pub fn IUserActivityChannelStatics2
<R
, F
: FnOnce(&IUserActivityChannelStatics2
) -> ::windows
::core
::Result
<R
>>(callback
: F
) -> ::windows
::core
::Result
<R
> {
967 static SHARED
: ::windows
::imp
::FactoryCache
<UserActivityChannel
, IUserActivityChannelStatics2
> = ::windows
::imp
::FactoryCache
::new();
968 SHARED
.call(callback
)
971 pub fn IUserActivityChannelStatics3
<R
, F
: FnOnce(&IUserActivityChannelStatics3
) -> ::windows
::core
::Result
<R
>>(callback
: F
) -> ::windows
::core
::Result
<R
> {
972 static SHARED
: ::windows
::imp
::FactoryCache
<UserActivityChannel
, IUserActivityChannelStatics3
> = ::windows
::imp
::FactoryCache
::new();
973 SHARED
.call(callback
)
976 impl ::core
::cmp
::PartialEq
for UserActivityChannel
{
977 fn eq(&self, other
: &Self) -> bool
{
981 impl ::core
::cmp
::Eq
for UserActivityChannel {}
982 impl ::core
::fmt
::Debug
for UserActivityChannel
{
983 fn fmt(&self, f
: &mut ::core
::fmt
::Formatter
<'_
>) -> ::core
::fmt
::Result
{
984 f
.debug_tuple("UserActivityChannel").field(&self.0).finish()
987 impl ::windows
::core
::RuntimeType
for UserActivityChannel
{
988 const SIGNATURE
: ::windows
::imp
::ConstBuffer
= ::windows
::imp
::ConstBuffer
::from_slice(b
"rc(Windows.ApplicationModel.UserActivities.UserActivityChannel;{bac0f8b8-a0e4-483b-b948-9cbabd06070c})");
990 impl ::core
::clone
::Clone
for UserActivityChannel
{
991 fn clone(&self) -> Self {
995 unsafe impl ::windows
::core
::Interface
for UserActivityChannel
{
996 type Vtable
= IUserActivityChannel_Vtbl
;
998 unsafe impl ::windows
::core
::ComInterface
for UserActivityChannel
{
999 const IID
: ::windows
::core
::GUID
= <IUserActivityChannel
as ::windows
::core
::ComInterface
>::IID
;
1001 impl ::windows
::core
::RuntimeName
for UserActivityChannel
{
1002 const NAME
: &'
static str = "Windows.ApplicationModel.UserActivities.UserActivityChannel";
1004 ::windows
::imp
::interface_hierarchy
!(UserActivityChannel
, ::windows
::core
::IUnknown
, ::windows
::core
::IInspectable
);
1005 unsafe impl ::core
::marker
::Send
for UserActivityChannel {}
1006 unsafe impl ::core
::marker
::Sync
for UserActivityChannel {}
1007 #[doc = "*Required features: `\"ApplicationModel_UserActivities\"`*"]
1008 #[repr(transparent)]
1009 pub struct UserActivityContentInfo(::windows
::core
::IUnknown
);
1010 impl UserActivityContentInfo
{
1011 pub fn ToJson(&self) -> ::windows
::core
::Result
<::windows
::core
::HSTRING
> {
1014 let mut result__
= ::windows
::core
::zeroed
::<::windows
::core
::HSTRING
>();
1015 (::windows
::core
::Interface
::vtable(this
).ToJson
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
1018 pub fn FromJson(value
: &::windows
::core
::HSTRING
) -> ::windows
::core
::Result
<UserActivityContentInfo
> {
1019 Self::IUserActivityContentInfoStatics(|this
| unsafe {
1020 let mut result__
= ::windows
::core
::zeroed
::<UserActivityContentInfo
>();
1021 (::windows
::core
::Interface
::vtable(this
).FromJson
)(::windows
::core
::Interface
::as_raw(this
), ::core
::mem
::transmute_copy(value
), &mut result__
).from_abi(result__
)
1025 pub fn IUserActivityContentInfoStatics
<R
, F
: FnOnce(&IUserActivityContentInfoStatics
) -> ::windows
::core
::Result
<R
>>(callback
: F
) -> ::windows
::core
::Result
<R
> {
1026 static SHARED
: ::windows
::imp
::FactoryCache
<UserActivityContentInfo
, IUserActivityContentInfoStatics
> = ::windows
::imp
::FactoryCache
::new();
1027 SHARED
.call(callback
)
1030 impl ::core
::cmp
::PartialEq
for UserActivityContentInfo
{
1031 fn eq(&self, other
: &Self) -> bool
{
1035 impl ::core
::cmp
::Eq
for UserActivityContentInfo {}
1036 impl ::core
::fmt
::Debug
for UserActivityContentInfo
{
1037 fn fmt(&self, f
: &mut ::core
::fmt
::Formatter
<'_
>) -> ::core
::fmt
::Result
{
1038 f
.debug_tuple("UserActivityContentInfo").field(&self.0).finish()
1041 impl ::windows
::core
::RuntimeType
for UserActivityContentInfo
{
1042 const SIGNATURE
: ::windows
::imp
::ConstBuffer
= ::windows
::imp
::ConstBuffer
::from_slice(b
"rc(Windows.ApplicationModel.UserActivities.UserActivityContentInfo;{b399e5ad-137f-409d-822d-e1af27ce08dc})");
1044 impl ::core
::clone
::Clone
for UserActivityContentInfo
{
1045 fn clone(&self) -> Self {
1046 Self(self.0.clone())
1049 unsafe impl ::windows
::core
::Interface
for UserActivityContentInfo
{
1050 type Vtable
= IUserActivityContentInfo_Vtbl
;
1052 unsafe impl ::windows
::core
::ComInterface
for UserActivityContentInfo
{
1053 const IID
: ::windows
::core
::GUID
= <IUserActivityContentInfo
as ::windows
::core
::ComInterface
>::IID
;
1055 impl ::windows
::core
::RuntimeName
for UserActivityContentInfo
{
1056 const NAME
: &'
static str = "Windows.ApplicationModel.UserActivities.UserActivityContentInfo";
1058 ::windows
::imp
::interface_hierarchy
!(UserActivityContentInfo
, ::windows
::core
::IUnknown
, ::windows
::core
::IInspectable
);
1059 impl ::windows
::core
::CanTryInto
<IUserActivityContentInfo
> for UserActivityContentInfo {}
1060 unsafe impl ::core
::marker
::Send
for UserActivityContentInfo {}
1061 unsafe impl ::core
::marker
::Sync
for UserActivityContentInfo {}
1062 #[doc = "*Required features: `\"ApplicationModel_UserActivities\"`*"]
1063 #[repr(transparent)]
1064 pub struct UserActivityRequest(::windows
::core
::IUnknown
);
1065 impl UserActivityRequest
{
1066 pub fn SetUserActivity(&self, activity
: &UserActivity
) -> ::windows
::core
::Result
<()> {
1068 unsafe { (::windows::core::Interface::vtable(this).SetUserActivity)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(activity)).ok() }
1071 impl ::core
::cmp
::PartialEq
for UserActivityRequest
{
1072 fn eq(&self, other
: &Self) -> bool
{
1076 impl ::core
::cmp
::Eq
for UserActivityRequest {}
1077 impl ::core
::fmt
::Debug
for UserActivityRequest
{
1078 fn fmt(&self, f
: &mut ::core
::fmt
::Formatter
<'_
>) -> ::core
::fmt
::Result
{
1079 f
.debug_tuple("UserActivityRequest").field(&self.0).finish()
1082 impl ::windows
::core
::RuntimeType
for UserActivityRequest
{
1083 const SIGNATURE
: ::windows
::imp
::ConstBuffer
= ::windows
::imp
::ConstBuffer
::from_slice(b
"rc(Windows.ApplicationModel.UserActivities.UserActivityRequest;{a0ef6355-cf35-4ff0-8833-50cb4b72e06d})");
1085 impl ::core
::clone
::Clone
for UserActivityRequest
{
1086 fn clone(&self) -> Self {
1087 Self(self.0.clone())
1090 unsafe impl ::windows
::core
::Interface
for UserActivityRequest
{
1091 type Vtable
= IUserActivityRequest_Vtbl
;
1093 unsafe impl ::windows
::core
::ComInterface
for UserActivityRequest
{
1094 const IID
: ::windows
::core
::GUID
= <IUserActivityRequest
as ::windows
::core
::ComInterface
>::IID
;
1096 impl ::windows
::core
::RuntimeName
for UserActivityRequest
{
1097 const NAME
: &'
static str = "Windows.ApplicationModel.UserActivities.UserActivityRequest";
1099 ::windows
::imp
::interface_hierarchy
!(UserActivityRequest
, ::windows
::core
::IUnknown
, ::windows
::core
::IInspectable
);
1100 unsafe impl ::core
::marker
::Send
for UserActivityRequest {}
1101 unsafe impl ::core
::marker
::Sync
for UserActivityRequest {}
1102 #[doc = "*Required features: `\"ApplicationModel_UserActivities\"`*"]
1103 #[repr(transparent)]
1104 pub struct UserActivityRequestManager(::windows
::core
::IUnknown
);
1105 impl UserActivityRequestManager
{
1106 #[doc = "*Required features: `\"Foundation\"`*"]
1107 #[cfg(feature = "Foundation")]
1108 pub fn UserActivityRequested(&self, handler
: &super::super::Foundation
::TypedEventHandler
<UserActivityRequestManager
, UserActivityRequestedEventArgs
>) -> ::windows
::core
::Result
<super::super::Foundation
::EventRegistrationToken
> {
1111 let mut result__
= ::windows
::core
::zeroed
::<super::super::Foundation
::EventRegistrationToken
>();
1112 (::windows
::core
::Interface
::vtable(this
).UserActivityRequested
)(::windows
::core
::Interface
::as_raw(this
), ::core
::mem
::transmute_copy(handler
), &mut result__
).from_abi(result__
)
1115 #[doc = "*Required features: `\"Foundation\"`*"]
1116 #[cfg(feature = "Foundation")]
1117 pub fn RemoveUserActivityRequested(&self, token
: super::super::Foundation
::EventRegistrationToken
) -> ::windows
::core
::Result
<()> {
1119 unsafe { (::windows::core::Interface::vtable(this).RemoveUserActivityRequested)(::windows::core::Interface::as_raw(this), token).ok() }
1121 pub fn GetForCurrentView() -> ::windows
::core
::Result
<UserActivityRequestManager
> {
1122 Self::IUserActivityRequestManagerStatics(|this
| unsafe {
1123 let mut result__
= ::windows
::core
::zeroed
::<UserActivityRequestManager
>();
1124 (::windows
::core
::Interface
::vtable(this
).GetForCurrentView
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
1128 pub fn IUserActivityRequestManagerStatics
<R
, F
: FnOnce(&IUserActivityRequestManagerStatics
) -> ::windows
::core
::Result
<R
>>(callback
: F
) -> ::windows
::core
::Result
<R
> {
1129 static SHARED
: ::windows
::imp
::FactoryCache
<UserActivityRequestManager
, IUserActivityRequestManagerStatics
> = ::windows
::imp
::FactoryCache
::new();
1130 SHARED
.call(callback
)
1133 impl ::core
::cmp
::PartialEq
for UserActivityRequestManager
{
1134 fn eq(&self, other
: &Self) -> bool
{
1138 impl ::core
::cmp
::Eq
for UserActivityRequestManager {}
1139 impl ::core
::fmt
::Debug
for UserActivityRequestManager
{
1140 fn fmt(&self, f
: &mut ::core
::fmt
::Formatter
<'_
>) -> ::core
::fmt
::Result
{
1141 f
.debug_tuple("UserActivityRequestManager").field(&self.0).finish()
1144 impl ::windows
::core
::RuntimeType
for UserActivityRequestManager
{
1145 const SIGNATURE
: ::windows
::imp
::ConstBuffer
= ::windows
::imp
::ConstBuffer
::from_slice(b
"rc(Windows.ApplicationModel.UserActivities.UserActivityRequestManager;{0c30be4e-903d-48d6-82d4-4043ed57791b})");
1147 impl ::core
::clone
::Clone
for UserActivityRequestManager
{
1148 fn clone(&self) -> Self {
1149 Self(self.0.clone())
1152 unsafe impl ::windows
::core
::Interface
for UserActivityRequestManager
{
1153 type Vtable
= IUserActivityRequestManager_Vtbl
;
1155 unsafe impl ::windows
::core
::ComInterface
for UserActivityRequestManager
{
1156 const IID
: ::windows
::core
::GUID
= <IUserActivityRequestManager
as ::windows
::core
::ComInterface
>::IID
;
1158 impl ::windows
::core
::RuntimeName
for UserActivityRequestManager
{
1159 const NAME
: &'
static str = "Windows.ApplicationModel.UserActivities.UserActivityRequestManager";
1161 ::windows
::imp
::interface_hierarchy
!(UserActivityRequestManager
, ::windows
::core
::IUnknown
, ::windows
::core
::IInspectable
);
1162 #[doc = "*Required features: `\"ApplicationModel_UserActivities\"`*"]
1163 #[repr(transparent)]
1164 pub struct UserActivityRequestedEventArgs(::windows
::core
::IUnknown
);
1165 impl UserActivityRequestedEventArgs
{
1166 pub fn Request(&self) -> ::windows
::core
::Result
<UserActivityRequest
> {
1169 let mut result__
= ::windows
::core
::zeroed
::<UserActivityRequest
>();
1170 (::windows
::core
::Interface
::vtable(this
).Request
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
1173 #[doc = "*Required features: `\"Foundation\"`*"]
1174 #[cfg(feature = "Foundation")]
1175 pub fn GetDeferral(&self) -> ::windows
::core
::Result
<super::super::Foundation
::Deferral
> {
1178 let mut result__
= ::windows
::core
::zeroed
::<super::super::Foundation
::Deferral
>();
1179 (::windows
::core
::Interface
::vtable(this
).GetDeferral
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
1183 impl ::core
::cmp
::PartialEq
for UserActivityRequestedEventArgs
{
1184 fn eq(&self, other
: &Self) -> bool
{
1188 impl ::core
::cmp
::Eq
for UserActivityRequestedEventArgs {}
1189 impl ::core
::fmt
::Debug
for UserActivityRequestedEventArgs
{
1190 fn fmt(&self, f
: &mut ::core
::fmt
::Formatter
<'_
>) -> ::core
::fmt
::Result
{
1191 f
.debug_tuple("UserActivityRequestedEventArgs").field(&self.0).finish()
1194 impl ::windows
::core
::RuntimeType
for UserActivityRequestedEventArgs
{
1195 const SIGNATURE
: ::windows
::imp
::ConstBuffer
= ::windows
::imp
::ConstBuffer
::from_slice(b
"rc(Windows.ApplicationModel.UserActivities.UserActivityRequestedEventArgs;{a4cc7a4c-8229-4cfd-a3bc-c61d318575a4})");
1197 impl ::core
::clone
::Clone
for UserActivityRequestedEventArgs
{
1198 fn clone(&self) -> Self {
1199 Self(self.0.clone())
1202 unsafe impl ::windows
::core
::Interface
for UserActivityRequestedEventArgs
{
1203 type Vtable
= IUserActivityRequestedEventArgs_Vtbl
;
1205 unsafe impl ::windows
::core
::ComInterface
for UserActivityRequestedEventArgs
{
1206 const IID
: ::windows
::core
::GUID
= <IUserActivityRequestedEventArgs
as ::windows
::core
::ComInterface
>::IID
;
1208 impl ::windows
::core
::RuntimeName
for UserActivityRequestedEventArgs
{
1209 const NAME
: &'
static str = "Windows.ApplicationModel.UserActivities.UserActivityRequestedEventArgs";
1211 ::windows
::imp
::interface_hierarchy
!(UserActivityRequestedEventArgs
, ::windows
::core
::IUnknown
, ::windows
::core
::IInspectable
);
1212 unsafe impl ::core
::marker
::Send
for UserActivityRequestedEventArgs {}
1213 unsafe impl ::core
::marker
::Sync
for UserActivityRequestedEventArgs {}
1214 #[doc = "*Required features: `\"ApplicationModel_UserActivities\"`*"]
1215 #[repr(transparent)]
1216 pub struct UserActivitySession(::windows
::core
::IUnknown
);
1217 impl UserActivitySession
{
1218 #[doc = "*Required features: `\"Foundation\"`*"]
1219 #[cfg(feature = "Foundation")]
1220 pub fn Close(&self) -> ::windows
::core
::Result
<()> {
1221 let this
= &::windows
::core
::ComInterface
::cast
::<super::super::Foundation
::IClosable
>(self)?
;
1222 unsafe { (::windows::core::Interface::vtable(this).Close)(::windows::core::Interface::as_raw(this)).ok() }
1224 pub fn ActivityId(&self) -> ::windows
::core
::Result
<::windows
::core
::HSTRING
> {
1227 let mut result__
= ::windows
::core
::zeroed
::<::windows
::core
::HSTRING
>();
1228 (::windows
::core
::Interface
::vtable(this
).ActivityId
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
1232 impl ::core
::cmp
::PartialEq
for UserActivitySession
{
1233 fn eq(&self, other
: &Self) -> bool
{
1237 impl ::core
::cmp
::Eq
for UserActivitySession {}
1238 impl ::core
::fmt
::Debug
for UserActivitySession
{
1239 fn fmt(&self, f
: &mut ::core
::fmt
::Formatter
<'_
>) -> ::core
::fmt
::Result
{
1240 f
.debug_tuple("UserActivitySession").field(&self.0).finish()
1243 impl ::windows
::core
::RuntimeType
for UserActivitySession
{
1244 const SIGNATURE
: ::windows
::imp
::ConstBuffer
= ::windows
::imp
::ConstBuffer
::from_slice(b
"rc(Windows.ApplicationModel.UserActivities.UserActivitySession;{ae434d78-24fa-44a3-ad48-6eda61aa1924})");
1246 impl ::core
::clone
::Clone
for UserActivitySession
{
1247 fn clone(&self) -> Self {
1248 Self(self.0.clone())
1251 unsafe impl ::windows
::core
::Interface
for UserActivitySession
{
1252 type Vtable
= IUserActivitySession_Vtbl
;
1254 unsafe impl ::windows
::core
::ComInterface
for UserActivitySession
{
1255 const IID
: ::windows
::core
::GUID
= <IUserActivitySession
as ::windows
::core
::ComInterface
>::IID
;
1257 impl ::windows
::core
::RuntimeName
for UserActivitySession
{
1258 const NAME
: &'
static str = "Windows.ApplicationModel.UserActivities.UserActivitySession";
1260 ::windows
::imp
::interface_hierarchy
!(UserActivitySession
, ::windows
::core
::IUnknown
, ::windows
::core
::IInspectable
);
1261 #[cfg(feature = "Foundation")]
1262 impl ::windows
::core
::CanTryInto
<super::super::Foundation
::IClosable
> for UserActivitySession {}
1263 unsafe impl ::core
::marker
::Send
for UserActivitySession {}
1264 unsafe impl ::core
::marker
::Sync
for UserActivitySession {}
1265 #[doc = "*Required features: `\"ApplicationModel_UserActivities\"`*"]
1266 #[repr(transparent)]
1267 pub struct UserActivitySessionHistoryItem(::windows
::core
::IUnknown
);
1268 impl UserActivitySessionHistoryItem
{
1269 pub fn UserActivity(&self) -> ::windows
::core
::Result
<UserActivity
> {
1272 let mut result__
= ::windows
::core
::zeroed
::<UserActivity
>();
1273 (::windows
::core
::Interface
::vtable(this
).UserActivity
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
1276 #[doc = "*Required features: `\"Foundation\"`*"]
1277 #[cfg(feature = "Foundation")]
1278 pub fn StartTime(&self) -> ::windows
::core
::Result
<super::super::Foundation
::DateTime
> {
1281 let mut result__
= ::windows
::core
::zeroed
::<super::super::Foundation
::DateTime
>();
1282 (::windows
::core
::Interface
::vtable(this
).StartTime
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
1285 #[doc = "*Required features: `\"Foundation\"`*"]
1286 #[cfg(feature = "Foundation")]
1287 pub fn EndTime(&self) -> ::windows
::core
::Result
<super::super::Foundation
::IReference
<super::super::Foundation
::DateTime
>> {
1290 let mut result__
= ::windows
::core
::zeroed
::<super::super::Foundation
::IReference
<super::super::Foundation
::DateTime
>>();
1291 (::windows
::core
::Interface
::vtable(this
).EndTime
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
1295 impl ::core
::cmp
::PartialEq
for UserActivitySessionHistoryItem
{
1296 fn eq(&self, other
: &Self) -> bool
{
1300 impl ::core
::cmp
::Eq
for UserActivitySessionHistoryItem {}
1301 impl ::core
::fmt
::Debug
for UserActivitySessionHistoryItem
{
1302 fn fmt(&self, f
: &mut ::core
::fmt
::Formatter
<'_
>) -> ::core
::fmt
::Result
{
1303 f
.debug_tuple("UserActivitySessionHistoryItem").field(&self.0).finish()
1306 impl ::windows
::core
::RuntimeType
for UserActivitySessionHistoryItem
{
1307 const SIGNATURE
: ::windows
::imp
::ConstBuffer
= ::windows
::imp
::ConstBuffer
::from_slice(b
"rc(Windows.ApplicationModel.UserActivities.UserActivitySessionHistoryItem;{e8d59bd3-3e5d-49fd-98d7-6da97521e255})");
1309 impl ::core
::clone
::Clone
for UserActivitySessionHistoryItem
{
1310 fn clone(&self) -> Self {
1311 Self(self.0.clone())
1314 unsafe impl ::windows
::core
::Interface
for UserActivitySessionHistoryItem
{
1315 type Vtable
= IUserActivitySessionHistoryItem_Vtbl
;
1317 unsafe impl ::windows
::core
::ComInterface
for UserActivitySessionHistoryItem
{
1318 const IID
: ::windows
::core
::GUID
= <IUserActivitySessionHistoryItem
as ::windows
::core
::ComInterface
>::IID
;
1320 impl ::windows
::core
::RuntimeName
for UserActivitySessionHistoryItem
{
1321 const NAME
: &'
static str = "Windows.ApplicationModel.UserActivities.UserActivitySessionHistoryItem";
1323 ::windows
::imp
::interface_hierarchy
!(UserActivitySessionHistoryItem
, ::windows
::core
::IUnknown
, ::windows
::core
::IInspectable
);
1324 unsafe impl ::core
::marker
::Send
for UserActivitySessionHistoryItem {}
1325 unsafe impl ::core
::marker
::Sync
for UserActivitySessionHistoryItem {}
1326 #[doc = "*Required features: `\"ApplicationModel_UserActivities\"`*"]
1327 #[repr(transparent)]
1328 pub struct UserActivityVisualElements(::windows
::core
::IUnknown
);
1329 impl UserActivityVisualElements
{
1330 pub fn DisplayText(&self) -> ::windows
::core
::Result
<::windows
::core
::HSTRING
> {
1333 let mut result__
= ::windows
::core
::zeroed
::<::windows
::core
::HSTRING
>();
1334 (::windows
::core
::Interface
::vtable(this
).DisplayText
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
1337 pub fn SetDisplayText(&self, value
: &::windows
::core
::HSTRING
) -> ::windows
::core
::Result
<()> {
1339 unsafe { (::windows::core::Interface::vtable(this).SetDisplayText)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(value)).ok() }
1341 pub fn Description(&self) -> ::windows
::core
::Result
<::windows
::core
::HSTRING
> {
1344 let mut result__
= ::windows
::core
::zeroed
::<::windows
::core
::HSTRING
>();
1345 (::windows
::core
::Interface
::vtable(this
).Description
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
1348 pub fn SetDescription(&self, value
: &::windows
::core
::HSTRING
) -> ::windows
::core
::Result
<()> {
1350 unsafe { (::windows::core::Interface::vtable(this).SetDescription)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(value)).ok() }
1352 #[doc = "*Required features: `\"UI\"`*"]
1353 #[cfg(feature = "UI")]
1354 pub fn BackgroundColor(&self) -> ::windows
::core
::Result
<super::super::UI
::Color
> {
1357 let mut result__
= ::windows
::core
::zeroed
::<super::super::UI
::Color
>();
1358 (::windows
::core
::Interface
::vtable(this
).BackgroundColor
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
1361 #[doc = "*Required features: `\"UI\"`*"]
1362 #[cfg(feature = "UI")]
1363 pub fn SetBackgroundColor(&self, value
: super::super::UI
::Color
) -> ::windows
::core
::Result
<()> {
1365 unsafe { (::windows::core::Interface::vtable(this).SetBackgroundColor)(::windows::core::Interface::as_raw(this), value).ok() }
1367 pub fn Attribution(&self) -> ::windows
::core
::Result
<UserActivityAttribution
> {
1370 let mut result__
= ::windows
::core
::zeroed
::<UserActivityAttribution
>();
1371 (::windows
::core
::Interface
::vtable(this
).Attribution
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
1374 pub fn SetAttribution(&self, value
: &UserActivityAttribution
) -> ::windows
::core
::Result
<()> {
1376 unsafe { (::windows::core::Interface::vtable(this).SetAttribution)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(value)).ok() }
1378 #[doc = "*Required features: `\"UI_Shell\"`*"]
1379 #[cfg(feature = "UI_Shell")]
1380 pub fn SetContent
<P0
>(&self, value
: P0
) -> ::windows
::core
::Result
<()>
1382 P0
: ::windows
::core
::TryIntoParam
<super::super::UI
::Shell
::IAdaptiveCard
>,
1385 unsafe { (::windows::core::Interface::vtable(this).SetContent)(::windows::core::Interface::as_raw(this), value.try_into_param()?.abi()).ok() }
1387 #[doc = "*Required features: `\"UI_Shell\"`*"]
1388 #[cfg(feature = "UI_Shell")]
1389 pub fn Content(&self) -> ::windows
::core
::Result
<super::super::UI
::Shell
::IAdaptiveCard
> {
1392 let mut result__
= ::windows
::core
::zeroed
::<super::super::UI
::Shell
::IAdaptiveCard
>();
1393 (::windows
::core
::Interface
::vtable(this
).Content
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
1396 pub fn AttributionDisplayText(&self) -> ::windows
::core
::Result
<::windows
::core
::HSTRING
> {
1397 let this
= &::windows
::core
::ComInterface
::cast
::<IUserActivityVisualElements2
>(self)?
;
1399 let mut result__
= ::windows
::core
::zeroed
::<::windows
::core
::HSTRING
>();
1400 (::windows
::core
::Interface
::vtable(this
).AttributionDisplayText
)(::windows
::core
::Interface
::as_raw(this
), &mut result__
).from_abi(result__
)
1403 pub fn SetAttributionDisplayText(&self, value
: &::windows
::core
::HSTRING
) -> ::windows
::core
::Result
<()> {
1404 let this
= &::windows
::core
::ComInterface
::cast
::<IUserActivityVisualElements2
>(self)?
;
1405 unsafe { (::windows::core::Interface::vtable(this).SetAttributionDisplayText)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(value)).ok() }
1408 impl ::core
::cmp
::PartialEq
for UserActivityVisualElements
{
1409 fn eq(&self, other
: &Self) -> bool
{
1413 impl ::core
::cmp
::Eq
for UserActivityVisualElements {}
1414 impl ::core
::fmt
::Debug
for UserActivityVisualElements
{
1415 fn fmt(&self, f
: &mut ::core
::fmt
::Formatter
<'_
>) -> ::core
::fmt
::Result
{
1416 f
.debug_tuple("UserActivityVisualElements").field(&self.0).finish()
1419 impl ::windows
::core
::RuntimeType
for UserActivityVisualElements
{
1420 const SIGNATURE
: ::windows
::imp
::ConstBuffer
= ::windows
::imp
::ConstBuffer
::from_slice(b
"rc(Windows.ApplicationModel.UserActivities.UserActivityVisualElements;{94757513-262f-49ef-bbbf-9b75d2e85250})");
1422 impl ::core
::clone
::Clone
for UserActivityVisualElements
{
1423 fn clone(&self) -> Self {
1424 Self(self.0.clone())
1427 unsafe impl ::windows
::core
::Interface
for UserActivityVisualElements
{
1428 type Vtable
= IUserActivityVisualElements_Vtbl
;
1430 unsafe impl ::windows
::core
::ComInterface
for UserActivityVisualElements
{
1431 const IID
: ::windows
::core
::GUID
= <IUserActivityVisualElements
as ::windows
::core
::ComInterface
>::IID
;
1433 impl ::windows
::core
::RuntimeName
for UserActivityVisualElements
{
1434 const NAME
: &'
static str = "Windows.ApplicationModel.UserActivities.UserActivityVisualElements";
1436 ::windows
::imp
::interface_hierarchy
!(UserActivityVisualElements
, ::windows
::core
::IUnknown
, ::windows
::core
::IInspectable
);
1437 unsafe impl ::core
::marker
::Send
for UserActivityVisualElements {}
1438 unsafe impl ::core
::marker
::Sync
for UserActivityVisualElements {}
1439 #[doc = "*Required features: `\"ApplicationModel_UserActivities\"`*"]
1440 #[repr(transparent)]
1441 #[derive(::core::cmp::PartialEq, ::core::cmp::Eq)]
1442 pub struct UserActivityState(pub i32);
1443 impl UserActivityState
{
1444 pub const New
: Self = Self(0i32);
1445 pub const Published
: Self = Self(1i32);
1447 impl ::core
::marker
::Copy
for UserActivityState {}
1448 impl ::core
::clone
::Clone
for UserActivityState
{
1449 fn clone(&self) -> Self {
1453 impl ::core
::default::Default
for UserActivityState
{
1454 fn default() -> Self {
1458 impl ::windows
::core
::TypeKind
for UserActivityState
{
1459 type TypeKind
= ::windows
::core
::CopyType
;
1461 impl ::core
::fmt
::Debug
for UserActivityState
{
1462 fn fmt(&self, f
: &mut ::core
::fmt
::Formatter
<'_
>) -> ::core
::fmt
::Result
{
1463 f
.debug_tuple("UserActivityState").field(&self.0).finish()
1466 impl ::windows
::core
::RuntimeType
for UserActivityState
{
1467 const SIGNATURE
: ::windows
::imp
::ConstBuffer
= ::windows
::imp
::ConstBuffer
::from_slice(b
"enum(Windows.ApplicationModel.UserActivities.UserActivityState;i4)");
1469 #[cfg(feature = "implement")]
1470 ::core
::include
!("impl.rs");