From 20ac23de3ce3cb1a75315a1be2818f179be697fd Mon Sep 17 00:00:00 2001 From: dahall Date: Mon, 5 Apr 2021 20:23:18 -0600 Subject: [PATCH] Updated XML documentation for IMAPI --- PInvoke/IMAPI/IMAPIv2.cs | 16 +++------------- PInvoke/IMAPI/IMAPIv2FS.cs | 6 ++++-- 2 files changed, 7 insertions(+), 15 deletions(-) diff --git a/PInvoke/IMAPI/IMAPIv2.cs b/PInvoke/IMAPI/IMAPIv2.cs index 71f2c093..6ba8f6af 100644 --- a/PInvoke/IMAPI/IMAPIv2.cs +++ b/PInvoke/IMAPI/IMAPIv2.cs @@ -297,7 +297,8 @@ namespace Vanara.PInvoke public class DDiscMaster2EventsSink : DDiscMaster2Events { /// Initializes a new instance of the class. - /// The on update. + /// The delegate to call when a device is added. + /// The delegate to call when a device is removed. public DDiscMaster2EventsSink(Action onAdded, Action onRemoved) { if (onAdded is not null) NotifyDeviceAdded += onAdded; @@ -3216,6 +3217,7 @@ namespace Vanara.PInvoke } /// Reads a DVD structure from the media. + /// The instance. /// /// Format field of the command packet. Acceptable values range from zero to 0xFF. /// Note This value is truncated to UCHAR. @@ -3325,18 +3327,6 @@ namespace Vanara.PInvoke IMAPI_MEDIA_PHYSICAL_TYPE[] SupportedMediaTypes { [return: MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef = typeof(SafeArrayMarshaler))] get; } } - public static IMAPI_MEDIA_PHYSICAL_TYPE GetCurrentPhysicalMediaType(this IDiscFormat2 formatter) => - (IMAPI_MEDIA_PHYSICAL_TYPE)formatter.GetType().InvokeMember("CurrentPhysicalMediaType", System.Reflection.BindingFlags.GetProperty, null, formatter, null); - - public static IDiscRecorder2 GetRecorder(this IDiscFormat2 formatter) => - (IDiscRecorder2)formatter.GetType().InvokeMember("Recorder", System.Reflection.BindingFlags.GetProperty, null, formatter, null); - - public static void SetRecorder(this IDiscFormat2 formatter, IDiscRecorder2 recorder) => - formatter.GetType().InvokeMember("Recorder", System.Reflection.BindingFlags.SetProperty, null, formatter, new object[] { recorder }); - - public static void SetClientName(this IDiscFormat2 formatter, string clientName) => - formatter.GetType().InvokeMember("ClientName", System.Reflection.BindingFlags.SetProperty, null, formatter, new object[] { clientName }); - /// /// Base interface containing properties common to derived multisession interfaces. /// diff --git a/PInvoke/IMAPI/IMAPIv2FS.cs b/PInvoke/IMAPI/IMAPIv2FS.cs index 947d5ee7..e82f2e5c 100644 --- a/PInvoke/IMAPI/IMAPIv2FS.cs +++ b/PInvoke/IMAPI/IMAPIv2FS.cs @@ -285,11 +285,13 @@ namespace Vanara.PInvoke long totalFileItems); } + /// Sink implementation for . + /// [ClassInterface(ClassInterfaceType.None)] public class DFileSystemImageImportEventsSink : DFileSystemImageImportEvents { - /// Initializes a new instance of the class. - /// The delegate to assign to the event. + /// Initializes a new instance of the class. + /// The delegate to call on import update. public DFileSystemImageImportEventsSink(Action onUpdateImport) { if (onUpdateImport is not null) UpdateImport += onUpdateImport;