/// <summary> Decode exception. </summary> /// <param name="wand"> Handle of the wand. </param> /// <returns> A string. </returns> private static string DecodeException(IWandCore wand) { int exceptionSeverity; IntPtr exceptionPtr = wand.GetException(out exceptionSeverity); wand.ClearException(); return WandNativeString.Load(exceptionPtr); }
/// <summary> Decode exception. </summary> /// <param name="wand"> Handle of the wand. </param> /// <returns> A string. </returns> private static string DecodeException(IWandCore wand) { int exceptionSeverity; IntPtr exceptionPtr = wand.GetException(out exceptionSeverity); wand.ClearException(); return(WandNativeString.Load(exceptionPtr)); }
/// <summary> /// Initializes a new instance of the ImageMagickSharp.WandException class. </summary> /// <param name="wand"> Handle of the wand. </param> internal WandException(IWandCore wand) : base(DecodeException(wand)) { }