Terraria
v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
SystemCore_EnumerableDebugView.cs
Go to the documentation of this file.
1
using
System.Collections
;
2
using
System.Collections.Generic
;
3
using
System.Diagnostics
;
4
5
namespace
System.Linq
;
6
7
internal
sealed
class
SystemCore_EnumerableDebugView
<T>
8
{
9
[
DebuggerBrowsable
(
DebuggerBrowsableState
.Never)]
10
private
readonly
IEnumerable<T>
_enumerable
;
11
12
[
DebuggerBrowsable
(
DebuggerBrowsableState
.RootHidden)]
13
public
T[] Items
14
{
15
get
16
{
17
T[]
array
=
_enumerable
.ToArray();
18
if
(
array
.Length == 0)
19
{
20
throw
new
SystemCore_EnumerableDebugViewEmptyException
();
21
}
22
return
array
;
23
}
24
}
25
26
public
SystemCore_EnumerableDebugView
(
IEnumerable<T>
enumerable
)
27
{
28
if
(
enumerable
==
null
)
29
{
30
ThrowHelper
.
ThrowArgumentNullException
(
ExceptionArgument
.enumerable);
31
}
32
_enumerable
=
enumerable
;
33
}
34
}
35
internal
sealed
class
SystemCore_EnumerableDebugView
36
{
37
[
DebuggerBrowsable
(
DebuggerBrowsableState
.Never)]
38
private
readonly
IEnumerable
_enumerable
;
39
40
[
DebuggerBrowsable
(
DebuggerBrowsableState
.RootHidden)]
41
public
object
[] Items
42
{
43
get
44
{
45
List<object>
list
=
new
List<object>
();
46
foreach
(
object
item
in
_enumerable
)
47
{
48
list
.Add(
item
);
49
}
50
if
(
list
.Count == 0)
51
{
52
throw
new
SystemCore_EnumerableDebugViewEmptyException
();
53
}
54
return
list
.ToArray();
55
}
56
}
57
58
public
SystemCore_EnumerableDebugView
(
IEnumerable
enumerable
)
59
{
60
if
(
enumerable
==
null
)
61
{
62
ThrowHelper
.
ThrowArgumentNullException
(
ExceptionArgument
.enumerable);
63
}
64
_enumerable
=
enumerable
;
65
}
66
}
System.Collections.Generic.Dictionary
Definition
Dictionary.cs:14
System.Linq.SystemCore_EnumerableDebugViewEmptyException
Definition
SystemCore_EnumerableDebugViewEmptyException.cs:4
System.Linq.SystemCore_EnumerableDebugView._enumerable
readonly IEnumerable _enumerable
Definition
SystemCore_EnumerableDebugView.cs:38
System.Linq.SystemCore_EnumerableDebugView._enumerable
readonly IEnumerable< T > _enumerable
Definition
SystemCore_EnumerableDebugView.cs:10
System.Linq.SystemCore_EnumerableDebugView.SystemCore_EnumerableDebugView
SystemCore_EnumerableDebugView(IEnumerable< T > enumerable)
Definition
SystemCore_EnumerableDebugView.cs:26
System.Linq.SystemCore_EnumerableDebugView.SystemCore_EnumerableDebugView
SystemCore_EnumerableDebugView(IEnumerable enumerable)
Definition
SystemCore_EnumerableDebugView.cs:58
System.Linq.SystemCore_EnumerableDebugView
Definition
SystemCore_EnumerableDebugView.cs:8
System.Linq.ThrowHelper.ThrowArgumentNullException
static void ThrowArgumentNullException(ExceptionArgument argument)
Definition
ThrowHelper.cs:8
System.Linq.ThrowHelper
Definition
ThrowHelper.cs:6
System.Collections.Generic.IEnumerable
Definition
IEnumerable.cs:4
System.Collections.Generic
Definition
IHashKeyCollection.cs:1
System.Collections
Definition
BlockingCollection.cs:8
System.Diagnostics.DebuggerBrowsableState
DebuggerBrowsableState
Definition
DebuggerBrowsableState.cs:4
System.Diagnostics
Definition
AggregationManager.cs:6
System.Linq.ExceptionArgument
ExceptionArgument
Definition
ExceptionArgument.cs:4
System.Linq.ExceptionArgument.enumerable
@ enumerable
System.Linq
Definition
ImmutableArrayExtensions.cs:4
System.ExceptionArgument.list
@ list
System.ExceptionArgument.item
@ item
System.ExceptionArgument.array
@ array
source
System.Linq
System.Linq
SystemCore_EnumerableDebugView.cs
Generated by
1.10.0