18 implementations of ToInt32
Microsoft.Gen.Logging.Generated.Tests (1)
parent\TestClasses\FormattableTestExtensions.cs (1)
38
public readonly int
ToInt32
(IFormatProvider? provider) => throw new NotSupportedException();
System.Private.CoreLib (17)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Boolean.cs (1)
356
int IConvertible.
ToInt32
(IFormatProvider? provider)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Byte.cs (1)
206
int IConvertible.
ToInt32
(IFormatProvider? provider)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Char.cs (1)
614
int IConvertible.
ToInt32
(IFormatProvider? provider)
src\runtime\src\libraries\System.Private.CoreLib\src\System\DateTime.cs (1)
1956
int IConvertible.
ToInt32
(IFormatProvider? provider) => throw InvalidCast(nameof(Int32));
src\runtime\src\libraries\System.Private.CoreLib\src\System\DBNull.cs (1)
72
int IConvertible.
ToInt32
(IFormatProvider? provider)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Decimal.cs (1)
1059
int IConvertible.
ToInt32
(IFormatProvider? provider)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Double.cs (1)
480
int IConvertible.
ToInt32
(IFormatProvider? provider)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Enum.cs (1)
2184
int IConvertible.
ToInt32
(IFormatProvider? provider) => Convert.ToInt32(GetValue());
src\runtime\src\libraries\System.Private.CoreLib\src\System\Int16.cs (1)
209
int IConvertible.
ToInt32
(IFormatProvider? provider)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Int32.cs (1)
224
int IConvertible.
ToInt32
(IFormatProvider? provider)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Int64.cs (1)
221
int IConvertible.
ToInt32
(IFormatProvider? provider)
src\runtime\src\libraries\System.Private.CoreLib\src\System\SByte.cs (1)
212
int IConvertible.
ToInt32
(IFormatProvider? provider)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Single.cs (1)
473
int IConvertible.
ToInt32
(IFormatProvider? provider)
src\runtime\src\libraries\System.Private.CoreLib\src\System\String.cs (1)
662
int IConvertible.
ToInt32
(IFormatProvider? provider)
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt16.cs (1)
203
int IConvertible.
ToInt32
(IFormatProvider? provider)
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt32.cs (1)
219
int IConvertible.
ToInt32
(IFormatProvider? provider)
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt64.cs (1)
218
int IConvertible.
ToInt32
(IFormatProvider? provider)
99 references to ToInt32
dotnet-svcutil-lib (3)
FrameworkFork\Microsoft.CodeDom\Microsoft\VBCodeProvider.cs (1)
1148
Output.Write("Global.Microsoft.VisualBasic.ChrW(" + ((IConvertible)e.Value).
ToInt32
(CultureInfo.InvariantCulture).ToString(CultureInfo.InvariantCulture) + ")");
FrameworkFork\Microsoft.Xml\Xml\Serialization\CodeExporter.cs (1)
329
return ((IConvertible)value).
ToInt32
(null);
FrameworkFork\Microsoft.Xml\Xml\Serialization\CodeGenerator.cs (1)
1147
Ldc(((IConvertible)o).
ToInt32
(CultureInfo.InvariantCulture));
GenerateDocumentationAndConfigFiles (1)
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\EnumUtilties.cs (1)
24
int val = value.
ToInt32
(null);
Microsoft.CodeAnalysis (1)
InternalUtilities\EnumUtilties.cs (1)
24
int val = value.
ToInt32
(null);
Microsoft.CodeAnalysis.Analyzers (1)
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\EnumUtilties.cs (1)
24
int val = value.
ToInt32
(null);
Microsoft.CodeAnalysis.AnalyzerUtilities (1)
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\EnumUtilties.cs (1)
24
int val = value.
ToInt32
(null);
Microsoft.CodeAnalysis.CodeStyle (1)
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\EnumUtilties.cs (1)
24
int val = value.
ToInt32
(null);
Microsoft.CodeAnalysis.ResxSourceGenerator (1)
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\EnumUtilties.cs (1)
24
int val = value.
ToInt32
(null);
Microsoft.CodeAnalysis.Workspaces (1)
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\EnumUtilties.cs (1)
24
int val = value.
ToInt32
(null);
Microsoft.CSharp (1)
Microsoft\CSharp\RuntimeBinder\ComInterop\DynamicVariantExtensions.cs (1)
66
case TypeCode.Int32: variant = ComVariant.Create(value.
ToInt32
(ci)); break;
Microsoft.VisualBasic.Core (63)
Microsoft\VisualBasic\CompilerServices\BooleanType.vb (1)
92
Return CBool(ValueInterface.
ToInt32
(Nothing))
Microsoft\VisualBasic\CompilerServices\ByteType.vb (1)
77
Return CByte(ValueInterface.
ToInt32
(Nothing))
Microsoft\VisualBasic\CompilerServices\Conversions.vb (15)
110
Return CBool(ValueInterface.
ToInt32
(Nothing))
254
Return CByte(ValueInterface.
ToInt32
(Nothing))
401
Return CSByte(ValueInterface.
ToInt32
(Nothing))
544
Return CShort(ValueInterface.
ToInt32
(Nothing))
690
Return CUShort(ValueInterface.
ToInt32
(Nothing))
833
Return CInt(ValueInterface.
ToInt32
(Nothing))
859
Return ValueInterface.
ToInt32
(Nothing)
978
Return CUInt(ValueInterface.
ToInt32
(Nothing))
1124
Return CLng(ValueInterface.
ToInt32
(Nothing))
1271
Return CULng(ValueInterface.
ToInt32
(Nothing))
1430
Return CDec(ValueInterface.
ToInt32
(Nothing))
1670
Return CSng(ValueInterface.
ToInt32
(Nothing))
1815
Return CDbl(ValueInterface.
ToInt32
(Nothing))
2277
Return CStr(ValueInterface.
ToInt32
(Nothing))
2428
Case TypeCode.Int32 : Return CastInt32Enum(iconv.
ToInt32
(Nothing), TargetType)
Microsoft\VisualBasic\CompilerServices\DecimalType.vb (1)
81
Return CDec(valueInterface.
ToInt32
(Nothing))
Microsoft\VisualBasic\CompilerServices\DoubleType.vb (1)
85
Return CDbl(valueInterface.
ToInt32
(Nothing))
Microsoft\VisualBasic\CompilerServices\IntegerType.vb (1)
77
Return CInt(ValueInterface.
ToInt32
(Nothing))
Microsoft\VisualBasic\CompilerServices\LongType.vb (1)
80
Return CLng(ValueInterface.
ToInt32
(Nothing))
Microsoft\VisualBasic\CompilerServices\ObjectType.vb (35)
524
Return ObjTstInt32(conv1.
ToInt32
(Nothing), 0)
527
Return ObjTstInt32(0, conv2.
ToInt32
(Nothing))
686
Return ObjTstInt32(conv1.
ToInt32
(Nothing), conv2.
ToInt32
(Nothing))
689
Return ObjTstInt32(conv1.
ToInt32
(Nothing), ToVBBool(conv2))
692
Return ObjTstInt32(ToVBBool(conv1), conv2.
ToInt32
(Nothing))
993
Int64Result = -CType(conv.
ToInt32
(Nothing), Int64)
1162
int32Value = Not iconv.
ToInt32
(Nothing)
1684
Return AddInt32(conv1.
ToInt32
(Nothing), conv2.
ToInt32
(Nothing))
1687
Return AddInt32(conv1.
ToInt32
(Nothing), ToVBBool(conv2))
1690
Return AddInt32(ToVBBool(conv1), conv2.
ToInt32
(Nothing))
1983
Return SubInt32(conv1.
ToInt32
(Nothing), conv2.
ToInt32
(Nothing))
1986
Return SubInt32(conv1.
ToInt32
(Nothing), ToVBBool(conv2))
1989
Return SubInt32(ToVBBool(conv1), conv2.
ToInt32
(Nothing))
2285
Return MulInt32(conv1.
ToInt32
(Nothing), conv2.
ToInt32
(Nothing))
2288
Return MulInt32(conv1.
ToInt32
(Nothing), ToVBBool(conv2))
2291
Return MulInt32(ToVBBool(conv1), conv2.
ToInt32
(Nothing))
2800
Return ModInt32(conv1.
ToInt32
(Nothing), 0)
2824
Return ModInt32(0, conv2.
ToInt32
(Nothing))
2925
Return ModInt32(conv1.
ToInt32
(Nothing), conv2.
ToInt32
(Nothing))
2928
Return ModInt32(conv1.
ToInt32
(Nothing), ToVBBool(conv2))
2931
Return ModInt32(ToVBBool(conv1), conv2.
ToInt32
(Nothing))
3143
Return IDivideInt32(conv1.
ToInt32
(Nothing), 0)
3161
Return IDivideInt32(0, conv2.
ToInt32
(Nothing))
3175
Return IDivideInt32(ToVBBool(conv1), conv2.
ToInt32
(Nothing))
3195
Return IDivideInt32(conv1.
ToInt32
(Nothing), ToVBBool(conv2))
3217
Return IDivideInt32(conv1.
ToInt32
(Nothing), conv2.
ToInt32
(Nothing))
3366
Return conv1.
ToInt32
(Nothing) << amount
3403
Return conv1.
ToInt32
(Nothing) >> amount
3659
Return iconv.
ToInt32
(Nothing)
Microsoft\VisualBasic\CompilerServices\ShortType.vb (1)
77
Return CShort(ValueInterface.
ToInt32
(Nothing))
Microsoft\VisualBasic\CompilerServices\SingleType.vb (1)
91
Return CSng(ValueInterface.
ToInt32
(Nothing))
Microsoft\VisualBasic\CompilerServices\StringType.vb (1)
124
Return FromInteger(ValueInterface.
ToInt32
(Nothing))
Microsoft\VisualBasic\Conversion.vb (4)
153
Return ValueInterface.
ToInt32
(Nothing)
228
Return ValueInterface.
ToInt32
(Nothing)
310
Return Hex(ValueInterface.
ToInt32
(Nothing))
422
Return Oct(ValueInterface.
ToInt32
(Nothing))
Roslyn.Diagnostics.Analyzers (1)
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\EnumUtilties.cs (1)
24
int val = value.
ToInt32
(null);
System.CodeDom (1)
Microsoft\VisualBasic\VBCodeGenerator.cs (1)
814
Output.Write("Global.Microsoft.VisualBasic.ChrW(" + ((IConvertible)e.Value).
ToInt32
(CultureInfo.InvariantCulture).ToString(CultureInfo.InvariantCulture) + ")");
System.Data.Common (5)
System\Data\Common\Int32Storage.cs (2)
206
value = ((IConvertible)value).
ToInt32
(FormatProvider);
242
_values[record] = ((IConvertible)value).
ToInt32
(FormatProvider);
System\Data\Common\SQLConvert.cs (1)
527
return ((IConvertible)(string)value).
ToInt32
(formatProvider);
System\Data\Filter\ConstNode.cs (1)
222
return convertible.
ToInt32
(NumberFormatInfo.InvariantInfo);
System\Data\ProviderBase\SchemaMapping.cs (1)
1175
targetColumn.ColumnMapping = (MappingType)((IConvertible)value).
ToInt32
(CultureInfo.InvariantCulture);
System.Data.Odbc (1)
Common\System\Data\Common\DbConnectionStringCommon.cs (1)
237
return ((IConvertible)value).
ToInt32
(CultureInfo.InvariantCulture);
System.Data.OleDb (1)
DbConnectionStringCommon.cs (1)
166
return ((IConvertible)value).
ToInt32
(CultureInfo.InvariantCulture);
System.Management (2)
System\Management\Property.cs (2)
640
((int[])wmiValue)[i] = ((IConvertible)((ushort)(arrayValue[i]))).
ToInt32
(null);
734
wmiValue = ((IConvertible)((ushort)val)).
ToInt32
(null);
System.Net.Http (1)
System\Net\Http\SocketsHttpHandler\RuntimeSettingParser.cs (1)
68
return convertible.
ToInt32
(NumberFormatInfo.InvariantInfo);
System.Private.CoreLib (8)
src\runtime\src\libraries\System.Private.CoreLib\src\System\AppContextConfigHelper.cs (1)
79
result = convertible.
ToInt32
(NumberFormatInfo.InvariantInfo);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Convert.cs (6)
151
TypeCode.Int32 => v.
ToInt32
(provider),
191
return value.
ToInt32
(provider);
263
return ic.
ToInt32
(provider);
983
return value == null ? 0 : ((IConvertible)value).
ToInt32
(null);
988
return value == null ? 0 : ((IConvertible)value).
ToInt32
(provider);
1099
return ((IConvertible)value).
ToInt32
(null);
System\Reflection\Runtime\TypeInfos\RuntimeTypeInfo.InvokeMember.cs (1)
180
idx[i] = ((IConvertible)providedArgs[i]!).
ToInt32
(null);
System.Windows.Forms.Design (5)
System\ComponentModel\Design\Serialization\CodeDomSerializerBase.cs (5)
628
indexes[i] = ic.
ToInt32
(null);
998
int size = ic.
ToInt32
(null);
1038
indexes[i] = convertible.
ToInt32
(null);
1375
int leftValue = left.
ToInt32
(null);
1376
int rightValue = right.
ToInt32
(null);