aboutsummaryrefslogtreecommitdiff
path: root/RhSolutions.ExcelExtensions/RowEnumerator.cs
diff options
context:
space:
mode:
Diffstat (limited to 'RhSolutions.ExcelExtensions/RowEnumerator.cs')
-rw-r--r--RhSolutions.ExcelExtensions/RowEnumerator.cs54
1 files changed, 0 insertions, 54 deletions
diff --git a/RhSolutions.ExcelExtensions/RowEnumerator.cs b/RhSolutions.ExcelExtensions/RowEnumerator.cs
deleted file mode 100644
index fd56dcd..0000000
--- a/RhSolutions.ExcelExtensions/RowEnumerator.cs
+++ /dev/null
@@ -1,54 +0,0 @@
-using System.Collections;
-
-namespace RhSolutions.ExcelExtensions;
-
-public class RowEnumerator : IEnumerator<TableCell>
-{
- public Range Range { get; }
- public Table ParentTable { get; }
- private int position = 0;
- object IEnumerator.Current
- {
- get
- {
- return Current;
- }
- }
-
- public TableCell Current
- {
- get
- {
- try
- {
- return new TableCell(Range.Cells[1, position], ParentTable);
- }
- catch (IndexOutOfRangeException)
- {
- throw new InvalidOperationException();
- }
- }
- }
-
- public RowEnumerator(Range range, Table parentTable)
- {
- Range = range;
- ParentTable = parentTable;
- }
-
- public bool MoveNext()
- {
- position++;
- return (position <= Range.Columns.Count);
- }
-
- public void Reset()
- {
- position = 0;
- }
-
- public void Dispose()
- {
-
- }
-} \ No newline at end of file