Bagikan melalui


RevocationAndRenewalInformation Kelas

Definisi

Berisi informasi tentang komponen yang perlu dicabut dan diperbarui.

public ref class RevocationAndRenewalInformation sealed
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
class RevocationAndRenewalInformation final
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
public sealed class RevocationAndRenewalInformation
Public NotInheritable Class RevocationAndRenewalInformation
Warisan
Object Platform::Object IInspectable RevocationAndRenewalInformation
Atribut

Persyaratan Windows

Rangkaian perangkat
Windows 10 (diperkenalkan dalam 10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (diperkenalkan dalam v1.0)

Contoh

Contoh ini menunjukkan ComponentLoadFailedEventHandler. Perulangan berulang melalui komponen yang gagal. Dan RenewSystemComponentsAsync dipanggil. Perhatikan bahwa RevocationAndRenewalInformation diteruskan melalui ComponentLoadFailedEventArgs.

private async void Manager_ComponentLoadFailed(MediaProtectionManager sender, ComponentLoadFailedEventArgs e)
{
    for (var i = 0; i < e.Information.Items.Count; i++)
    {
        Debug.WriteLine('Component Name=' +
                    e.Information.Items[i].Name +
                    "<BR/>");
        Debug.WriteLine('Failure Reason=' +
                    e.Information.Items[i].Reasons.ToString(16) +
                    "<BR/>");
        Debug.WriteLine('Renewal GUID=' +
                    e.Information.Items[i].RenewalId +
                    "<BR/>");
    }



    //  Invoke the revocation               
    var renewalStatus = await ComponentRenewal.RenewSystemComponentsAsync(e.Information);
    Debug.WriteLine("RenewSystemComponentsAsync: " +
                    renewalStatus.ToString() +
                    "<BR/>");

    e.Completion.Complete(false);
}

Keterangan

Instans objek ini dikembalikan oleh properti ComponentLoadFailedEventArgs.Information .

Properti

Items

Mengembalikan daftar komponen yang perlu dicabut dan diperbarui dengan komponen yang diperbarui.

Berlaku untuk