# System.Runtime.InteropServices.WindowsRuntime ``` diff +namespace System.Runtime.InteropServices.WindowsRuntime { + public sealed class DefaultInterfaceAttribute : Attribute { + public DefaultInterfaceAttribute(Type defaultInterface); + public Type DefaultInterface { get; } + } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public struct EventRegistrationToken { + public override bool Equals(object obj); + public override int GetHashCode(); + public static bool operator ==(EventRegistrationToken left, EventRegistrationToken right); + public static bool operator !=(EventRegistrationToken left, EventRegistrationToken right); + } + public sealed class EventRegistrationTokenTable where T : class { + public EventRegistrationTokenTable(); + public T InvocationList { get; set; } + public EventRegistrationToken AddEventHandler(T handler); + public static EventRegistrationTokenTable GetOrCreateEventRegistrationTokenTable(ref EventRegistrationTokenTable refEventTable); + public void RemoveEventHandler(EventRegistrationToken token); + public void RemoveEventHandler(T handler); + } + public interface IActivationFactory { + object ActivateInstance(); + } + public sealed class InterfaceImplementedInVersionAttribute : Attribute { + public InterfaceImplementedInVersionAttribute(Type interfaceType, byte majorVersion, byte minorVersion, byte buildVersion, byte revisionVersion); + public byte BuildVersion { get; } + public Type InterfaceType { get; } + public byte MajorVersion { get; } + public byte MinorVersion { get; } + public byte RevisionVersion { get; } + } + public sealed class ReadOnlyArrayAttribute : Attribute { + public ReadOnlyArrayAttribute(); + } + public sealed class ReturnValueNameAttribute : Attribute { + public ReturnValueNameAttribute(string name); + public string Name { get; } + } + public static class WindowsRuntimeMarshal { + public static void AddEventHandler(Func addMethod, Action removeMethod, T handler); + public static void FreeHString(IntPtr ptr); + public static IActivationFactory GetActivationFactory(Type type); + public static string PtrToStringHString(IntPtr ptr); + public static void RemoveAllEventHandlers(Action removeMethod); + public static void RemoveEventHandler(Action removeMethod, T handler); + public static IntPtr StringToHString(string s); + } + public sealed class WriteOnlyArrayAttribute : Attribute { + public WriteOnlyArrayAttribute(); + } +} ```