• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

MorganKryze / ConsoleAppVisuals / 8114215569

01 Mar 2024 04:29PM UTC coverage: 85.767% (-9.3%) from 95.093%
8114215569

push

github

MorganKryze
🤖 moved to publish

865 of 1072 branches covered (80.69%)

Branch coverage included in aggregate %.

1708 of 1928 relevant lines covered (88.59%)

273.5 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

92.12
/src/ConsoleAppVisuals/elements/static_elements/TableView.cs
1
/*
2
    GNU GPL License 2024 MorganKryze(Yann Vidamment)
3
    For full license information, please visit: https://github.com/MorganKryze/ConsoleAppVisuals/blob/main/LICENSE
4
*/
5
namespace ConsoleAppVisuals.Elements;
6

7
/// <summary>
8
/// The <see cref="TableView{T}"/> class that contains the methods to create a table and display it.
9
/// </summary>
10
public class TableView<T> : Element
11
{
12
    #region Fields: title, headers, lines, display array, rounded corners
13
    private string? _title;
14
    private List<string>? _rawHeaders;
15
    private List<List<T>>? _rawLines;
16
    private string[]? _displayArray;
17
    private bool _roundedCorners;
18
    private readonly Placement _placement;
19
    #endregion
20

21
    #region Properties: get headers, get lines
22
    /// <summary>
23
    /// This property returns the headers of the table.
24
    /// </summary>
25
    public List<string>? GetRawHeaders => _rawHeaders;
18✔
26

27
    /// <summary>
28
    /// This property returns the lines of the table.
29
    /// </summary>
30
    public List<List<T>>? GetRawLines => _rawLines;
15✔
31

32
    /// <summary>
33
    /// This property returns the title of the table.
34
    /// </summary>
35
    public override Placement Placement => _placement;
24✔
36

37
    /// <summary>
38
    /// This property returns the height of the table.
39
    /// </summary>
40
    public override int Height => _displayArray?.Length ?? 0;
27✔
41

42
    /// <summary>
43
    /// This property returns the width of the table.
44
    /// </summary>
45
    public override int Width => _displayArray?.Max(x => x.Length) ?? 0;
3!
46

47
    /// <summary>
48
    /// This property returns the maximum number of this element that can be displayed on the console.
49
    /// </summary>
50
    public override int MaxNumberOfThisElement { get; } = 9;
174✔
51

52
    #endregion
53

54
    #region Constructor
55
    /// <summary>
56
    /// The <see cref="TableView{T}"/> natural constructor.
57
    /// </summary>
58
    /// <param name="title">The title of the table.</param>
59
    /// <param name="headers">The headers of the table.</param>
60
    /// <param name="lines">The lines of the table.</param>
61
    /// <param name="roundedCorners">The rounded corners of the table.</param>
62
    /// <param name="placement">The placement of the table.</param>
63
    /// <exception cref="ArgumentException">Is thrown when the number of columns in the table is not consistent with itself or with the headers.</exception>
64
    /// <exception cref="NullReferenceException">Is thrown when no body lines were provided.</exception>
65
    /// <remarks>Refer to the example project to understand how to implement it available at https://github.com/MorganKryze/ConsoleAppVisuals/blob/main/example/ </remarks>
66
    public TableView(
168✔
67
        string? title = null,
168✔
68
        List<string>? headers = null,
168✔
69
        List<List<T>>? lines = null,
168✔
70
        bool roundedCorners = false,
168✔
71
        Placement placement = Placement.TopCenter
168✔
72
    )
168✔
73
    {
74
        _title = title;
168✔
75
        _rawHeaders = headers;
168✔
76
        _rawLines = lines;
168✔
77
        _roundedCorners = roundedCorners;
168✔
78
        _placement = placement;
168✔
79
        if (CompatibilityCheck())
168✔
80
        {
81
            BuildTable();
144✔
82
        }
83
    }
162✔
84
    #endregion
85

86
    #region Check Methods
87
    private bool CompatibilityCheck()
88
    {
89
        if (_rawHeaders is null)
177✔
90
        {
91
            return CheckRawLines();
21✔
92
        }
93
        else if (_rawLines is null)
156✔
94
        {
95
            return true;
3✔
96
        }
97
        else
98
        {
99
            return CheckRawHeadersAndLines();
153✔
100
        }
101
    }
102

103
    private bool CheckRawLines()
104
    {
105
        if (_rawLines is null || _rawLines.Count == 0)
21✔
106
        {
107
            return false;
6✔
108
        }
109

110
        for (int i = 0; i < _rawLines.Count; i++)
84✔
111
        {
112
            if (_rawLines[i].Count != _rawLines[0].Count)
30✔
113
            {
114
                throw new ArgumentException(
3✔
115
                    "The number of columns in the table is not consistent."
3✔
116
                );
3✔
117
            }
118
        }
119
        return true;
12✔
120
    }
121

122
    private bool CheckRawHeadersAndLines()
123
    {
124
        if (_rawLines is null || _rawLines.Count == 0)
153✔
125
        {
126
            return false;
12✔
127
        }
128

129
        if (_rawLines.Count > 0)
141✔
130
        {
131
            for (int i = 0; i < _rawLines.Count; i++)
798✔
132
            {
133
                if (_rawLines[i].Count != _rawHeaders?.Count)
264!
134
                {
135
                    throw new ArgumentException(
6✔
136
                        "The number of columns in the table is not consistent(Headers or Lines)."
6✔
137
                    );
6✔
138
                }
139
            }
140
        }
141
        return true;
135✔
142
    }
143
    #endregion
144

145
    #region Build Methods
146
    private void BuildTable()
147
    {
148
        if (_rawHeaders is null)
204✔
149
        {
150
            if (_rawLines is not null)
30✔
151
            {
152
                BuildLines();
24✔
153
            }
154
        }
155
        else
156
        {
157
            if (_rawLines is null)
174✔
158
            {
159
                BuildHeaders();
6✔
160
            }
161
            else
162
            {
163
                BuildHeadersAndLines();
168✔
164
            }
165
        }
166
    }
174✔
167

168
    private void BuildHeadersAndLines()
169
    {
170
        if (_rawHeaders is not null && _rawLines is not null)
168✔
171
        {
172
            var stringList = new List<string>();
168✔
173
            var localMax = new int[_rawHeaders.Count];
168✔
174
            for (int i = 0; i < _rawHeaders.Count; i++)
1,344✔
175
            {
176
                if (_rawHeaders[i]?.Length > localMax[i])
504!
177
                {
178
                    localMax[i] = _rawHeaders[i]?.Length ?? 0;
504!
179
                }
180
            }
181

182
            for (int i = 0; i < _rawLines.Count; i++)
900✔
183
            {
184
                for (int j = 0; j < _rawLines[i].Count; j++)
2,256✔
185
                {
186
                    if (_rawLines[i][j]?.ToString()?.Length > localMax[j])
846!
187
                    {
188
                        localMax[j] = _rawLines[i][j]?.ToString()?.Length ?? 0;
×
189
                    }
190
                }
191
            }
192

193
            StringBuilder headerBuilder = new("│ ");
168✔
194
            for (int i = 0; i < _rawHeaders.Count; i++)
1,344✔
195
            {
196
                headerBuilder.Append(_rawHeaders[i]?.PadRight(localMax[i]) ?? "");
504!
197
                if (i != _rawHeaders.Count - 1)
504✔
198
                {
199
                    headerBuilder.Append(" │ ");
336✔
200
                }
201
                else
202
                {
203
                    headerBuilder.Append(" │");
168✔
204
                }
205
            }
206
            stringList.Add(headerBuilder.ToString());
168✔
207

208
            StringBuilder upperBorderBuilder = new(GetCorners[0].ToString());
168✔
209
            for (int i = 0; i < _rawHeaders.Count; i++)
1,344✔
210
            {
211
                upperBorderBuilder.Append(new string('─', localMax[i] + 2));
504✔
212
                upperBorderBuilder.Append(
504✔
213
                    (i != _rawHeaders.Count - 1) ? "┬" : GetCorners[1].ToString()
504✔
214
                );
504✔
215
            }
216
            stringList.Insert(0, upperBorderBuilder.ToString());
168✔
217

218
            StringBuilder intermediateBorderBuilder = new("├");
168✔
219
            for (int i = 0; i < _rawHeaders.Count; i++)
1,344✔
220
            {
221
                intermediateBorderBuilder.Append(new string('─', localMax[i] + 2));
504✔
222
                intermediateBorderBuilder.Append((i != _rawHeaders.Count - 1) ? "┼" : "┤");
504✔
223
            }
224
            stringList.Add(intermediateBorderBuilder.ToString());
168✔
225

226
            for (int i = 0; i < _rawLines.Count; i++)
900✔
227
            {
228
                StringBuilder lineBuilder = new("│ ");
282✔
229
                for (int j = 0; j < _rawLines[i].Count; j++)
2,256✔
230
                {
231
                    lineBuilder.Append(_rawLines[i][j]?.ToString()?.PadRight(localMax[j]) ?? "");
846!
232
                    if (j != _rawLines[i].Count - 1)
846✔
233
                    {
234
                        lineBuilder.Append(" │ ");
564✔
235
                    }
236
                    else
237
                    {
238
                        lineBuilder.Append(" │");
282✔
239
                    }
240
                }
241
                stringList.Add(lineBuilder.ToString());
282✔
242
            }
243

244
            StringBuilder lowerBorderBuilder = new(GetCorners[2].ToString());
168✔
245
            for (int i = 0; i < _rawHeaders.Count; i++)
1,344✔
246
            {
247
                lowerBorderBuilder.Append(new string('─', localMax[i] + 2));
504✔
248
                lowerBorderBuilder.Append(
504✔
249
                    (i != _rawHeaders.Count - 1) ? "┴" : GetCorners[3].ToString()
504✔
250
                );
504✔
251
            }
252
            stringList.Add(lowerBorderBuilder.ToString());
168✔
253

254
            _displayArray = stringList.ToArray();
168✔
255
            BuildTitle();
168✔
256
        }
257
    }
168✔
258

259
    private void BuildHeaders()
260
    {
261
        if (_rawHeaders is not null)
6✔
262
        {
263
            var stringList = new List<string>();
6✔
264
            var localMax = new int[_rawHeaders.Count];
6✔
265
            for (int i = 0; i < _rawHeaders.Count; i++)
48✔
266
            {
267
                if (_rawHeaders[i]?.Length > localMax[i])
18!
268
                {
269
                    localMax[i] = _rawHeaders[i]?.Length ?? 0;
18!
270
                }
271
            }
272
            StringBuilder headerBuilder = new("│ ");
6✔
273
            for (int i = 0; i < _rawHeaders.Count; i++)
48✔
274
            {
275
                headerBuilder.Append(_rawHeaders[i]?.PadRight(localMax[i]) ?? "");
18!
276
                if (i != _rawHeaders.Count - 1)
18✔
277
                {
278
                    headerBuilder.Append(" │ ");
12✔
279
                }
280
                else
281
                {
282
                    headerBuilder.Append(" │");
6✔
283
                }
284
            }
285
            stringList.Add(headerBuilder.ToString());
6✔
286
            StringBuilder upperBorderBuilder = new(GetCorners[0].ToString());
6✔
287
            for (int i = 0; i < _rawHeaders.Count; i++)
48✔
288
            {
289
                upperBorderBuilder.Append(new string('─', localMax[i] + 2));
18✔
290
                upperBorderBuilder.Append(
18✔
291
                    (i != _rawHeaders.Count - 1) ? "┬" : GetCorners[1].ToString()
18✔
292
                );
18✔
293
            }
294
            stringList.Insert(0, upperBorderBuilder.ToString());
6✔
295
            StringBuilder lowerBorderBuilder = new(GetCorners[2].ToString());
6✔
296
            for (int i = 0; i < _rawHeaders.Count; i++)
48✔
297
            {
298
                lowerBorderBuilder.Append(new string('─', localMax[i] + 2));
18✔
299
                lowerBorderBuilder.Append(
18✔
300
                    (i != _rawHeaders.Count - 1) ? "┴" : GetCorners[3].ToString()
18✔
301
                );
18✔
302
            }
303
            stringList.Add(lowerBorderBuilder.ToString());
6✔
304
            _displayArray = stringList.ToArray();
6✔
305
            BuildTitle();
6✔
306
        }
307
    }
6✔
308

309
    private void BuildLines()
310
    {
311
        if (_rawLines is not null)
24✔
312
        {
313
            var stringList = new List<string>();
24✔
314
            var localMax = new int[_rawLines[0].Count];
24✔
315
            for (int i = 0; i < _rawLines.Count; i++)
132✔
316
            {
317
                for (int j = 0; j < _rawLines[i].Count; j++)
336✔
318
                {
319
                    if (_rawLines[i][j]?.ToString()?.Length > localMax[j])
126!
320
                    {
321
                        localMax[j] = _rawLines[i][j]?.ToString()?.Length ?? 0;
72!
322
                    }
323
                }
324
            }
325
            for (int i = 0; i < _rawLines.Count; i++)
132✔
326
            {
327
                StringBuilder line = new("│ ");
42✔
328
                for (int j = 0; j < _rawLines[i].Count; j++)
336✔
329
                {
330
                    line.Append(_rawLines[i][j]?.ToString()?.PadRight(localMax[j]) ?? "");
126!
331
                    if (j != _rawLines[i].Count - 1)
126✔
332
                    {
333
                        line.Append(" │ ");
84✔
334
                    }
335
                    else
336
                    {
337
                        line.Append(" │");
42✔
338
                    }
339
                }
340
                stringList.Add(line.ToString());
42✔
341
            }
342
            StringBuilder upperBorderBuilder = new(GetCorners[0].ToString());
24✔
343
            for (int i = 0; i < _rawLines.Count; i++)
132✔
344
            {
345
                upperBorderBuilder.Append(new string('─', localMax[i] + 2));
42✔
346
                upperBorderBuilder.Append(
42✔
347
                    (i != _rawLines.Count - 1) ? "┬" : GetCorners[1].ToString()
42✔
348
                );
42✔
349
            }
350
            stringList.Insert(0, upperBorderBuilder.ToString());
24✔
351
            StringBuilder lowerBorderBuilder = new(GetCorners[2].ToString());
24✔
352
            for (int i = 0; i < _rawLines.Count; i++)
132✔
353
            {
354
                lowerBorderBuilder.Append(new string('─', localMax[i] + 2));
42✔
355
                lowerBorderBuilder.Append(
42✔
356
                    (i != _rawLines.Count - 1) ? "┴" : GetCorners[3].ToString()
42✔
357
                );
42✔
358
            }
359
            stringList.Add(lowerBorderBuilder.ToString());
24✔
360
            _displayArray = stringList.ToArray();
24✔
361
            BuildTitle();
24✔
362
        }
363
    }
24✔
364

365
    private void BuildTitle()
366
    {
367
        if (_title is not null)
198✔
368
        {
369
            var len = _displayArray![0].Length;
30✔
370
            var title = _title.ResizeString(len - 4);
30✔
371
            title = $"│ {title} │";
30✔
372
            var upperBorderBuilder = new StringBuilder(GetCorners[0].ToString());
30✔
373
            upperBorderBuilder.Append(new string('─', len - 2));
30✔
374
            upperBorderBuilder.Append(GetCorners[1].ToString());
30✔
375
            var display = _displayArray.ToList();
30✔
376
            display[0] = display[0]
30✔
377
                .Remove(0, 1)
30✔
378
                .Insert(0, "├")
30✔
379
                .Remove(display[1].Length - 1, 1)
30✔
380
                .Insert(display[1].Length - 1, "┤");
30✔
381
            display.Insert(0, title);
30✔
382
            display.Insert(0, upperBorderBuilder.ToString());
30✔
383
            _displayArray = display.ToArray();
30✔
384
        }
385
    }
198✔
386
    #endregion
387

388
    #region Properties: GetCorners, Count
389
    private string GetCorners => _roundedCorners ? "╭╮╰╯" : "┌┐└┘";
852✔
390

391
    /// <summary>
392
    /// This property returns the number of lines in the table.
393
    /// </summary>
394
    public int Count => _rawLines?.Count ?? 0;
24✔
395

396
    #endregion
397

398
    #region Methods: Get, Add, Update, Remove, Clear
399
    /// <summary>
400
    /// Toggles the rounded corners of the table.
401
    /// </summary>
402
    /// <remarks>Refer to the example project to understand how to implement it available at https://github.com/MorganKryze/ConsoleAppVisuals/blob/main/example/ </remarks>
403
    public void SetRoundedCorners(bool rounded = true)
404
    {
405
        _roundedCorners = rounded;
6✔
406
        BuildTable();
6✔
407
    }
6✔
408

409
    /// <summary>
410
    /// This method adds a title to the table.
411
    /// </summary>
412
    /// <param name="title">The title to add.</param>
413
    public void AddTitle(string title)
414
    {
415
        _title = title;
6✔
416
        BuildTable();
6✔
417
    }
6✔
418

419
    /// <summary>
420
    /// This method updates the title of the table.
421
    /// </summary>
422
    /// <param name="title">The title to update.</param>
423
    public void UpdateTitle(string title)
424
    {
425
        AddTitle(title);
3✔
426
    }
3✔
427

428
    /// <summary>
429
    /// This method clears the title of the table.
430
    /// </summary>
431
    public void ClearTitle()
432
    {
433
        _title = null;
9✔
434
        BuildTable();
9✔
435
    }
9✔
436

437
    /// <summary>
438
    /// This method adds headers to the table.
439
    /// </summary>
440
    /// <param name="headers">The headers to add.</param>
441
    public void AddHeaders(List<string> headers)
442
    {
443
        _rawHeaders = headers;
9✔
444
        if (CompatibilityCheck())
9✔
445
        {
446
            BuildTable();
6✔
447
        }
448
    }
6✔
449

450
    /// <summary>
451
    /// This method updates the headers of the table.
452
    /// </summary>
453
    /// <param name="headers">The headers to update.</param>
454
    public void UpdateHeaders(List<string> headers)
455
    {
456
        AddHeaders(headers);
3✔
457
    }
3✔
458

459
    /// <summary>
460
    /// This method clears the headers of the table.
461
    /// </summary>
462
    public void ClearHeaders()
463
    {
464
        _rawHeaders = null;
12✔
465
        BuildTable();
12✔
466
    }
12✔
467

468
    /// <summary>
469
    /// This method adds a line to the table.
470
    /// </summary>
471
    /// <param name="line">The line to add.</param>
472
    /// <exception cref="ArgumentException">Is thrown when the number of columns in the table is not consistent with itself or with the headers.</exception>
473
    /// <remarks>Refer to the example project to understand how to implement it available at https://github.com/MorganKryze/ConsoleAppVisuals/blob/main/example/ </remarks>
474
    public void AddLine(List<T> line)
475
    {
476
        if (_rawLines?.Count > 0 && line.Count != _rawLines[0].Count)
12✔
477
        {
478
            throw new ArgumentException(
3✔
479
                "The number of columns in the table is not consistent with other lines."
3✔
480
            );
3✔
481
        }
482
        if (_rawHeaders is not null && line.Count != _rawHeaders.Count)
9✔
483
        {
484
            throw new ArgumentException(
3✔
485
                "The number of columns in the table is not consistent with the headers."
3✔
486
            );
3✔
487
        }
488
        _rawLines ??= new List<List<T>>();
6!
489
        _rawLines.Add(line);
6✔
490
        BuildTable();
6✔
491
    }
6✔
492

493
    /// <summary>
494
    /// This method updates a line in the table.
495
    /// </summary>
496
    /// <param name="index">The index of the line to update.</param>
497
    /// <param name="line">The new line.</param>
498
    /// <exception cref="ArgumentOutOfRangeException">Is thrown when the index is out of range.</exception>
499
    /// <exception cref="ArgumentException">Is thrown when the number of columns in the table is not consistent with itself or with the headers.</exception>
500
    /// <remarks>Refer to the example project to understand how to implement it available at https://github.com/MorganKryze/ConsoleAppVisuals/blob/main/example/ </remarks>
501
    public void UpdateLine(int index, List<T> line)
502
    {
503
        if (_rawLines?.Count > 0)
9!
504
        {
505
            if (index < 0 || index >= _rawLines.Count)
9✔
506
            {
507
                throw new ArgumentOutOfRangeException(nameof(index), "The index is out of range.");
3✔
508
            }
509

510
            if (line.Count != _rawHeaders?.Count)
6!
511
            {
512
                throw new ArgumentException(
3✔
513
                    "The number of columns in the table is not consistent."
3✔
514
                );
3✔
515
            }
516
        }
517
        _rawLines![index] = line;
3✔
518
        BuildTable();
3✔
519
    }
3✔
520

521
    /// <summary>
522
    /// This method removes a line from the table.
523
    /// </summary>
524
    /// <param name="index">The index of the line to remove.</param>
525
    /// <exception cref="ArgumentOutOfRangeException">Is thrown when the index is out of range.</exception>
526
    /// <remarks>Refer to the example project to understand how to implement it available at https://github.com/MorganKryze/ConsoleAppVisuals/blob/main/example/ </remarks>
527
    public void RemoveLine(int index)
528
    {
529
        if (_rawLines?.Count > 0 && (index < 0 || index >= _rawLines.Count))
6!
530
        {
531
            throw new ArgumentOutOfRangeException(nameof(index), "The index is out of range.");
3✔
532
        }
533

534
        _rawLines?.RemoveAt(index);
3!
535
        BuildTable();
3✔
536
    }
3✔
537

538
    /// <summary>
539
    /// This method clears the lines of the table.
540
    /// </summary>
541
    public void ClearLines()
542
    {
543
        _rawLines = null;
9✔
544
        BuildTable();
9✔
545
    }
9✔
546

547
    /// <summary>
548
    /// This property returns the specified line in the table.
549
    /// </summary>
550
    /// <param name="index">The index of the line to return.</param>
551
    /// <returns>The line at the specified index.</returns>
552
    /// <exception cref="ArgumentOutOfRangeException">Is thrown when the index is out of range.</exception>
553
    /// <remarks>Refer to the example project to understand how to implement it available at https://github.com/MorganKryze/ConsoleAppVisuals/blob/main/example/ </remarks>
554
    public List<T> GetLine(int index)
555
    {
556
        if (index < 0 || index >= _rawLines?.Count)
9!
557
        {
558
            throw new ArgumentOutOfRangeException(nameof(index), "The index is out of range.");
3✔
559
        }
560
        return _rawLines![index];
6✔
561
    }
562

563
    /// <summary>
564
    /// This method is used to get all the elements from a column given its index.
565
    /// </summary>
566
    /// <param name="index">The index of the column.</param>
567
    /// <returns>The elements of the column.</returns>
568
    /// <exception cref="ArgumentOutOfRangeException">Is thrown when the index is out of range.</exception>
569
    public List<T>? GetColumnData(int index)
570
    {
571
        if (_rawLines is null)
12✔
572
        {
573
            return null;
3✔
574
        }
575

576
        if (index < 0 || index >= _rawLines[0].Count)
9✔
577
        {
578
            throw new ArgumentOutOfRangeException(nameof(index), "Invalid column index.");
3✔
579
        }
580

581
        List<T>? list = new();
6✔
582
        for (int i = 0; i < _rawLines.Count; i++)
36✔
583
        {
584
            list.Add(_rawLines[i][index]);
12✔
585
        }
586
        return list;
6✔
587
    }
588

589
    /// <summary>
590
    /// This method is used to get all the elements from a column given its header.
591
    /// </summary>
592
    /// <param name="header">The header of the column.</param>
593
    /// <returns>The elements of the column.</returns>
594
    /// <exception cref="InvalidOperationException">Is thrown when the table is empty.</exception>
595
    /// <exception cref="ArgumentOutOfRangeException">Is thrown when the header is invalid.</exception>
596
    public List<T>? GetColumnData(string header)
597
    {
598
        if (_rawHeaders is null)
12✔
599
        {
600
            throw new InvalidOperationException("The headers are null.");
3✔
601
        }
602
        else if (_rawLines is null)
9✔
603
        {
604
            return null;
3✔
605
        }
606
        if (!_rawHeaders.Contains(header))
6✔
607
        {
608
            throw new ArgumentOutOfRangeException(nameof(header), "Invalid column header.");
3✔
609
        }
610

611
        return GetColumnData(_rawHeaders.IndexOf(header));
3✔
612
    }
613

614
    /// <summary>
615
    /// This method clears the table.
616
    /// </summary>
617
    public void Reset()
618
    {
619
        _title = null;
3✔
620
        _rawHeaders?.Clear();
3!
621
        _rawLines?.Clear();
3!
622
        _displayArray = null;
3✔
623
    }
3✔
624
    #endregion
625

626
    #region Display Methods
627
    /// <summary>
628
    /// This method displays the table without interaction.
629
    /// </summary>
630
    protected override void RenderElementActions()
631
    {
632
        string[] array = new string[_displayArray!.Length];
3✔
633
        for (int j = 0; j < _displayArray.Length; j++)
54✔
634
        {
635
            array[j] = _displayArray[j];
24✔
636
            Core.WritePositionedString(array[j], _placement.ToTextAlignment(), false, Line + j);
24✔
637
        }
638
    }
3✔
639
    #endregion
640
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc