185 references to IsDefined
Aspire.Dashboard (1)
Model\Assistant\OtelAttributeHelpers.cs (1)
13if (Enum.IsDefined(typeof(HttpStatusCode), statusCode))
CSharpSyntaxGenerator (6)
src\roslyn\src\Compilers\CSharp\Portable\Syntax\SyntaxKindFacts.cs (6)
22Debug.Assert(Enum.IsDefined(typeof(SyntaxKind), (SyntaxKind)i)); 151Debug.Assert(Enum.IsDefined(typeof(SyntaxKind), (SyntaxKind)i)); 181Debug.Assert(Enum.IsDefined(typeof(SyntaxKind), (SyntaxKind)i)); 187Debug.Assert(Enum.IsDefined(typeof(SyntaxKind), (SyntaxKind)i)); 193Debug.Assert(Enum.IsDefined(typeof(SyntaxKind), (SyntaxKind)i)); 1247Debug.Assert(Enum.IsDefined(typeof(SyntaxKind), (SyntaxKind)i));
datacollector (1)
DataCollectorMain.cs (1)
85var isTraceLevelArgValid = Enum.IsDefined(typeof(PlatformTraceLevel), traceLevelInt);
datacollector.arm64 (1)
src\vstest\src\datacollector\DataCollectorMain.cs (1)
85var isTraceLevelArgValid = Enum.IsDefined(typeof(PlatformTraceLevel), traceLevelInt);
dotnet-svcutil-lib (1)
FrameworkFork\System.ServiceModel\System\ServiceModel\Description\PrincipalPermissionMode.cs (1)
20return Enum.IsDefined(typeof(PrincipalPermissionMode), principalPermissionMode);
ILCompiler.Compiler (1)
src\runtime\src\coreclr\tools\Common\Compiler\DependencyAnalysis\Target_Wasm\WasmTypes.cs (1)
51if (Enum.IsDefined(typeof(WasmValueType), (byte)ty))
ILCompiler.ReadyToRun (1)
src\runtime\src\coreclr\tools\Common\Compiler\DependencyAnalysis\Target_Wasm\WasmTypes.cs (1)
51if (Enum.IsDefined(typeof(WasmValueType), (byte)ty))
ILLink.RoslynAnalyzer (1)
COMAnalyzer.cs (1)
79if (Enum.IsDefined(typeof(UnmanagedType), unmanagedType))
Microsoft.AspNetCore.Components (2)
BindConverter.cs (2)
1619if (!Enum.IsDefined(typeof(T), converted)) 1644if (!Enum.IsDefined(typeof(T), converted))
Microsoft.AspNetCore.Mvc.Core (1)
ModelBinding\Binders\EnumTypeModelBinder.cs (1)
87return Enum.IsDefined(modelType, model);
Microsoft.AspNetCore.Server.HttpSys (1)
src\aspnetcore\src\Shared\Buffers.MemoryPool\MemoryPoolThrowHelper.cs (1)
111Debug.Assert(Enum.IsDefined(typeof(ExceptionArgument), argument), "The enum value is not defined, please check the ExceptionArgument Enum.");
Microsoft.AspNetCore.Server.IIS (1)
src\aspnetcore\src\Shared\Buffers.MemoryPool\MemoryPoolThrowHelper.cs (1)
111Debug.Assert(Enum.IsDefined(typeof(ExceptionArgument), argument), "The enum value is not defined, please check the ExceptionArgument Enum.");
Microsoft.AspNetCore.Server.Kestrel.Core (2)
Internal\ThrowHelper.cs (1)
24Debug.Assert(Enum.IsDefined(typeof(ExceptionArgument), argument), "The enum value is not defined, please check the ExceptionArgument Enum.");
src\aspnetcore\src\Shared\Buffers.MemoryPool\MemoryPoolThrowHelper.cs (1)
111Debug.Assert(Enum.IsDefined(typeof(ExceptionArgument), argument), "The enum value is not defined, please check the ExceptionArgument Enum.");
Microsoft.AspNetCore.Server.Kestrel.Transport.NamedPipes (1)
src\aspnetcore\src\Shared\Buffers.MemoryPool\MemoryPoolThrowHelper.cs (1)
111Debug.Assert(Enum.IsDefined(typeof(ExceptionArgument), argument), "The enum value is not defined, please check the ExceptionArgument Enum.");
Microsoft.AspNetCore.Server.Kestrel.Transport.Quic (1)
src\aspnetcore\src\Shared\Buffers.MemoryPool\MemoryPoolThrowHelper.cs (1)
111Debug.Assert(Enum.IsDefined(typeof(ExceptionArgument), argument), "The enum value is not defined, please check the ExceptionArgument Enum.");
Microsoft.Build (1)
Definition\ProjectOptions.cs (1)
75if (!Enum.IsDefined(typeof(ProjectEvaluationStage), value))
Microsoft.Build.Framework (2)
NodeMode.cs (2)
100if (Enum.IsDefined(typeof(NodeMode), intValue)) 110if (Enum.TryParse(value, ignoreCase: true, out NodeMode enumValue) && Enum.IsDefined(typeof(NodeMode), enumValue))
Microsoft.CodeAnalysis.CSharp (6)
Syntax\SyntaxKindFacts.cs (6)
22Debug.Assert(Enum.IsDefined(typeof(SyntaxKind), (SyntaxKind)i)); 151Debug.Assert(Enum.IsDefined(typeof(SyntaxKind), (SyntaxKind)i)); 181Debug.Assert(Enum.IsDefined(typeof(SyntaxKind), (SyntaxKind)i)); 187Debug.Assert(Enum.IsDefined(typeof(SyntaxKind), (SyntaxKind)i)); 193Debug.Assert(Enum.IsDefined(typeof(SyntaxKind), (SyntaxKind)i)); 1247Debug.Assert(Enum.IsDefined(typeof(SyntaxKind), (SyntaxKind)i));
Microsoft.CodeAnalysis.CSharp.NetAnalyzers (1)
src\sdk\src\Microsoft.CodeAnalysis.NetAnalyzers\src\Utilities\Compiler.CSharp\Extensions\SyntaxGeneratorExtensions.cs (1)
34if (!Enum.IsDefined(typeof(SyntaxKind), SyntaxKindEx.UnsignedRightShiftExpression))
Microsoft.DotNet.Build.Tasks.Feed (1)
src\PushToBuildStorage.cs (1)
191if (!Enum.IsDefined(typeof(PublishingInfraVersion), PublishingVersion))
Microsoft.Extensions.AI (1)
src\Shared\Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
Microsoft.Extensions.AI.Abstractions.Tests (1)
Image\ImageGenerationOptionsTests.cs (1)
122Assert.True(Enum.IsDefined(typeof(ImageGenerationResponseFormat), responseFormat));
Microsoft.Extensions.AI.Evaluation (1)
src\Shared\Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
Microsoft.Extensions.AI.OpenAI (1)
src\Shared\Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
Microsoft.Extensions.Caching.Hybrid (1)
src\Shared\Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
Microsoft.Extensions.Compliance.Abstractions (1)
src\Shared\Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
Microsoft.Extensions.Compliance.Redaction (1)
src\Shared\Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
Microsoft.Extensions.Compliance.Testing (1)
src\Shared\Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
Microsoft.Extensions.DataIngestion.Abstractions (1)
src\Shared\Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
Microsoft.Extensions.DataIngestion.MarkItDown (1)
src\Shared\Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
Microsoft.Extensions.Diagnostics.HealthChecks.ResourceUtilization (1)
src\Shared\Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
Microsoft.Extensions.Diagnostics.ResourceMonitoring.Kubernetes (1)
src\Shared\Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
Microsoft.Extensions.Http.Resilience (1)
src\Shared\Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
Microsoft.Extensions.Options.Contextual (1)
src\Shared\Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
Microsoft.Extensions.Telemetry (1)
src\Shared\Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
Microsoft.Extensions.TimeProvider.Testing (1)
src\Shared\Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
Microsoft.Interop.ComInterfaceGenerator (1)
Analyzers\ConvertComImportToGeneratedComInterfaceAnalyzer.cs (1)
181return !Enum.IsDefined(typeof(UnmanagedType), unmanagedType)
Microsoft.Interop.LibraryImportGenerator (2)
Analyzers\ConvertToLibraryImportAnalyzer.cs (1)
206return !Enum.IsDefined(typeof(UnmanagedType), unmanagedType)
Analyzers\CustomMarshallerAttributeAnalyzer.cs (1)
690|| !Enum.IsDefined(typeof(MarshalMode), (MarshalMode)marshalMode))
Microsoft.Interop.SourceGeneration (1)
MarshalAsParser.cs (1)
206if (!Enum.IsDefined(typeof(UnmanagedType), unmanagedType)
Microsoft.Maui.Controls (4)
CompareStateTrigger.cs (1)
86 return Enum.IsDefined(enumType, value) ? Enum.ToObject(enumType, value) : null;
ListView\ListView.cs (2)
389 if (!Enum.IsDefined(typeof(ScrollToPosition), position)) 404 if (!Enum.IsDefined(typeof(ScrollToPosition), position))
ScrollView\ScrollView.cs (1)
264 if (!Enum.IsDefined(typeof(ScrollToPosition), position))
Microsoft.ML.Data (19)
Commands\TrainCommand.cs (1)
449ch.CheckUserArg(Enum.IsDefined(typeof(NormalizeOption), autoNorm), nameof(TrainCommand.Arguments.NormalizeFeatures),
DataLoadSave\Binary\BinaryLoader.cs (5)
344bool knowCompression = Enum.IsDefined(typeof(CompressionKind), compression); 503ectx.Assert(Enum.IsDefined(typeof(CompressionKind), compression)); 530Contracts.Assert((codec == null) || !Enum.IsDefined(typeof(CompressionKind), compression)); 1110bool knowCompression = Enum.IsDefined(typeof(CompressionKind), compression); 1779Ectx.Assert(Enum.IsDefined(typeof(CompressionKind), entry.Compression));
DataLoadSave\Database\DatabaseLoader.cs (2)
499ch.CheckUserArg(Enum.IsDefined(typeof(DbType), col.Type), nameof(Column.Type), "Bad item type"); 570Contracts.CheckDecode(Enum.IsDefined(typeof(InternalDataKind), kind));
DataLoadSave\Text\TextLoader.cs (2)
777ch.CheckUserArg(Enum.IsDefined(typeof(InternalDataKind), kind), nameof(Column.Type), "Bad item type"); 935Contracts.CheckDecode(Enum.IsDefined(typeof(InternalDataKind), kind));
EntryPoints\InputBuilder.cs (1)
446if (!Enum.IsDefined(type, value.Value<string>()))
Model\Pfa\SavePfaCommand.cs (1)
82Host.CheckUserArg(Enum.IsDefined(typeof(Formatting), args.Formatting), nameof(args.Formatting), "Undefined value");
Transforms\ColumnSelecting.cs (2)
345Contracts.Assert(Enum.IsDefined(typeof(HiddenColumnOption), hiddenOption)); 361Contracts.Assert(Enum.IsDefined(typeof(HiddenColumnOption), colHiddenOption));
Transforms\TypeConverting.cs (2)
266Host.CheckDecode(Enum.IsDefined(typeof(InternalDataKind), kind)); 416ectx.Assert(Enum.IsDefined(typeof(InternalDataKind), kind));
Transforms\ValueToKeyMappingTransformer.cs (2)
283if (!Enum.IsDefined(typeof(ValueToKeyMappingEstimator.KeyOrdinality), options.Sort)) 290if (!Enum.IsDefined(typeof(ValueToKeyMappingEstimator.KeyOrdinality), sortOrder))
Transforms\ValueToKeyMappingTransformerImpl.cs (1)
519ectx.CheckDecode(Enum.IsDefined(typeof(MapType), mtype));
Microsoft.ML.Ensemble (9)
OutputCombiners\MultiWeightedAverage.cs (3)
59Host.CheckUserArg(Enum.IsDefined(typeof(MultiWeightageKind), _weightageKind), nameof(options.WeightageName)); 69Host.CheckDecode(Enum.IsDefined(typeof(MultiWeightageKind), _weightageKind)); 87Host.Assert(Enum.IsDefined(typeof(MultiWeightageKind), _weightageKind));
OutputCombiners\WeightedAverage.cs (3)
57Host.CheckUserArg(Enum.IsDefined(typeof(WeightageKind), _weightageKind), nameof(options.WeightageName)); 66Host.CheckDecode(Enum.IsDefined(typeof(WeightageKind), _weightageKind)); 85Contracts.Assert(Enum.IsDefined(typeof(WeightageKind), _weightageKind));
Selector\SubModelSelector\BestPerformanceRegressionSelector.cs (1)
41Host.CheckUserArg(Enum.IsDefined(typeof(RegressionEvaluator.Metrics), args.MetricName), nameof(args.MetricName), "Undefined metric name");
Selector\SubModelSelector\BestPerformanceSelector.cs (1)
40Host.CheckUserArg(Enum.IsDefined(typeof(BinaryClassifierEvaluator.Metrics), args.MetricName),
Selector\SubModelSelector\BestPerformanceSelectorMulticlass.cs (1)
40Host.CheckUserArg(Enum.IsDefined(typeof(MulticlassClassificationEvaluator.Metrics), args.MetricName),
Microsoft.ML.FastTree (3)
Dataset\IntArray.cs (2)
91Contracts.CheckParam(Enum.IsDefined(typeof(IntArrayType), type) && type != IntArrayType.Current, nameof(type)); 92Contracts.CheckParam(Enum.IsDefined(typeof(IntArrayBits), bitsPerItem), nameof(bitsPerItem));
SumupPerformanceCommand.cs (1)
89_host.CheckUserArg(Enum.IsDefined(typeof(IntArrayType), args.Type) && args.Type != IntArrayType.Current, nameof(args.Type), "Value not defined");
Microsoft.ML.ImageAnalytics (4)
ImageResizer.cs (4)
207Host.CheckDecode(Enum.IsDefined(typeof(ImageResizingEstimator.ResizingKind), scale)); 209Host.CheckDecode(Enum.IsDefined(typeof(ImageResizingEstimator.Anchor), anchor)); 456Contracts.CheckUserArg(Enum.IsDefined(typeof(ResizingKind), resizing), nameof(resizing)); 457Contracts.CheckUserArg(Enum.IsDefined(typeof(Anchor), anchor), nameof(anchor));
Microsoft.ML.InternalCodeAnalyzer (1)
NameFixProvider.cs (1)
94Debug.Assert(!Enum.IsDefined(typeof(NameType), desiredName));
Microsoft.ML.TimeSeries (16)
SequentialAnomalyDetectionTransformBase.cs (9)
173Host.CheckUserArg(Enum.IsDefined(typeof(MartingaleType), martingale), nameof(ArgumentsBase.Martingale), "Value is undefined."); 174Host.CheckUserArg(Enum.IsDefined(typeof(AnomalySide), anomalySide), nameof(ArgumentsBase.Side), "Value is undefined."); 175Host.CheckUserArg(Enum.IsDefined(typeof(AlertingScore), alertingScore), nameof(ArgumentsBase.AlertOn), "Value is undefined."); 211Host.CheckDecode(Enum.IsDefined(typeof(MartingaleType), temp)); 215Host.CheckDecode(Enum.IsDefined(typeof(AlertingScore), temp)); 222Host.CheckDecode(Enum.IsDefined(typeof(AnomalySide), temp)); 240Host.Assert(Enum.IsDefined(typeof(MartingaleType), Martingale)); 241Host.Assert(Enum.IsDefined(typeof(AlertingScore), ThresholdScore)); 244Host.Assert(Enum.IsDefined(typeof(AnomalySide), Side));
SlidingWindowTransformBase.cs (3)
74Host.CheckUserArg(Enum.IsDefined(typeof(BeginOptions), args.Begin), nameof(args.Begin), "Undefined value."); 92Host.CheckDecode(Enum.IsDefined(typeof(BeginOptions), r)); 114Host.Assert(Enum.IsDefined(typeof(BeginOptions), _begin));
SsaAnomalyDetectionBase.cs (3)
196Host.CheckUserArg(Enum.IsDefined(typeof(ErrorFunction), options.ErrorFunction), nameof(options.ErrorFunction), ErrorFunctionUtils.ErrorFunctionHelpText); 233Host.CheckDecode(Enum.IsDefined(typeof(ErrorFunction), temp)); 272Host.Assert(Enum.IsDefined(typeof(ErrorFunction), ErrorFunction));
SsaChangePointDetector.cs (1)
143InternalTransform.Host.Assert(!Enum.IsDefined(typeof(MartingaleType), InternalTransform.Martingale));
Microsoft.ML.Transforms (12)
GcnTransform.cs (1)
846Contracts.CheckDecode(Enum.IsDefined(typeof(NormFunction), normKindVal));
MissingValueReplacing.cs (1)
441if (!Enum.IsDefined(typeof(ReplacementKind), kind))
OneHotEncoding.cs (1)
65if (!Enum.IsDefined(typeof(OneHotEncodingEstimator.OutputKind), kind))
Text\NgramTransform.cs (2)
160Contracts.CheckDecode(Enum.IsDefined(typeof(NgramExtractingEstimator.WeightingCriteria), Weighting)); 179Contracts.Assert(Enum.IsDefined(typeof(NgramExtractingEstimator.WeightingCriteria), Weighting));
Text\StopWordsRemovingTransformer.cs (1)
237Contracts.CheckDecode(Enum.IsDefined(typeof(StopWordsRemovingEstimator.Language), lang));
Text\TextFeaturizingEstimator.cs (2)
385host.Check(Enum.IsDefined(typeof(Language), parent.OptionalSettings.Language)); 386host.Check(Enum.IsDefined(typeof(CaseMode), parent.OptionalSettings.CaseMode));
Text\TextNormalizing.cs (1)
164host.CheckDecode(Enum.IsDefined(typeof(TextNormalizingEstimator.CaseMode), _caseMode));
Text\WordEmbeddingsExtractor.cs (2)
187env.CheckUserArg(Enum.IsDefined(typeof(WordEmbeddingEstimator.PretrainedModelKind), modelKind), nameof(modelKind)); 227env.CheckUserArg(!options.ModelKind.HasValue || Enum.IsDefined(typeof(WordEmbeddingEstimator.PretrainedModelKind), options.ModelKind), nameof(options.ModelKind));
UngroupTransform.cs (1)
355ectx.CheckDecode(Enum.IsDefined(typeof(UngroupMode), modeIndex));
Microsoft.NET.Build.Tasks (1)
CreateAppHost.cs (1)
82&& Enum.IsDefined(typeof(HostWriter.DotNetSearchOptions.SearchLocation), location))
Microsoft.NET.HostModel (3)
Bundle\Bundler.cs (1)
114using (DeflateStream compressionStream = new DeflateStream(bundle, Enum.IsDefined(typeof(CompressionLevel), smallestSize) ? smallestSize : CompressionLevel.Optimal, leaveOpen: true))
MachO\BinaryFormat\Blobs\BlobParser.cs (1)
34Debug.Assert(!Enum.IsDefined(typeof(BlobMagic), magic), "Blob magic is known but not handled.");
src\runtime\src\coreclr\tools\Common\MachO\MachObjectFile.cs (1)
29return Enum.IsDefined(typeof(MachMagic), magic);
Microsoft.NET.Sdk.Razor.Tasks (2)
DotnetToolTask.cs (1)
137if (!SuppressCurrentUserOnlyPipeOptions && !Enum.IsDefined(typeof(PipeOptions), PipeOptionCurrentUserOnly))
src\sdk\src\RazorSdk\Tool\Client.cs (1)
132if (Enum.IsDefined(typeof(PipeOptions), PipeOptionCurrentUserOnly))
Microsoft.Private.Windows.Core (1)
src\winforms\src\Microsoft.Private.Windows.Polyfills\System\EnumExtensions.cs (1)
20public static bool IsDefined<TEnum>(TEnum value) where TEnum : struct, Enum => Enum.IsDefined(typeof(TEnum), value);
Microsoft.TemplateEngine.Orchestrator.RunnableProjects (1)
Validation\ValidationManager.cs (1)
26if (!Enum.IsDefined(typeof(ValidationScope), scope))
Microsoft.TestPlatform.Extensions.BlameDataCollector (3)
BlameCollector.cs (3)
373if (Enum.TryParse(attribute.Value, ignoreCase: true, out CrashDumpType value) && Enum.IsDefined(typeof(CrashDumpType), value)) 420if (Enum.TryParse(attribute.Value, ignoreCase: true, out HangDumpType value) && Enum.IsDefined(typeof(HangDumpType), value)) 434if (Enum.TryParse(attribute.Value, ignoreCase: true, out HangDumpType value2) && Enum.IsDefined(typeof(HangDumpType), value2))
Microsoft.TestPlatform.Utilities (2)
InferRunSettingsHelper.cs (2)
634return Enum.IsDefined(typeof(Architecture), value) && value != Architecture.Default && value != Architecture.AnyCPU; 662return Enum.IsDefined(typeof(FrameworkVersion), value) && value != FrameworkVersion.None;
Microsoft.VisualStudio.TestPlatform.ObjectModel (2)
RunSettings\RunConfiguration.cs (2)
790if (!Enum.IsDefined(typeof(Architecture), archType) || Architecture.Default == archType || Architecture.AnyCPU == archType) 818if (!Enum.IsDefined(typeof(Architecture), defaultArchType) || Architecture.Default == defaultArchType || Architecture.AnyCPU == defaultArchType)
Microsoft.Win32.Registry (1)
Microsoft\Win32\RegistryKey.cs (1)
1212!Enum.IsDefined(typeof(RegistryValueKind), type) ? RegistryValueKind.Unknown :
NuGet.Commands (2)
TrustedSignersCommand\TrustedSignerActionsProvider.cs (2)
93if (!Enum.IsDefined(typeof(VerificationTarget), trustTarget) || (trustTarget != VerificationTarget.Repository && trustTarget != VerificationTarget.Author)) 177if (!Enum.IsDefined(typeof(HashAlgorithmName), hashAlgorithm) || hashAlgorithm == HashAlgorithmName.Unknown)
NuGet.Packaging (9)
Signing\Authoring\SignPackageRequest.cs (2)
66if (!Enum.IsDefined(typeof(HashAlgorithmName), signatureHashAlgorithm) || 72if (!Enum.IsDefined(typeof(HashAlgorithmName), timestampHashAlgorithm) ||
Signing\Signatures\Signature.cs (1)
348if (!Enum.IsDefined(typeof(HashAlgorithmName), algorithm))
Signing\Utility\CertificateChainUtility.cs (1)
80if (!Enum.IsDefined(typeof(CertificateType), certificateType))
Signing\Verification\CertificateHashAllowListEntry.cs (2)
20if (!Enum.IsDefined(typeof(SignaturePlacement), placement)) 30if (!Enum.IsDefined(typeof(HashAlgorithmName), algorithm))
Signing\Verification\SignedPackageVerifierSettings.cs (3)
90if (!Enum.IsDefined(typeof(VerificationTarget), verificationTarget)) 100if (!Enum.IsDefined(typeof(SignaturePlacement), signaturePlacement)) 110if (!Enum.IsDefined(typeof(SignatureVerificationBehavior), repositoryCountersignatureVerificationBehavior))
NuGet.Protocol (23)
Plugins\MessageConverter.cs (2)
125if (!Enum.TryParse<MessageType>(typeStr, out var messageType) || !Enum.IsDefined(typeof(MessageType), messageType)) 136if (!Enum.TryParse<MessageMethod>(methodStr, out var messageMethod) || !Enum.IsDefined(typeof(MessageMethod), messageMethod))
Plugins\Messages\CopyFilesInPackageResponse.cs (1)
41if (!Enum.IsDefined(typeof(MessageResponseCode), responseCode))
Plugins\Messages\CopyNupkgFileResponse.cs (1)
30if (!Enum.IsDefined(typeof(MessageResponseCode), responseCode))
Plugins\Messages\GetAuthenticationCredentialsResponse.cs (1)
57if (!Enum.IsDefined(typeof(MessageResponseCode), responseCode))
Plugins\Messages\GetCredentialsRequest.cs (1)
41if (!Enum.IsDefined(typeof(HttpStatusCode), statusCode))
Plugins\Messages\GetCredentialsResponse.cs (1)
48if (!Enum.IsDefined(typeof(MessageResponseCode), responseCode))
Plugins\Messages\GetFilesInPackageResponse.cs (1)
41if (!Enum.IsDefined(typeof(MessageResponseCode), responseCode))
Plugins\Messages\GetOperationClaimsResponse.cs (1)
38var unrecognizedClaims = claims.Where(claim => !Enum.IsDefined(typeof(OperationClaim), claim));
Plugins\Messages\GetPackageHashResponse.cs (1)
38if (!Enum.IsDefined(typeof(MessageResponseCode), responseCode))
Plugins\Messages\GetPackageVersionsResponse.cs (1)
41if (!Enum.IsDefined(typeof(MessageResponseCode), responseCode))
Plugins\Messages\GetServiceIndexResponse.cs (1)
53if (!Enum.IsDefined(typeof(MessageResponseCode), responseCode))
Plugins\Messages\HandshakeResponse.cs (1)
54if (!Enum.IsDefined(typeof(MessageResponseCode), responseCode))
Plugins\Messages\InitializeResponse.cs (1)
30if (!Enum.IsDefined(typeof(MessageResponseCode), responseCode))
Plugins\Messages\LogRequest.cs (1)
40if (!Enum.IsDefined(typeof(LogLevel), logLevel))
Plugins\Messages\LogResponse.cs (1)
30if (!Enum.IsDefined(typeof(MessageResponseCode), responseCode))
Plugins\Messages\Message.cs (2)
73if (!Enum.IsDefined(typeof(MessageType), type)) 83if (!Enum.IsDefined(typeof(MessageMethod), method))
Plugins\Messages\MonitorNuGetProcessExitResponse.cs (1)
30if (!Enum.IsDefined(typeof(MessageResponseCode), responseCode))
Plugins\Messages\PrefetchPackageResponse.cs (1)
30if (!Enum.IsDefined(typeof(MessageResponseCode), responseCode))
Plugins\Messages\SetCredentialsResponse.cs (1)
30if (!Enum.IsDefined(typeof(MessageResponseCode), responseCode))
Plugins\Messages\SetLogLevelRequest.cs (1)
31if (!Enum.IsDefined(typeof(LogLevel), logLevel))
Plugins\Messages\SetLogLevelResponse.cs (1)
30if (!Enum.IsDefined(typeof(MessageResponseCode), responseCode))
rzc (2)
Client.cs (1)
132if (Enum.IsDefined(typeof(PipeOptions), PipeOptionCurrentUserOnly))
ConnectionHost.cs (1)
77if (Enum.IsDefined(typeof(PipeOptions), PipeOptionCurrentUserOnly))
Shared (1)
Throw\Throw.cs (1)
228if (!Enum.IsDefined(typeof(T), argument))
System.ComponentModel.Annotations (1)
System\ComponentModel\DataAnnotations\EnumDataTypeAttribute.cs (1)
98return Enum.IsDefined(EnumType, convertedValue);
System.ComponentModel.TypeConverter (2)
System\ComponentModel\EnumConverter.cs (2)
130if (!EnumType.IsDefined(typeof(FlagsAttribute), false) && !Enum.IsDefined(EnumType, value)) 330public override bool IsValid(ITypeDescriptorContext? context, object? value) => Enum.IsDefined(EnumType, value!);
System.ServiceModel.Federation (1)
System\ServiceModel\Federation\WSTrustChannelSecurityTokenProvider.cs (1)
369if (!Enum.IsDefined(typeof(SecurityKeyEntropyMode), value))
System.ServiceModel.Primitives (1)
System\ServiceModel\Description\PrincipalPermissionMode.cs (1)
21return Enum.IsDefined(typeof(PrincipalPermissionMode), principalPermissionMode);
System.Text.Encodings.Web (1)
System\Text\Encodings\Web\ThrowHelper.cs (1)
25Debug.Assert(Enum.IsDefined(typeof(ExceptionArgument), argument),
System.Text.Json (1)
System\Text\Json\Serialization\Converters\Value\EnumConverter.cs (1)
400s_isFlagsEnum || (dictionaryKeyPolicy is not null && Enum.IsDefined(typeof(T), value)),
System.Windows.Forms.Analyzers.CSharp (1)
System\Windows\Forms\CSharp\Generators\ApplicationConfiguration\ProjectFileReader.cs (1)
112!Enum.IsDefined(typeof(HighDpiMode), highDpiMode))
testhost (1)
src\vstest\src\testhost.x86\DefaultEngineInvoker.cs (1)
291var traceLevel = Enum.IsDefined(typeof(PlatformTraceLevel), traceLevelInt) ?
testhost.arm64 (1)
src\vstest\src\testhost.x86\DefaultEngineInvoker.cs (1)
291var traceLevel = Enum.IsDefined(typeof(PlatformTraceLevel), traceLevelInt) ?
testhost.x86 (1)
DefaultEngineInvoker.cs (1)
291var traceLevel = Enum.IsDefined(typeof(PlatformTraceLevel), traceLevelInt) ?