NanoXLSX.Reader 3.0.0-rc.5
Loading...
Searching...
No Matches
ReaderPlugInHandler.cs
1/*
2 * NanoXLSX is a small .NET library to generate and read XLSX (Microsoft Excel 2007 or newer) files in an easy and native way
3 * Copyright Raphael Stoeckli © 2026
4 * This library is licensed under the MIT License.
5 * You find a copy of the license in project folder or on: http://opensource.org/licenses/MIT
6 */
7
8using System.IO;
9using NanoXLSX.Interfaces;
10using NanoXLSX.Interfaces.Reader;
11using NanoXLSX.Registry;
12
14{
18 internal static class ReaderPlugInHandler
19 {
28 internal static void HandleInlineQueuePlugins(MemoryStream stream, Workbook workbook, string queueUuid, IOptions readerOptions, int? index)
29 {
30 IPluginInlineReader queueReader = null;
31 string lastUuid = null;
32 do
33 {
34 string currentUuid;
35 queueReader = PlugInLoader.GetNextQueuePlugIn<IPluginInlineReader>(queueUuid, lastUuid, out currentUuid);
36 if (queueReader != null)
37 {
38 stream.Position = 0;
39 queueReader.Init(stream, workbook, readerOptions, index);
40 queueReader.Execute();
41 lastUuid = currentUuid;
42 }
43 else
44 {
45 lastUuid = null;
46 }
47
48 } while (queueReader != null);
49 }
50 }
51}