You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Gets the value that indicates whether this app view is hosted or not.
13
+
14
+
Gets the value that indicates whether this app view is hosted.
14
15
15
16
## -property-value
16
-
If **true**, this app view is hosted; if **false**, it is not.
17
+
18
+
If **true**, this app view is hosted; if **false**, it isn't.
17
19
18
20
## -remarks
19
-
An app view is considered hosted when the process that launched it controls its lifetime. For example, the window that opens when a [FileOpenPicker](../windows.storage.pickers/fileopenpicker.md) is launched is considered hosted.
21
+
22
+
An app view is hosted when the process that launches it controls its lifetime. For example, the window that opens when a [FileOpenPicker](../windows.storage.pickers/fileopenpicker.md) is launched is hosted.
20
23
21
24
## -examples
22
25
26
+
Here's a simple example that demonstrates how to use the `IsHosted` property:
Manages access for drag and drop within and between apps.
15
16
16
17
## -remarks
17
18
18
19
## -examples
20
+
21
+
The following example demonstrates how to use the `CoreDragDropManager` to set up a drag-and-drop target that filters incoming data and delegates handling to a specified control.
Sets the data contained in the [DataPackage](datapackage.md) in a [RandomAccessStream](../windows.storage.streams/randomaccessstream.md) format.
14
15
15
16
## -parameters
17
+
16
18
### -param formatId
17
-
Specifies the format of the data. We recommend that you set this value by using the [StandardDataFormats](standarddataformats.md) class.
19
+
20
+
Specifies the format of the data. Set this value by using the [StandardDataFormats](standarddataformats.md) class.
18
21
19
22
### -param value
23
+
20
24
Specifies the content that the [DataPackage](datapackage.md) contains.
21
25
22
26
## -remarks
23
-
To add data using this method, your app must convert the data into an object. You must also specify a *formatId* that target apps can use to request the data. Note that the target app can request this data only if it knows the *formatId*.
24
27
25
-
This method is often used when you use a delegate function to share data. For more information, see [How to support pull operations](/previous-versions/windows/apps/hh770848(v=win.10)).
28
+
To add data with this method, your app must convert the data into an object. You must also specify a *formatId* that target apps can use to request the data. The target app can request this data only if it knows the *formatId*.
29
+
30
+
Use this method when you use a delegate function to share data. For more information, see [How to support pull operations](/previous-versions/windows/apps/hh770848(v=win.10)).
26
31
27
32
## -examples
28
33
34
+
The following example demonstrates how to use the **SetData** method to serialize a custom C# object into a **RandomAccessStream** and pass it to the **DataPackage**. It also shows how to deserialize the data back to the original object type by using [GetDataAsync](datapackageview_getdataasync_225712847.md).
35
+
36
+
```csharp
37
+
usingSystem;
38
+
usingSystem.IO;
39
+
usingSystem.Runtime.Serialization;
40
+
usingWindows.ApplicationModel.DataTransfer;
41
+
usingWindows.Storage.Streams;
42
+
43
+
// Define a custom class to serialize
44
+
[DataContract]
45
+
publicclassPersonData
46
+
{
47
+
[DataMember]
48
+
publicstringName { get; set; }
49
+
50
+
[DataMember]
51
+
publicintAge { get; set; }
52
+
53
+
[DataMember]
54
+
publicstringEmail { get; set; }
55
+
}
56
+
57
+
// Method to serialize object and set data in DataPackage
1.**Serialization**: Use **DataContractSerializer** to serialize a custom object and convert it to an **InMemoryRandomAccessStream** suitable for **SetData**.
168
+
1.**Setting Data**: Call **SetData** with a custom format identifier and the serialized stream.
169
+
1.**Deserialization**: Retrieve the data by using **GetDataAsync** and deserialize it back to the original object type.
170
+
1.**Error Handling**: Implement basic error handling for serialization and deserialization operations.
171
+
172
+
> [!NOTE]
173
+
> This example uses **DataContractSerializer**, which is safer and more modern than the deprecated **BinaryFormatter**. To ensure proper serialization support, add the `[DataContract]` and `[DataMember]` attributes to your custom classes.
Gets the string representation of the [GUID](/windows/win32/api/guiddef/ns-guiddef-guid) for the AV1 video subtype.
16
+
17
+
## -property-value
18
+
19
+
The string representation of the AV1 video subtype.
20
+
21
+
## -remarks
22
+
23
+
This GUID matches the value of the Media Foundation subtype [MFVideoFormat_AV1](/windows/win32/medfound/video-subtype-guids), defined using the FOURCC 'AV01'.
Copy file name to clipboardExpand all lines: windows.security.credentials/keycredentialmanager.md
+26-1Lines changed: 26 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,8 +16,33 @@ Contains methods for basic management of key credentials.
16
16
17
17
## -remarks
18
18
19
+
The `KeyCredentialManager` class provides methods to manage key credentials, which are RSA 2048-bit keys. These keys are used for secure authentication and cryptographic operations.
20
+
21
+
#### Key Information
22
+
23
+
-**Key Type**: RSA 2048-bit
24
+
-**Signature Format**: PKCS #1 RSA PSS with SHA256
25
+
-**Attestation Data**: The attestation data is a binary blob that includes metadata about the key, such as its origin and security properties.
26
+
27
+
#### Attestation Data Format
28
+
29
+
The attestation data is encoded in a binary format. It includes:
30
+
31
+
1.**Key Metadata**: Information about the key's origin and properties.
32
+
1.**Certificate Chain**: A chain of certificates that can be used to verify the authenticity of the attestation.
33
+
34
+
#### Verifying Attestation Data
35
+
36
+
To verify the attestation data:
37
+
38
+
1. Parse the binary blob to extract the metadata and certificate chain.
39
+
1. Use the certificate chain to validate the authenticity of the attestation.
40
+
1. Ensure the metadata matches the expected properties of the key.
41
+
42
+
For more details, refer to the [KeyCredentialManager sample](https://github.com/Microsoft/Windows-universal-samples/tree/main/Samples/KeyCredentialManager).
0 commit comments