112 references to GetTypeCode
dotnet-svcutil-lib (11)
FrameworkFork\Microsoft.Xml\Xml\Serialization\CodeGenerator.cs (5)
1066
OpCode opCode = GetLdindOpCode(Type.
GetTypeCode
(type));
1135
switch (Type.
GetTypeCode
(valueType))
1528
OpCode opCode = GetLdelemOpCode(Type.
GetTypeCode
(arrayElementType));
1608
OpCode opCode = GetStelemOpCode(Type.
GetTypeCode
(arrayElementType));
1797
OpCode opCode = GetConvOpCode(Type.
GetTypeCode
(target));
FrameworkFork\Microsoft.Xml\Xml\Serialization\Types.cs (1)
580
switch (Type.
GetTypeCode
(type))
FrameworkFork\Microsoft.Xml\Xml\Serialization\XmlSerializationWriter.cs (3)
207
switch (Type.
GetTypeCode
(type))
257
switch (Type.
GetTypeCode
(t))
3526
switch (Type.
GetTypeCode
(type))
FrameworkFork\Microsoft.Xml\Xml\Serialization\XmlSerializer.cs (2)
776
switch (Type.
GetTypeCode
(_primitiveType))
850
switch (Type.
GetTypeCode
(_primitiveType))
Microsoft.AspNetCore.Components (1)
ChangeDetection.cs (1)
52
=> Type.
GetTypeCode
(type) != TypeCode.Object
Microsoft.Build (3)
Evaluation\Expander.cs (1)
4389
? Type.
GetTypeCode
(parameters[0].ParameterType)
TaskParameter.cs (2)
122
TypeCode typeCode = Type.
GetTypeCode
(wrappedParameterType.GetElementType());
168
TypeCode typeCode = Type.
GetTypeCode
(wrappedParameterType);
Microsoft.CodeAnalysis.ExpressionEvaluator.ResultProvider.Utilities (1)
Debugger\MemberInfo\TypeImpl.cs (1)
399
return (TypeCode)System.Type.
GetTypeCode
(this.Type);
Microsoft.CodeAnalysis.VisualBasic.Semantic.UnitTests (1)
Semantics\Conversions.vb (1)
1369
Select Case System.Type.
GetTypeCode
(value.GetType())
Microsoft.CSharp (4)
Microsoft\CSharp\RuntimeBinder\Semantics\ConstVal.cs (1)
90
Type.
GetTypeCode
(o.GetType()) switch
Microsoft\CSharp\RuntimeBinder\Semantics\Tree\Constant.cs (1)
59
object objval = System.Type.
GetTypeCode
(Type.AssociatedSystemType) switch
Microsoft\CSharp\RuntimeBinder\SymbolTable.cs (2)
1511
Debug.Assert(Type.
GetTypeCode
(defValue.GetType()) != TypeCode.Decimal); // Handled above
1512
switch (Type.
GetTypeCode
(defValue.GetType()))
Microsoft.Extensions.AI.Abstractions.Tests (1)
Utilities\AIJsonUtilitiesTests.cs (1)
236
string numericType = Type.
GetTypeCode
(param.ParameterType) is TypeCode.Double or TypeCode.Single or TypeCode.Decimal
Microsoft.VisualBasic.Core (5)
Microsoft\VisualBasic\CompilerServices\ObjectType.vb (1)
3550
Dim toTypeCode As TypeCode = Type.
GetTypeCode
(toType)
Microsoft\VisualBasic\CompilerServices\Utils.vb (1)
125
Return Type.
GetTypeCode
(type)
Microsoft\VisualBasic\CompilerServices\VB6File.vb (2)
2171
Select Case Type.
GetTypeCode
(typ)
2264
Select Case Type.
GetTypeCode
(CurrentType)
Microsoft\VisualBasic\CompilerServices\VB6RandomFile.vb (1)
456
Select Case Type.
GetTypeCode
(typ)
MSBuild (2)
TaskParameter.cs (2)
122
TypeCode typeCode = Type.
GetTypeCode
(wrappedParameterType.GetElementType());
168
TypeCode typeCode = Type.
GetTypeCode
(wrappedParameterType);
MSBuildTaskHost (3)
Concurrent\ConcurrentDictionary.cs (1)
72
switch (Type.
GetTypeCode
(valueType))
TaskParameter.cs (2)
122
TypeCode typeCode = Type.
GetTypeCode
(wrappedParameterType.GetElementType());
168
TypeCode typeCode = Type.
GetTypeCode
(wrappedParameterType);
PresentationCore (1)
System\Windows\BinaryFormat\TypeInfo.cs (1)
41
internal static PrimitiveType GetPrimitiveType(Type type) => Type.
GetTypeCode
(type) switch
PresentationFramework (8)
System\Windows\Controls\DataGridLengthConverter.cs (1)
25
TypeCode tc = Type.
GetTypeCode
(sourceType);
System\Windows\Controls\VirtualizationCacheLengthConverter.cs (1)
36
TypeCode tc = Type.
GetTypeCode
(sourceType);
System\Windows\CornerRadiusConverter.cs (1)
31
TypeCode tc = Type.
GetTypeCode
(sourceType);
System\Windows\FigureLengthConverter.cs (1)
49
TypeCode tc = Type.
GetTypeCode
(sourceType);
System\Windows\GridLengthConverter.cs (1)
52
TypeCode tc = Type.
GetTypeCode
(sourceType);
System\Windows\LengthConverter.cs (1)
46
TypeCode tc = Type.
GetTypeCode
(sourceType);
System\Windows\ThemeModeConverter.cs (1)
34
return Type.
GetTypeCode
(sourceType) == TypeCode.String;
System\Windows\ThicknessConverter.cs (1)
39
TypeCode tc = Type.
GetTypeCode
(sourceType);
System.Data.Common (4)
System\Data\Common\DataStorage.cs (1)
371
TypeCode tcode = Type.
GetTypeCode
(dataType);
System\Data\Common\ObjectStorage.cs (2)
195
switch (Type.
GetTypeCode
(dataType))
482
if (Type.
GetTypeCode
(value.GetType()) != TypeCode.Object)
System\Data\DataRowComparer.cs (1)
67
switch (Type.
GetTypeCode
(a.GetType().GetElementType()))
System.Data.Odbc (2)
System\Data\Odbc\Odbc32.cs (2)
888
switch (Type.
GetTypeCode
(dataType))
931
default: throw ADP.UnknownDataTypeCode(dataType, Type.
GetTypeCode
(dataType));
System.Linq.Expressions (1)
System\Dynamic\Utils\TypeExtensions.cs (1)
67
public static TypeCode GetTypeCode(this Type type) => Type.
GetTypeCode
(type);
System.Private.CoreLib (17)
src\libraries\System.Private.CoreLib\src\System\Collections\Generic\EqualityComparer.cs (1)
246
if (Type.
GetTypeCode
(typeof(T)) != TypeCode.Int32)
src\libraries\System.Private.CoreLib\src\System\DefaultBinder.cs (2)
1238
Primitives widerCodes = PrimitiveConversions[(int)(Type.
GetTypeCode
(source))];
1239
Primitives targetCode = (Primitives)(1 << (int)(Type.
GetTypeCode
(target)));
src\libraries\System.Private.CoreLib\src\System\Diagnostics\Tracing\EventPipeMetadataGenerator.cs (1)
667
return Type.
GetTypeCode
(parameterType);
src\libraries\System.Private.CoreLib\src\System\Diagnostics\Tracing\EventSource.cs (3)
1796
TypeCode typeCode = Type.
GetTypeCode
(dataType);
3544
(dataType.IsEnum && Type.
GetTypeCode
(dataType.GetEnumUnderlyingType()) <= TypeCode.UInt32))
6048
switch (Type.
GetTypeCode
(type))
src\libraries\System.Private.CoreLib\src\System\Enum.cs (1)
106
switch (Type.
GetTypeCode
(underlyingType)) // can't use InternalGetCorElementType as enumType may actually be the underlying type
src\libraries\System.Private.CoreLib\src\System\RuntimeType.cs (1)
231
return
GetTypeCode
(underlyingType) switch
src\libraries\System.Private.CoreLib\src\System\Type.cs (1)
551
return
GetTypeCode
(systemType);
src\System\Reflection\Emit\CustomAttributeBuilder.cs (6)
254
return Type.
GetTypeCode
(Enum.GetUnderlyingType(t)) is
269
if (type != typeof(object) && Type.
GetTypeCode
(passedType) != Type.
GetTypeCode
(type))
283
switch (Type.
GetTypeCode
(type))
375
switch (Type.
GetTypeCode
(Enum.GetUnderlyingType(type)))
439
switch (Type.
GetTypeCode
(type))
src\System\StubHelpers.cs (1)
917
switch (Type.
GetTypeCode
(elementType))
System.Private.DataContractSerialization (21)
System\Runtime\Serialization\CodeGenerator.cs (7)
318
TypeCode typeCode = Type.
GetTypeCode
(type);
635
switch (Type.
GetTypeCode
(type))
766
OpCode opCode = GetLdindOpCode(Type.
GetTypeCode
(type));
812
switch (Type.
GetTypeCode
(valueType))
990
OpCode opCode = GetLdelemOpCode(Type.
GetTypeCode
(arrayElementType));
1028
OpCode opCode = GetStelemOpCode(Type.
GetTypeCode
(arrayElementType));
1158
OpCode opCode = GetConvOpCode(Type.
GetTypeCode
(target));
System\Runtime\Serialization\DataContract.cs (1)
673
switch (Type.
GetTypeCode
(type))
System\Runtime\Serialization\ExtensionDataReader.cs (1)
662
switch (Type.
GetTypeCode
(type))
System\Runtime\Serialization\Json\JsonFormatReaderGenerator.cs (1)
917
switch (Type.
GetTypeCode
(itemType))
System\Runtime\Serialization\Json\JsonFormatWriterGenerator.cs (1)
563
switch (Type.
GetTypeCode
(itemType))
System\Runtime\Serialization\Json\ReflectionJsonFormatReader.cs (1)
209
TypeCode typeCode = Type.
GetTypeCode
(keyDataContract.UnderlyingType);
System\Runtime\Serialization\Json\ReflectionJsonFormatWriter.cs (1)
152
switch (Type.
GetTypeCode
(itemType))
System\Runtime\Serialization\ReflectionReader.cs (1)
634
switch (Type.
GetTypeCode
(itemType))
System\Runtime\Serialization\ReflectionXmlFormatWriter.cs (1)
102
switch (Type.
GetTypeCode
(itemType))
System\Runtime\Serialization\XmlFormatReaderGenerator.cs (1)
848
switch (Type.
GetTypeCode
(itemType))
System\Runtime\Serialization\XmlFormatWriterGenerator.cs (1)
596
switch (Type.
GetTypeCode
(itemType))
System\Runtime\Serialization\XmlReaderDelegator.cs (2)
226
switch (Type.
GetTypeCode
(valueType))
282
switch (Type.
GetTypeCode
(valueType))
System\Runtime\Serialization\XmlWriterDelegator.cs (2)
285
switch (Type.
GetTypeCode
(valueType))
362
switch (Type.
GetTypeCode
(valueType))
System.Private.Windows.Core (1)
System\Private\Windows\BinaryFormat\Support\TypeInfo.cs (1)
52
internal static PrimitiveType GetPrimitiveType(Type type) => type.IsEnum ? default : Type.
GetTypeCode
(type) switch
System.Private.Xml (13)
System\Xml\Serialization\CodeGenerator.cs (5)
710
OpCode opCode = GetLdindOpCode(Type.
GetTypeCode
(type));
782
switch (Type.
GetTypeCode
(valueType))
1038
OpCode opCode = GetLdelemOpCode(Type.
GetTypeCode
(arrayElementType));
1084
OpCode opCode = GetStelemOpCode(Type.
GetTypeCode
(arrayElementType));
1198
OpCode opCode = GetConvOpCode(Type.
GetTypeCode
(target));
System\Xml\Serialization\Types.cs (1)
553
switch (Type.
GetTypeCode
(type))
System\Xml\Serialization\XmlSerializationWriter.cs (3)
207
switch (Type.
GetTypeCode
(type))
269
switch (Type.
GetTypeCode
(t))
1337
if (Type.
GetTypeCode
(t) == TypeCode.Object && !(o is Guid) && (t != typeof(XmlQualifiedName)) && !(o is XmlNode[]) && (t != typeof(byte[])))
System\Xml\Serialization\XmlSerializer.cs (2)
861
switch (Type.
GetTypeCode
(_primitiveType))
943
switch (Type.
GetTypeCode
(_primitiveType))
System\Xml\Xsl\XsltOld\NumberAction.cs (1)
372
if (Type.
GetTypeCode
(value.GetType()) == TypeCode.Object)
System\Xml\Xsl\XsltOld\XsltCompileContext.cs (1)
546
switch (Type.
GetTypeCode
(type))
System.Reflection.Context (1)
System\Reflection\Context\Delegation\DelegatingType.cs (1)
247
return Type.
GetTypeCode
(_typeInfo);
System.Reflection.DispatchProxy (1)
System\Reflection\DispatchProxyGenerator.cs (1)
553
private static int GetTypeCode(Type type) => (int)Type.
GetTypeCode
(type);
System.Reflection.Emit (1)
System\Reflection\Emit\CustomAttributeWrapper.cs (1)
123
switch (Type.
GetTypeCode
(t))
System.Reflection.MetadataLoadContext (4)
System\Reflection\DefaultBinder.CanConvert.cs (2)
17
Primitives widerCodes = s_primitiveConversions[(int)(Type.
GetTypeCode
(source))];
18
Primitives targetCode = (Primitives)(1 << (int)(Type.
GetTypeCode
(target)));
System\Reflection\TypeLoading\Types\RoConstructedGenericType.cs (1)
114
protected sealed override TypeCode GetTypeCodeImpl() => Type.
GetTypeCode
(_genericTypeDefinition);
System\Reflection\TypeLoading\Types\RoType.cs (1)
344
Array ret = Type.
GetTypeCode
(GetEnumUnderlyingType()) switch
System.Text.Json (4)
System\Text\Json\Nodes\JsonValueOfT.cs (1)
107
return Type.
GetTypeCode
(type) switch
System\Text\Json\Serialization\Converters\Value\EnumConverter.cs (1)
19
private static readonly TypeCode s_enumTypeCode = Type.
GetTypeCode
(typeof(T));
System\Text\Json\Serialization\Converters\Value\EnumConverterFactory.cs (2)
33
if (!Helpers.IsSupportedTypeCode(Type.
GetTypeCode
(enumType)))
59
if (!IsSupportedTypeCode(Type.
GetTypeCode
(typeof(T))))
System.Windows.Controls.Ribbon (1)
Microsoft\Windows\Controls\Ribbon\RibbonControlLengthConverter.cs (1)
48
TypeCode tc = Type.
GetTypeCode
(sourceType);