private void LibraryLoadFailureHandler(object sender, LibraryLoadFailedEventArgs args) { LibraryLoadFailedException ex = new LibraryLoadFailedException(args.LibraryPath, args.Reason); Log(ex.Message, WarningLevel.Moderate); throw ex; }
private void OnLibraryLoadFailed(LibraryLoadFailedEventArgs e) { EventHandler <LibraryLoadFailedEventArgs> handler = LibraryLoadFailed; if (handler != null) { handler(this, e); } }
private void LibraryLoadFailureHandler(object sender, LibraryLoadFailedEventArgs args) { LibraryLoadFailedException ex = new LibraryLoadFailedException(args.LibraryPath, args.Reason); Log(ex.Message, WarningLevel.Moderate); // NOTE: We do not want to throw an exception here if the failure was due // to a missing library that was explicitly (attempted to be) loaded // but was moved or deleted OR if a .DS file with syntax error(s) is loaded if (args.ThrowOnFailure) { throw ex; } }