571 instantiations of MaybeNullWhen
GenerateDocumentationAndConfigFiles (31)
src\Compilers\Core\Portable\Collections\OrderPreservingMultiDictionary.cs (2)
112public bool TryGetValue<TArg>(K key, Func<V, TArg, bool> predicate, TArg arg, [MaybeNullWhen(false)] out V value) 232public bool TryGetValue<TArg>(Func<V, TArg, bool> predicate, TArg arg, [MaybeNullWhen(false)] out V value)
src\Dependencies\Collections\RoslynImmutableInterlocked.cs (1)
587public static bool TryRemove<TKey, TValue>(ref ImmutableSegmentedDictionary<TKey, TValue> location, TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2.cs (1)
263public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2+Builder.cs (1)
118public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2+ValueBuilder.cs (1)
225public readonly bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\SegmentedDictionary`2.cs (2)
771public bool Remove(TKey key, [MaybeNullWhen(false)] out TValue value) 853public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\SegmentedHashSet`1.cs (1)
398public bool TryGetValue(T equalValue, [MaybeNullWhen(false)] out T actualValue)
src\Dependencies\Collections\Specialized\SpecializedCollections.Empty.Dictionary.cs (1)
57public bool TryGetValue(TKey key, [MaybeNullWhen(returnValue: false)] out TValue value)
src\Dependencies\PooledObjects\ArrayBuilder.cs (1)
922public bool TryPop([MaybeNullWhen(false)] out T result)
src\RoslynAnalyzers\Utilities\Compiler\Options\AbstractCategorizedAnalyzerConfigOptions.cs (4)
37static (string s, TryParseValue<T> tryParseValue, [MaybeNullWhen(returnValue: false)] out T parsedValue) => tryParseValue(s, out parsedValue), 113bool TryGetSpecificOptionValue(string specificOptionKey, string optionKeyPrefix, [MaybeNullWhen(false)] out T specificOptionValue) 124bool TryGetAnySpecificOptionValue(IEnumerable<string> specificOptionKeys, string optionKeyPrefix, [MaybeNullWhen(false)] out T specificOptionValue) 138bool TryGetGeneralOptionValue(string optionKeyPrefix, [MaybeNullWhen(false)] out T generalOptionValue)
src\RoslynAnalyzers\Utilities\Compiler\Options\AggregateCategorizedAnalyzerConfigOptions.cs (2)
91static (string s, TryParseValue<T> tryParseValue, [MaybeNullWhen(returnValue: false)] out T parsedValue) => tryParseValue(s, out parsedValue), 112private bool TryGetOptionValue<T, TArg>(string optionName, OptionKind kind, SyntaxTree? tree, DiagnosticDescriptor? rule, TryParseValue<T, TArg> tryParseValue, TArg arg, T defaultValue, [MaybeNullWhen(false)] out T value)
src\RoslynAnalyzers\Utilities\Compiler\Options\ICategorizedAnalyzerConfigOptions.cs (2)
58public delegate bool TryParseValue<T>(string value, [MaybeNullWhen(returnValue: false)] out T parsedValue); 60public delegate bool TryParseValue<T, TArg>(string value, TArg arg, [MaybeNullWhen(returnValue: false)] out T parsedValue);
src\RoslynAnalyzers\Utilities\Compiler\Options\SymbolNamesWithValueOption.cs (2)
237public bool TryGetValue(ISymbol symbol, [MaybeNullWhen(false)] out TValue value) 267private bool TryGetFirstWildcardMatch(ISymbol symbol, [NotNullWhen(true)] out string? firstMatchName, [MaybeNullWhen(false)] out TValue firstMatchValue)
src\RoslynAnalyzers\Utilities\Compiler\SmallDictionary.cs (3)
182public bool TryGetValue(K key, [MaybeNullWhen(returnValue: false)] out V value) 314private bool TryGetValue(int hashCode, K key, [MaybeNullWhen(returnValue: false)] out V value) 348private bool GetFromList(Node? next, K key, [MaybeNullWhen(returnValue: false)] out V value)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\EditorConfigValueSerializer`1.cs (1)
40internal bool TryParseValue(string value, [MaybeNullWhen(false)] out T result)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\AsyncLazy`1.cs (2)
17public abstract bool TryGetValue([MaybeNullWhen(false)] out T result); 185public override bool TryGetValue([MaybeNullWhen(false)] out T result)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\CancellableLazy`1.cs (1)
34public bool TryGetValue([MaybeNullWhen(false)] out T value)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\IBidirectionalMap.cs (2)
14bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value); 15bool TryGetKey(TValue value, [MaybeNullWhen(false)] out TKey key);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Workspace\Mef\MefLanguageServices.cs (1)
93internal bool TryGetService<TLanguageService>(HostWorkspaceServices.MetadataFilter filter, [MaybeNullWhen(false)] out TLanguageService languageService)
Microsoft.AspNetCore.Components (12)
BindConverter.cs (3)
28internal delegate bool BindParser<T>(object? obj, CultureInfo? culture, [MaybeNullWhen(false)] out T value); 29internal delegate bool BindParserWithFormat<T>(object? obj, CultureInfo? culture, string? format, [MaybeNullWhen(false)] out T value); 1660public static bool TryConvertTo<[DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.All)] T>(object? obj, CultureInfo? culture, [MaybeNullWhen(false)] out T value)
ParameterView.cs (1)
66public bool TryGetValue<TValue>(string parameterName, [MaybeNullWhen(false)] out TValue result)
PersistentComponentState.cs (2)
123public bool TryTakeFromJson<[DynamicallyAccessedMembers(JsonSerialized)] TValue>(string key, [MaybeNullWhen(false)] out TValue? instance) 141internal bool TryTakeFromJson(string key, [DynamicallyAccessedMembers(JsonSerialized)] Type type, [MaybeNullWhen(false)] out object? instance)
Reflection\ComponentProperties.cs (1)
357public bool TryGetValue(string parameterName, [MaybeNullWhen(false)] out PropertySetter writer)
Routing\UrlValueConstraint.cs (5)
15public delegate bool TryParseDelegate<T>(ReadOnlySpan<char> str, [MaybeNullWhen(false)] out T result); 19public static bool TryGetByTargetType(Type targetType, [MaybeNullWhen(false)] out UrlValueConstraint result) 91public abstract bool TryParse(ReadOnlySpan<char> value, [MaybeNullWhen(false)] out object result); 106public override bool TryParse(ReadOnlySpan<char> value, [MaybeNullWhen(false)] out object result) 163bool TryParseNullable(ReadOnlySpan<char> value, [MaybeNullWhen(false)] out T? result)
Microsoft.AspNetCore.Components.Endpoints (2)
Builder\ResourcePreloadCollection.cs (1)
99public bool TryGetAssets(string group, [MaybeNullWhen(false)] out List<PreloadAsset> assets)
Rendering\EndpointHtmlRenderer.cs (1)
294public bool TryGetValue(string key, [MaybeNullWhen(false)] out StringValues value)
Microsoft.AspNetCore.Components.Endpoints.Tests (3)
Binding\FormDataMapperTests.cs (2)
2258public static bool TryParse([NotNullWhen(true)] string s, IFormatProvider provider, [MaybeNullWhen(false)] out Point result) 2306public static bool TryParse([NotNullWhen(true)] string s, IFormatProvider provider, [MaybeNullWhen(false)] out ValuePoint result)
FormMapping\Converters\NullableConverterTests.cs (1)
221public static bool TryParse([NotNullWhen(true)] string s, IFormatProvider provider, [MaybeNullWhen(false)] out ParsableTestStruct result)
Microsoft.AspNetCore.Components.Web (6)
Forms\InputBase.cs (1)
180protected abstract bool TryParseValueFromString(string? value, [MaybeNullWhen(false)] out TValue result, [NotNullWhen(false)] out string? validationErrorMessage);
Forms\InputDate.cs (1)
110protected override bool TryParseValueFromString(string? value, [MaybeNullWhen(false)] out TValue result, [NotNullWhen(false)] out string? validationErrorMessage)
Forms\InputExtensions.cs (1)
13[MaybeNullWhen(false)] out TValue result,
Forms\InputNumber.cs (1)
68protected override bool TryParseValueFromString(string? value, [MaybeNullWhen(false)] out TValue result, [NotNullWhen(false)] out string? validationErrorMessage)
Forms\InputRadioGroup.cs (1)
82protected override bool TryParseValueFromString(string? value, [MaybeNullWhen(false)] out TValue result, [NotNullWhen(false)] out string? validationErrorMessage)
Forms\InputSelect.cs (1)
66protected override bool TryParseValueFromString(string? value, [MaybeNullWhen(false)] out TValue result, [NotNullWhen(false)] out string? validationErrorMessage)
Microsoft.AspNetCore.Components.WebView (2)
FileExtensionContentTypeProvider.cs (1)
439public bool TryGetContentType(string subpath, [MaybeNullWhen(false)] out string contentType)
IContentTypeProvider.cs (1)
25bool TryGetContentType(string subpath, [MaybeNullWhen(false)] out string contentType);
Microsoft.AspNetCore.Http (3)
src\Shared\CopyOnWriteDictionary\CopyOnWriteDictionary.cs (1)
114public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Shared\CopyOnWriteDictionary\CopyOnWriteDictionaryHolder.cs (1)
131public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Shared\Dictionary\AdaptiveCapacityDictionary.cs (1)
481public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
Microsoft.AspNetCore.Mvc.Abstractions (1)
ModelBinding\Validation\ValidationStateDictionary.cs (1)
129public bool TryGetValue(object key, [MaybeNullWhen(false)] out ValidationStateEntry value)
Microsoft.AspNetCore.Mvc.ApiExplorer.Test (1)
DefaultApiDescriptionProviderTest.cs (1)
2701public static bool TryParse([NotNullWhen(true)] string s, IFormatProvider provider, [MaybeNullWhen(false)] out TryParsableEmployee result)
Microsoft.AspNetCore.Mvc.Core (2)
src\Shared\CopyOnWriteDictionary\CopyOnWriteDictionary.cs (1)
114public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Shared\CopyOnWriteDictionary\CopyOnWriteDictionaryHolder.cs (1)
131public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
Microsoft.AspNetCore.Mvc.IntegrationTests (2)
SimpleTypeModelBinderIntegrationTest.cs (2)
813public static bool TryParse([NotNullWhen(true)] string s, [MaybeNullWhen(false)] out SampleModel result) 825public static bool TryParse([NotNullWhen(true)] string s, [MaybeNullWhen(false)] out SampleTryParsableModel result)
Microsoft.AspNetCore.Razor.Runtime (2)
src\Shared\CopyOnWriteDictionary\CopyOnWriteDictionary.cs (1)
114public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Shared\CopyOnWriteDictionary\CopyOnWriteDictionaryHolder.cs (1)
131public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
Microsoft.AspNetCore.Session (3)
DefaultDistributedSessionStore.cs (1)
17public bool TryGetValue(EncodedKey key, [MaybeNullWhen(false)] out byte[] value)
IDistributedSessionStore.cs (1)
14bool TryGetValue(EncodedKey key, [MaybeNullWhen(false)] out byte[] value);
NoOpSessionStore.cs (1)
30public bool TryGetValue(EncodedKey key, [MaybeNullWhen(false)] out byte[] value)
Microsoft.AspNetCore.Shared.Tests (3)
src\Shared\CopyOnWriteDictionary\CopyOnWriteDictionary.cs (1)
114public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Shared\CopyOnWriteDictionary\CopyOnWriteDictionaryHolder.cs (1)
131public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Shared\Dictionary\AdaptiveCapacityDictionary.cs (1)
481public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
Microsoft.AspNetCore.SignalR.Core (3)
Internal\Utf8HashLookup.cs (3)
58internal bool TryGetValue(ReadOnlySpan<byte> encodedValue, [MaybeNullWhen(false), AllowNull] out string value) 76private bool TryGetValueSlow(ReadOnlySpan<byte> encodedValue, [MaybeNullWhen(false), AllowNull] out string value) 95private bool TryGetValueFromChars(ReadOnlySpan<char> key, [MaybeNullWhen(false), AllowNull] out string value)
Microsoft.AspNetCore.StaticFiles (2)
FileExtensionContentTypeProvider.cs (1)
433public bool TryGetContentType(string subpath, [MaybeNullWhen(false)] out string contentType)
IContentTypeProvider.cs (1)
19bool TryGetContentType(string subpath, [MaybeNullWhen(false)] out string contentType);
Microsoft.CodeAnalysis (36)
Collections\CachingFactory.cs (2)
70public bool TryGetValue(TKey key, [MaybeNullWhen(returnValue: false)] out TValue value) 161public bool TryGetValue(TKey key, [MaybeNullWhen(returnValue: false)] out TValue value)
Collections\ConcurrentCache.cs (1)
60public bool TryGetValue(TKey key, [MaybeNullWhen(returnValue: false)] out TValue value)
Collections\KeyedStack.cs (1)
32public bool TryPop(T key, [MaybeNullWhen(returnValue: false)] out R value)
Collections\OrderPreservingMultiDictionary.cs (2)
112public bool TryGetValue<TArg>(K key, Func<V, TArg, bool> predicate, TArg arg, [MaybeNullWhen(false)] out V value) 232public bool TryGetValue<TArg>(Func<V, TArg, bool> predicate, TArg arg, [MaybeNullWhen(false)] out V value)
Collections\SmallDictionary.cs (3)
71public bool TryGetValue(K key, [MaybeNullWhen(returnValue: false)] out V value) 201private bool TryGetValue(int hashCode, K key, [MaybeNullWhen(returnValue: false)] out V value) 235private bool GetFromList(Node? next, K key, [MaybeNullWhen(returnValue: false)] out V value)
DiagnosticAnalyzer\AnalysisValueProvider.cs (1)
49internal bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
DiagnosticAnalyzer\CompilationAnalysisValueProvider.cs (1)
28internal bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
DiagnosticAnalyzer\DiagnosticAnalysisContext.cs (12)
241public bool TryGetValue<TValue>(SourceText text, SourceTextValueProvider<TValue> valueProvider, [MaybeNullWhen(false)] out TValue value) 256public bool TryGetValue<TValue>(AdditionalText text, AdditionalTextValueProvider<TValue> valueProvider, [MaybeNullWhen(false)] out TValue value) 261private bool TryGetValue<TKey, TValue>(TKey key, AnalysisValueProvider<TKey, TValue> valueProvider, [MaybeNullWhen(false)] out TValue value) 505public bool TryGetValue<TValue>(SourceText text, SourceTextValueProvider<TValue> valueProvider, [MaybeNullWhen(false)] out TValue value) 520public bool TryGetValue<TValue>(AdditionalText text, AdditionalTextValueProvider<TValue> valueProvider, [MaybeNullWhen(false)] out TValue value) 535public bool TryGetValue<TValue>(SyntaxTree tree, SyntaxTreeValueProvider<TValue> valueProvider, [MaybeNullWhen(false)] out TValue value) 540private bool TryGetValue<TKey, TValue>(TKey key, AnalysisValueProvider<TKey, TValue> valueProvider, [MaybeNullWhen(false)] out TValue value) 547internal virtual bool TryGetValueCore<TKey, TValue>(TKey key, AnalysisValueProvider<TKey, TValue> valueProvider, [MaybeNullWhen(false)] out TValue value) 627public bool TryGetValue<TValue>(SourceText text, SourceTextValueProvider<TValue> valueProvider, [MaybeNullWhen(false)] out TValue value) 642public bool TryGetValue<TValue>(AdditionalText text, AdditionalTextValueProvider<TValue> valueProvider, [MaybeNullWhen(false)] out TValue value) 657public bool TryGetValue<TValue>(SyntaxTree tree, SyntaxTreeValueProvider<TValue> valueProvider, [MaybeNullWhen(false)] out TValue value) 662private bool TryGetValue<TKey, TValue>(TKey key, AnalysisValueProvider<TKey, TValue> valueProvider, [MaybeNullWhen(false)] out TValue value)
DiagnosticAnalyzer\DiagnosticStartAnalysisScope.cs (1)
213internal override bool TryGetValueCore<TKey, TValue>(TKey key, AnalysisValueProvider<TKey, TValue> valueProvider, [MaybeNullWhen(false)] out TValue value)
InternalUtilities\ConcurrentLruCache.cs (2)
165public bool TryGetValue(K key, [MaybeNullWhen(returnValue: false)] out V value) 176public bool UnsafeTryGetValue(K key, [MaybeNullWhen(returnValue: false)] out V value)
src\Dependencies\Collections\RoslynImmutableInterlocked.cs (1)
587public static bool TryRemove<TKey, TValue>(ref ImmutableSegmentedDictionary<TKey, TValue> location, TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2.cs (1)
263public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2+Builder.cs (1)
118public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2+ValueBuilder.cs (1)
225public readonly bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\SegmentedDictionary`2.cs (2)
771public bool Remove(TKey key, [MaybeNullWhen(false)] out TValue value) 853public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\SegmentedHashSet`1.cs (1)
398public bool TryGetValue(T equalValue, [MaybeNullWhen(false)] out T actualValue)
src\Dependencies\Collections\Specialized\SpecializedCollections.Empty.Dictionary.cs (1)
57public bool TryGetValue(TKey key, [MaybeNullWhen(returnValue: false)] out TValue value)
src\Dependencies\PooledObjects\ArrayBuilder.cs (1)
922public bool TryPop([MaybeNullWhen(false)] out T result)
Symbols\TypedConstant.cs (1)
135internal bool TryDecodeValue<T>(SpecialType specialType, [MaybeNullWhen(false)] out T value)
Microsoft.CodeAnalysis.Collections.Package (9)
RoslynImmutableInterlocked.cs (1)
587public static bool TryRemove<TKey, TValue>(ref ImmutableSegmentedDictionary<TKey, TValue> location, TKey key, [MaybeNullWhen(false)] out TValue value)
Segmented\ImmutableSegmentedDictionary`2.cs (1)
263public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
Segmented\ImmutableSegmentedDictionary`2+Builder.cs (1)
118public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
Segmented\ImmutableSegmentedDictionary`2+ValueBuilder.cs (1)
225public readonly bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
Segmented\SegmentedDictionary`2.cs (2)
771public bool Remove(TKey key, [MaybeNullWhen(false)] out TValue value) 853public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
Segmented\SegmentedHashSet`1.cs (1)
398public bool TryGetValue(T equalValue, [MaybeNullWhen(false)] out T actualValue)
Specialized\SpecializedCollections.Empty.Dictionary.cs (1)
57public bool TryGetValue(TKey key, [MaybeNullWhen(returnValue: false)] out TValue value)
src\Dependencies\PooledObjects\ArrayBuilder.cs (1)
922public bool TryPop([MaybeNullWhen(false)] out T result)
Microsoft.CodeAnalysis.CSharp (2)
FlowAnalysis\NullableWalker.cs (1)
6531bool tryGetReceiver(BoundCall node, [MaybeNullWhen(returnValue: false)] out BoundCall receiver)
Lowering\LocalRewriter\LocalRewriter_Call.cs (1)
435internal static bool TryGetReceiver(BoundCall node, [MaybeNullWhen(returnValue: false)] out BoundCall receiver)
Microsoft.CodeAnalysis.Workspaces (27)
Differencing\TreeComparer.cs (2)
94protected internal abstract bool TryGetParent(TNode node, [MaybeNullWhen(false)] out TNode parent); 103internal bool TryGetAncestor(TNode node, int level, [MaybeNullWhen(false)] out TNode ancestor)
Log\AbstractLogAggregator.cs (1)
51protected bool TryGetCounter(TKey key, [MaybeNullWhen(false)] out TValue counter)
src\Compilers\Core\Portable\Collections\OrderPreservingMultiDictionary.cs (2)
112public bool TryGetValue<TArg>(K key, Func<V, TArg, bool> predicate, TArg arg, [MaybeNullWhen(false)] out V value) 232public bool TryGetValue<TArg>(Func<V, TArg, bool> predicate, TArg arg, [MaybeNullWhen(false)] out V value)
src\Dependencies\Collections\RoslynImmutableInterlocked.cs (1)
587public static bool TryRemove<TKey, TValue>(ref ImmutableSegmentedDictionary<TKey, TValue> location, TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2.cs (1)
263public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2+Builder.cs (1)
118public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2+ValueBuilder.cs (1)
225public readonly bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\SegmentedDictionary`2.cs (2)
771public bool Remove(TKey key, [MaybeNullWhen(false)] out TValue value) 853public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\SegmentedHashSet`1.cs (1)
398public bool TryGetValue(T equalValue, [MaybeNullWhen(false)] out T actualValue)
src\Dependencies\Collections\Specialized\SpecializedCollections.Empty.Dictionary.cs (1)
57public bool TryGetValue(TKey key, [MaybeNullWhen(returnValue: false)] out TValue value)
src\Dependencies\PooledObjects\ArrayBuilder.cs (1)
922public bool TryPop([MaybeNullWhen(false)] out T result)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\EditorConfigValueSerializer`1.cs (1)
40internal bool TryParseValue(string value, [MaybeNullWhen(false)] out T result)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\AsyncLazy`1.cs (2)
17public abstract bool TryGetValue([MaybeNullWhen(false)] out T result); 185public override bool TryGetValue([MaybeNullWhen(false)] out T result)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\CancellableLazy`1.cs (1)
34public bool TryGetValue([MaybeNullWhen(false)] out T value)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\IBidirectionalMap.cs (2)
14bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value); 15bool TryGetKey(TValue value, [MaybeNullWhen(false)] out TKey key);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Workspace\Mef\MefLanguageServices.cs (1)
93internal bool TryGetService<TLanguageService>(HostWorkspaceServices.MetadataFilter filter, [MaybeNullWhen(false)] out TLanguageService languageService)
Workspace\Solution\ConstantTextAndVersionSource.cs (1)
33public bool TryGetValue(LoadTextOptions options, [MaybeNullWhen(false)] out TextAndVersion value)
Workspace\Solution\VersionSource\ITextAndVersionSource.cs (1)
25bool TryGetValue(LoadTextOptions options, [MaybeNullWhen(false)] out TextAndVersion value);
Workspace\Solution\VersionSource\LoadableTextAndVersionSource.cs (2)
43public bool TryGetValue([MaybeNullWhen(false)] out TextAndVersion value) 129public bool TryGetValue(LoadTextOptions options, [MaybeNullWhen(false)] out TextAndVersion value)
Workspace\Solution\VersionSource\RecoverableTextAndVersion.cs (1)
54public bool TryGetValue(LoadTextOptions options, [MaybeNullWhen(false)] out TextAndVersion value)
Workspace\Solution\VersionSource\RecoverableTextAndVersion.RecoverableText.cs (1)
83public bool TryGetValue([MaybeNullWhen(false)] out SourceText value)
Microsoft.CodeAnalysis.Workspaces.MSBuild.BuildHost (11)
src\Compilers\Core\Portable\InternalUtilities\ConcurrentLruCache.cs (2)
165public bool TryGetValue(K key, [MaybeNullWhen(returnValue: false)] out V value) 176public bool UnsafeTryGetValue(K key, [MaybeNullWhen(returnValue: false)] out V value)
src\Dependencies\Collections\RoslynImmutableInterlocked.cs (1)
587public static bool TryRemove<TKey, TValue>(ref ImmutableSegmentedDictionary<TKey, TValue> location, TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2.cs (1)
263public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2+Builder.cs (1)
118public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2+ValueBuilder.cs (1)
225public readonly bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\SegmentedDictionary`2.cs (2)
771public bool Remove(TKey key, [MaybeNullWhen(false)] out TValue value) 853public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\SegmentedHashSet`1.cs (1)
398public bool TryGetValue(T equalValue, [MaybeNullWhen(false)] out T actualValue)
src\Dependencies\Collections\Specialized\SpecializedCollections.Empty.Dictionary.cs (1)
57public bool TryGetValue(TKey key, [MaybeNullWhen(returnValue: false)] out TValue value)
src\Dependencies\PooledObjects\ArrayBuilder.cs (1)
922public bool TryPop([MaybeNullWhen(false)] out T result)
Microsoft.Extensions.AI.Abstractions (1)
AdditionalPropertiesDictionary{TValue}.cs (1)
196public bool TryGetValue(string key, [MaybeNullWhen(false)] out TValue value) => _dictionary.TryGetValue(key, out value);
Microsoft.Extensions.AI.Abstractions.Tests (1)
test\Shared\JsonSchemaExporter\TestTypes.cs (1)
1168public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value) => _dictionary.TryGetValue(key, out value);
Microsoft.Extensions.AsyncState (2)
IAsyncContext.cs (1)
45bool TryGet([MaybeNullWhen(false)] out T? context);
IAsyncState.cs (1)
36bool TryGet(AsyncStateToken token, [MaybeNullWhen(false)] out object? value);
Microsoft.Extensions.DependencyModel (2)
Resolution\PackageCompilationAssemblyResolver.cs (1)
95private static bool TryResolveFromPackagePath(IFileSystem fileSystem, CompilationLibrary library, string basePath, [MaybeNullWhen(false)] out IEnumerable<string> results)
Resolution\ReferenceAssemblyPathResolver.cs (1)
63private bool TryResolveReferenceAssembly(string path, [MaybeNullWhen(false)] out string fullPath)
Microsoft.Extensions.Options (1)
OptionsCache.cs (1)
78internal bool TryGetValue(string? name, [MaybeNullWhen(false)] out TOptions options)
Microsoft.Maui (2)
Handlers\HybridWebView\FileExtensionContentTypeProvider.cs (1)
439 public bool TryGetContentType(string subpath, [MaybeNullWhen(false)] out string contentType)
WeakReferenceExtensions.cs (1)
8 internal static bool TryGetTarget<T>(this WeakReference self, [MaybeNullWhen(false), NotNullWhen(true)] out T? target)
Microsoft.Maui.Controls (2)
Internals\WeakEventProxy.cs (2)
25 public bool TryGetSource([MaybeNullWhen(false)] out TSource source) 36 public bool TryGetHandler([MaybeNullWhen(false)] out TEventHandler handler)
PresentationCore (19)
System\Windows\clipboard.cs (2)
444[NotNullWhen(true), MaybeNullWhen(false)] out T data) 478[NotNullWhen(true), MaybeNullWhen(false)] out T data)
System\Windows\dataobject.cs (5)
148[NotNullWhen(true), MaybeNullWhen(false)] out T data) 159[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 164[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 168[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 175[NotNullWhen(true), MaybeNullWhen(false)] out T data)
System\Windows\DataObjectExtensions.cs (4)
34[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 43[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 53[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 65[NotNullWhen(true), MaybeNullWhen(false)] out T data) =>
System\Windows\ITypedDataObject.cs (4)
28[NotNullWhen(true), MaybeNullWhen(false)] out T data); 33[NotNullWhen(true), MaybeNullWhen(false)] out T data); 39[NotNullWhen(true), MaybeNullWhen(false)] out T data); 48[NotNullWhen(true), MaybeNullWhen(false)] out T data);
System\Windows\Ole\DataObjectAdapter.cs (4)
34[MaybeNullWhen(false), NotNullWhen(true)] out T data) => DataObject.TryGetData(out data); 37[MaybeNullWhen(false), NotNullWhen(true)] out T data) => DataObject.TryGetData(format, out data); 41[NotNullWhen(true), MaybeNullWhen(false)] out T data) => DataObject.TryGetData(format, autoConvert, out data); 46[MaybeNullWhen(false), NotNullWhen(true)] out T data) => DataObject.TryGetData(format, resolver, autoConvert, out data);
PresentationFramework (1)
System\Windows\Markup\Localizer\BamlLocalizationDictionary.cs (1)
266internal bool TryGetValue(BamlLocalizableResourceKey key, [MaybeNullWhen(false)] out BamlLocalizableResource value)
Shared.Tests (1)
JsonSchemaExporter\TestTypes.cs (1)
1168public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value) => _dictionary.TryGetValue(key, out value);
System.Collections (14)
System\Collections\Generic\OrderedDictionary.cs (3)
746public bool Remove(TKey key, [MaybeNullWhen(false)] out TValue value) 921public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value) => TryGetValue(key, out value, out _); 932public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value, out int index)
System\Collections\Generic\PriorityQueue.cs (6)
315public bool TryDequeue([MaybeNullWhen(false)] out TElement element, [MaybeNullWhen(false)] out TPriority priority) 341public bool TryPeek([MaybeNullWhen(false)] out TElement element, [MaybeNullWhen(false)] out TPriority priority) 521[MaybeNullWhen(false)] out TElement removedElement, 522[MaybeNullWhen(false)] out TPriority priority,
System\Collections\Generic\SortedDictionary.cs (1)
257public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
System\Collections\Generic\SortedList.cs (1)
671public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
System\Collections\Generic\SortedSet.cs (1)
2001public bool TryGetValue(T equalValue, [MaybeNullWhen(false)] out T actualValue)
System\Collections\Generic\Stack.cs (2)
205public bool TryPeek([MaybeNullWhen(false)] out T result) 244public bool TryPop([MaybeNullWhen(false)] out T result)
System.Collections.Concurrent (26)
System\Collections\Concurrent\BlockingCollection.cs (5)
555public bool TryTake([MaybeNullWhen(false)] out T item) 577public bool TryTake([MaybeNullWhen(false)] out T item, TimeSpan timeout) 598public bool TryTake([MaybeNullWhen(false)] out T item, int millisecondsTimeout) 623public bool TryTake([MaybeNullWhen(false)] out T item, int millisecondsTimeout, CancellationToken cancellationToken) 645private bool TryTakeWithNoTimeValidation([MaybeNullWhen(false)] out T item, int millisecondsTimeout, CancellationToken cancellationToken, CancellationTokenSource? combinedTokenSource)
System\Collections\Concurrent\ConcurrentBag.cs (7)
99public bool TryTake([MaybeNullWhen(false)] out T result) 112public bool TryPeek([MaybeNullWhen(false)] out T result) 170private bool TrySteal([MaybeNullWhen(false)] out T result, bool take) 243private static bool TryStealFromTo(WorkStealingQueue? startInclusive, WorkStealingQueue? endExclusive, [MaybeNullWhen(false)] out T result, bool take) 859internal bool TryLocalPop([MaybeNullWhen(false)] out T result) 934internal bool TryLocalPeek([MaybeNullWhen(false)] out T result) 967internal bool TrySteal([MaybeNullWhen(false)] out T result, bool take)
System\Collections\Concurrent\ConcurrentDictionary.cs (10)
396public bool TryRemove(TKey key, [MaybeNullWhen(false)] out TValue value) 440private bool TryRemoveInternal(TKey key, [MaybeNullWhen(false)] out TValue value, bool matchValue, TValue? oldValue) 517public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value) 558private static bool TryGetValueInternal(Tables tables, TKey key, int hashcode, [MaybeNullWhen(false)] out TValue value) 2528public bool TryGetValue(TAlternateKey key, [MaybeNullWhen(false)] out TValue value) => 2543public bool TryGetValue(TAlternateKey key, [MaybeNullWhen(false)] out TKey actualKey, [MaybeNullWhen(false)] out TValue value) 2577public bool TryRemove(TAlternateKey key, [MaybeNullWhen(false)] out TValue value) => 2589public bool TryRemove(TAlternateKey key, [MaybeNullWhen(false)] out TKey actualKey, [MaybeNullWhen(false)] out TValue value)
System\Collections\Concurrent\ConcurrentStack.cs (4)
432public bool TryPeek([MaybeNullWhen(false)] out T result) 459public bool TryPop([MaybeNullWhen(false)] out T result) 555private bool TryPopCore([MaybeNullWhen(false)] out T result) 669bool IProducerConsumerCollection<T>.TryTake([MaybeNullWhen(false)] out T item)
System.Collections.Immutable (17)
System\Collections\Frozen\FrozenDictionary.AlternateLookup.cs (1)
131public bool TryGetValue(TAlternateKey key, [MaybeNullWhen(false)] out TValue value)
System\Collections\Frozen\FrozenDictionary.cs (1)
612public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
System\Collections\Frozen\FrozenSet.AlternateLookup.cs (1)
103public bool TryGetValue(TAlternate equalValue, [MaybeNullWhen(false)] out T actualValue)
System\Collections\Frozen\FrozenSet.cs (1)
314public bool TryGetValue(T equalValue, [MaybeNullWhen(false)] out T actualValue)
System\Collections\Immutable\AllocFreeConcurrentStack.cs (1)
37public static bool TryTake([MaybeNullWhen(false)] out T item)
System\Collections\Immutable\ImmutableDictionary_2.Builder.cs (1)
591public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
System\Collections\Immutable\ImmutableDictionary_2.cs (2)
414public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value) 905private static bool TryGetValue(TKey key, MutationInput origin, [MaybeNullWhen(false)] out TValue value)
System\Collections\Immutable\ImmutableDictionary_2.HashBucket.cs (1)
260internal bool TryGetValue(TKey key, Comparers comparers, [MaybeNullWhen(false)] out TValue value)
System\Collections\Immutable\ImmutableInterlocked.cs (3)
504public static bool TryRemove<TKey, TValue>(ref ImmutableDictionary<TKey, TValue> location, TKey key, [MaybeNullWhen(false)] out TValue value) where TKey : notnull 537public static bool TryPop<T>(ref ImmutableStack<T> location, [MaybeNullWhen(false)] out T value) 592public static bool TryDequeue<T>(ref ImmutableQueue<T> location, [MaybeNullWhen(false)] out T value)
System\Collections\Immutable\ImmutableSortedDictionary_2.Builder.cs (1)
466public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
System\Collections\Immutable\ImmutableSortedDictionary_2.cs (1)
448public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
System\Collections\Immutable\ImmutableSortedDictionary_2.Node.cs (1)
314internal bool TryGetValue(TKey key, IComparer<TKey> keyComparer, [MaybeNullWhen(false)] out TValue value)
System\Collections\Immutable\SecureObjectPool.cs (1)
117internal bool TryUse<TCaller>(ref TCaller caller, [MaybeNullWhen(false)] out T value)
System\Collections\Immutable\SortedInt32KeyNode.cs (1)
213internal bool TryGetValue(int key, [MaybeNullWhen(false)] out TValue value)
System.ComponentModel.Composition (3)
System\ComponentModel\Composition\Hosting\AtomicComposition.cs (3)
73public bool TryGetValue<T>(object key, [MaybeNullWhen(false)] out T value) 78public bool TryGetValue<T>(object key, bool localAtomicCompositionOnly, [MaybeNullWhen(false)] out T value) 268private bool TryGetValueInternal<T>(object key, bool localAtomicCompositionOnly, [MaybeNullWhen(false)] out T value)
System.Formats.Nrbf (1)
System\Formats\Nrbf\RecordMap.cs (1)
26public bool TryGetValue(SerializationRecordId key, [MaybeNullWhen(false)] out SerializationRecord value) => _map.TryGetValue(key, out value);
System.IO.Packaging (1)
System\IO\Packaging\OrderedDictionary.cs (1)
57public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
System.Linq (1)
System\Linq\ElementAt.cs (1)
151private static bool TryGetElementFromEnd<TSource>(IEnumerable<TSource> source, int indexFromEnd, [MaybeNullWhen(false)] out TSource element)
System.Linq.Expressions (2)
System\Dynamic\Utils\CacheDict.cs (1)
53internal bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
System\Linq\Expressions\Interpreter\Utilities.cs (1)
176public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
System.Linq.Parallel (45)
System\Linq\Parallel\Channels\AsynchronousChannel.cs (2)
403internal bool TryDequeue([MaybeNullWhen(false), AllowNull] ref T item) 479internal bool TryDequeue([MaybeNullWhen(false), AllowNull] ref T item, ref bool isDone)
System\Linq\Parallel\Enumerables\EmptyEnumerable.cs (1)
44internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref T currentElement, ref int currentKey)
System\Linq\Parallel\Enumerables\RepeatEnumerable.cs (1)
102internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TResult currentElement, ref int currentKey)
System\Linq\Parallel\Partitioning\PartitionedDataSource.cs (5)
258internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref T currentElement, ref int currentKey) 363internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref T currentElement, ref int currentKey) 429internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref T currentElement, ref int currentKey) 534internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref T currentElement, ref int currentKey) 610internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref T currentElement, ref int currentKey)
System\Linq\Parallel\QueryOperators\AssociativeAggregationOperator.cs (1)
259internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TIntermediate currentElement, ref int currentKey)
System\Linq\Parallel\QueryOperators\Binary\ConcatQueryOperator.cs (1)
187internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TSource currentElement, ref ConcatKey<TLeftKey, TRightKey> currentKey)
System\Linq\Parallel\QueryOperators\Binary\ExceptQueryOperator.cs (2)
169internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TInputOutput currentElement, ref int currentKey) 262internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TInputOutput currentElement, [AllowNull] ref TLeftKey currentKey)
System\Linq\Parallel\QueryOperators\Binary\HashJoinQueryOperatorEnumerator.cs (1)
93internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TOutput currentElement, [AllowNull] ref TOutputKey currentKey)
System\Linq\Parallel\QueryOperators\Binary\IntersectQueryOperator.cs (2)
157internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TInputOutput currentElement, ref int currentKey) 261internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TInputOutput currentElement, [AllowNull] ref TLeftKey currentKey)
System\Linq\Parallel\QueryOperators\Binary\UnionQueryOperator.cs (2)
215internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TInputOutput currentElement, ref int currentKey) 333internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TInputOutput currentElement, ref ConcatKey<TLeftKey, TRightKey> currentKey)
System\Linq\Parallel\QueryOperators\Inlined\InlinedAggregationOperatorEnumerator.cs (2)
54internal sealed override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TIntermediate currentElement, ref int currentKey) 67protected abstract bool MoveNextCore([MaybeNullWhen(false), AllowNull] ref TIntermediate currentElement);
System\Linq\Parallel\QueryOperators\PartitionerQueryOperator.cs (2)
216internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TElement currentElement, ref int currentKey) 251internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TElement currentElement, ref int currentKey)
System\Linq\Parallel\QueryOperators\QueryOperatorEnumerator.cs (1)
26internal abstract bool MoveNext([MaybeNullWhen(false), AllowNull] ref TElement currentElement, [AllowNull] ref TKey currentKey);
System\Linq\Parallel\QueryOperators\Unary\DefaultIfEmptyQueryOperator.cs (1)
144internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TSource currentElement, [AllowNull] ref TKey currentKey)
System\Linq\Parallel\QueryOperators\Unary\DistinctQueryOperator.cs (2)
144internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TInputOutput currentElement, ref int currentKey) 224internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TInputOutput currentElement, [AllowNull] ref TKey currentKey)
System\Linq\Parallel\QueryOperators\Unary\ElementAtQueryOperator.cs (2)
125internal bool Aggregate([MaybeNullWhen(false)] out TSource result, bool withDefaultValue) 197internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TSource currentElement, ref int currentKey)
System\Linq\Parallel\QueryOperators\Unary\FirstQueryOperator.cs (1)
161internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TSource currentElement, ref int currentKey)
System\Linq\Parallel\QueryOperators\Unary\ForAllOperator.cs (1)
149internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TInput currentElement, ref int currentKey)
System\Linq\Parallel\QueryOperators\Unary\GroupByQueryOperator.cs (2)
256internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref IGrouping<TGroupKey, TElement> currentElement, [AllowNull] ref TOrderKey currentKey) 462internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref IGrouping<TGroupKey, TElement> currentElement, [AllowNull] ref TOrderKey currentKey)
System\Linq\Parallel\QueryOperators\Unary\IndexedSelectQueryOperator.cs (1)
155internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TOutput currentElement, ref int currentKey)
System\Linq\Parallel\QueryOperators\Unary\IndexedWhereQueryOperator.cs (1)
163internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TInputOutput currentElement, ref int currentKey)
System\Linq\Parallel\QueryOperators\Unary\LastQueryOperator.cs (1)
157internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TSource currentElement, ref int currentKey)
System\Linq\Parallel\QueryOperators\Unary\ReverseQueryOperator.cs (1)
127internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TSource currentElement, [AllowNull] ref TKey currentKey)
System\Linq\Parallel\QueryOperators\Unary\SelectManyQueryOperator.cs (2)
273internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TOutput currentElement, ref Pair<int, int> currentKey) 402internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TOutput currentElement, ref Pair<TLeftKey, int> currentKey)
System\Linq\Parallel\QueryOperators\Unary\SelectQueryOperator.cs (1)
114internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TOutput currentElement, [AllowNull] ref TKey currentKey)
System\Linq\Parallel\QueryOperators\Unary\SortQueryOperator.cs (1)
193internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TInputOutput currentElement, [AllowNull] ref TSortKey currentKey)
System\Linq\Parallel\QueryOperators\Unary\TakeOrSkipQueryOperator.cs (1)
193internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TResult currentElement, [AllowNull] ref TKey currentKey)
System\Linq\Parallel\QueryOperators\Unary\TakeOrSkipWhileQueryOperator.cs (1)
252internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TResult currentElement, [AllowNull] ref TKey currentKey)
System\Linq\Parallel\QueryOperators\Unary\WhereQueryOperator.cs (1)
128internal override bool MoveNext([MaybeNullWhen(false), AllowNull] ref TInputOutput currentElement, [AllowNull] ref TKey currentKey)
System\Linq\Parallel\Utils\HashLookup.cs (2)
47internal bool TryGetValue(TKey key, [MaybeNullWhen(false), AllowNull] ref TValue value) 75private bool Find(TKey key, bool add, bool set, [MaybeNullWhen(false)] ref TValue value)
System.Net.Http (4)
src\libraries\Common\src\System\Collections\Generic\BidirectionalDictionary.cs (2)
38public bool TryGetForward(T1 item1, [MaybeNullWhen(false)] out T2 item2) 43public bool TryGetBackward(T2 item2, [MaybeNullWhen(false)] out T1 item1)
System\Net\Http\HttpRequestOptions.cs (1)
64public bool TryGetValue<TValue>(HttpRequestOptionsKey<TValue> key, [MaybeNullWhen(false)] out TValue value)
System\Net\Http\SocketsHttpHandler\ConnectionPool\RequestQueue.cs (1)
142public bool TryDequeueWaiter(HttpConnectionPool pool, [MaybeNullWhen(false)] out HttpConnectionWaiter<T> waiter)
System.Net.WebSockets.Client (1)
System\Net\WebSockets\HttpResponseHeadersReadOnlyCollection.cs (1)
53public bool TryGetValue(string key, [MaybeNullWhen(false)] out IEnumerable<string> value)
System.ObjectModel (1)
System\Collections\ObjectModel\KeyedCollection.cs (1)
92public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TItem item)
System.Private.CoreLib (114)
src\libraries\Common\src\System\Collections\Concurrent\IProducerConsumerQueue.cs (1)
22bool TryDequeue([MaybeNullWhen(false)] out T result);
src\libraries\Common\src\System\Collections\Concurrent\MultiProducerMultiConsumerQueue.cs (1)
23bool IProducerConsumerQueue<T>.TryDequeue([MaybeNullWhen(false)] out T result) { return TryDequeue(out result); }
src\libraries\Common\src\System\Collections\Concurrent\SingleProducerSingleConsumerQueue.cs (5)
132public bool TryDequeue([MaybeNullWhen(false)] out T result) 154public bool TryPeek([MaybeNullWhen(false)] out T result) 177private bool TryDequeueSlow(Segment segment, T[] array, bool peek, [MaybeNullWhen(false)] out T result) 220public bool TryDequeueIf(Predicate<T>? predicate, [MaybeNullWhen(false)] out T result) 251private bool TryDequeueIfSlow(Predicate<T>? predicate, Segment segment, T[] array, [MaybeNullWhen(false)] out T result)
src\libraries\System.Private.CoreLib\src\System\Byte.cs (3)
886static bool INumberBase<byte>.TryConvertToChecked<TOther>(byte value, [MaybeNullWhen(false)] out TOther result) 960static bool INumberBase<byte>.TryConvertToSaturating<TOther>(byte value, [MaybeNullWhen(false)] out TOther result) 1034static bool INumberBase<byte>.TryConvertToTruncating<TOther>(byte value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\Char.cs (3)
1732static bool INumberBase<char>.TryConvertToChecked<TOther>(char value, [MaybeNullWhen(false)] out TOther result) 1806static bool INumberBase<char>.TryConvertToSaturating<TOther>(char value, [MaybeNullWhen(false)] out TOther result) 1880static bool INumberBase<char>.TryConvertToTruncating<TOther>(char value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\Collections\Concurrent\ConcurrentQueue.cs (5)
201bool IProducerConsumerCollection<T>.TryTake([MaybeNullWhen(false)] out T item) => TryDequeue(out item); 668public bool TryDequeue([MaybeNullWhen(false)] out T result) 692private bool TryDequeueSlow([MaybeNullWhen(false)] out T item) 751public bool TryPeek([MaybeNullWhen(false)] out T result) => TryPeek(out result, resultUsed: true); 757private bool TryPeek([MaybeNullWhen(false)] out T result, bool resultUsed)
src\libraries\System.Private.CoreLib\src\System\Collections\Concurrent\ConcurrentQueueSegment.cs (2)
107public bool TryDequeue([MaybeNullWhen(false)] out T item) 193public bool TryPeek([MaybeNullWhen(false)] out T result, bool resultUsed)
src\libraries\System.Private.CoreLib\src\System\Collections\Concurrent\IProducerConsumerCollection.cs (1)
61bool TryTake([MaybeNullWhen(false)] out T item);
src\libraries\System.Private.CoreLib\src\System\Collections\Generic\CollectionExtensions.cs (1)
40public static bool Remove<TKey, TValue>(this IDictionary<TKey, TValue> dictionary, TKey key, [MaybeNullWhen(false)] out TValue value)
src\libraries\System.Private.CoreLib\src\System\Collections\Generic\Dictionary.cs (8)
750public bool TryGetValue(TAlternateKey key, [MaybeNullWhen(false)] out TValue value) 775public bool TryGetValue(TAlternateKey key, [MaybeNullWhen(false)] out TKey actualKey, [MaybeNullWhen(false)] out TValue value) 800internal ref TValue FindValue(TAlternateKey key, [MaybeNullWhen(false)] out TKey actualKey) 871public bool Remove(TAlternateKey key, [MaybeNullWhen(false)] out TKey actualKey, [MaybeNullWhen(false)] out TValue value) 1364public bool Remove(TKey key, [MaybeNullWhen(false)] out TValue value) 1441public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\libraries\System.Private.CoreLib\src\System\Collections\Generic\HashSet.cs (2)
612public bool TryGetValue(TAlternate equalValue, [MaybeNullWhen(false)] out T actualValue) 784public bool TryGetValue(T equalValue, [MaybeNullWhen(false)] out T actualValue)
src\libraries\System.Private.CoreLib\src\System\Collections\Generic\IDictionary.cs (1)
47bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value);
src\libraries\System.Private.CoreLib\src\System\Collections\Generic\IReadOnlyDictionary.cs (1)
12bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value);
src\libraries\System.Private.CoreLib\src\System\Collections\Generic\Queue.cs (2)
215public bool TryDequeue([MaybeNullWhen(false)] out T result) 250public bool TryPeek([MaybeNullWhen(false)] out T result)
src\libraries\System.Private.CoreLib\src\System\Collections\ObjectModel\ReadOnlyDictionary.cs (1)
46public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\libraries\System.Private.CoreLib\src\System\Decimal.cs (4)
1640static bool INumberBase<decimal>.TryConvertToChecked<TOther>(decimal value, [MaybeNullWhen(false)] out TOther result) 1714static bool INumberBase<decimal>.TryConvertToSaturating<TOther>(decimal value, [MaybeNullWhen(false)] out TOther result) 1721static bool INumberBase<decimal>.TryConvertToTruncating<TOther>(decimal value, [MaybeNullWhen(false)] out TOther result) 1727private static bool TryConvertTo<TOther>(decimal value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\Diagnostics\Tracing\TraceLogging\EventPayload.cs (1)
110public bool TryGetValue(string key, [MaybeNullWhen(false)] out object? value)
src\libraries\System.Private.CoreLib\src\System\Double.cs (4)
1299static bool INumberBase<double>.TryConvertToChecked<TOther>(double value, [MaybeNullWhen(false)] out TOther result) 1367static bool INumberBase<double>.TryConvertToSaturating<TOther>(double value, [MaybeNullWhen(false)] out TOther result) 1374static bool INumberBase<double>.TryConvertToTruncating<TOther>(double value, [MaybeNullWhen(false)] out TOther result) 1380private static bool TryConvertTo<TOther>(double value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\Half.cs (4)
2001static bool INumberBase<Half>.TryConvertToChecked<TOther>(Half value, [MaybeNullWhen(false)] out TOther result) 2069static bool INumberBase<Half>.TryConvertToSaturating<TOther>(Half value, [MaybeNullWhen(false)] out TOther result) 2076static bool INumberBase<Half>.TryConvertToTruncating<TOther>(Half value, [MaybeNullWhen(false)] out TOther result) 2082private static bool TryConvertTo<TOther>(Half value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\Int128.cs (3)
1709static bool INumberBase<Int128>.TryConvertToChecked<TOther>(Int128 value, [MaybeNullWhen(false)] out TOther result) 1777static bool INumberBase<Int128>.TryConvertToSaturating<TOther>(Int128 value, [MaybeNullWhen(false)] out TOther result) 1852static bool INumberBase<Int128>.TryConvertToTruncating<TOther>(Int128 value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\Int16.cs (3)
1100static bool INumberBase<short>.TryConvertToChecked<TOther>(short value, [MaybeNullWhen(false)] out TOther result) 1168static bool INumberBase<short>.TryConvertToSaturating<TOther>(short value, [MaybeNullWhen(false)] out TOther result) 1237static bool INumberBase<short>.TryConvertToTruncating<TOther>(short value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\Int32.cs (3)
1164static bool INumberBase<int>.TryConvertToChecked<TOther>(int value, [MaybeNullWhen(false)] out TOther result) 1232static bool INumberBase<int>.TryConvertToSaturating<TOther>(int value, [MaybeNullWhen(false)] out TOther result) 1303static bool INumberBase<int>.TryConvertToTruncating<TOther>(int value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\Int64.cs (3)
1159static bool INumberBase<long>.TryConvertToChecked<TOther>(long value, [MaybeNullWhen(false)] out TOther result) 1227static bool INumberBase<long>.TryConvertToSaturating<TOther>(long value, [MaybeNullWhen(false)] out TOther result) 1306static bool INumberBase<long>.TryConvertToTruncating<TOther>(long value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\IntPtr.cs (3)
1155static bool INumberBase<nint>.TryConvertToChecked<TOther>(nint value, [MaybeNullWhen(false)] out TOther result) 1223static bool INumberBase<nint>.TryConvertToSaturating<TOther>(nint value, [MaybeNullWhen(false)] out TOther result) 1295static bool INumberBase<nint>.TryConvertToTruncating<TOther>(nint value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\IParsable.cs (1)
27static abstract bool TryParse([NotNullWhen(true)] string? s, IFormatProvider? provider, [MaybeNullWhen(returnValue: false)] out TSelf result);
src\libraries\System.Private.CoreLib\src\System\ISpanParsable.cs (1)
26static abstract bool TryParse(ReadOnlySpan<char> s, IFormatProvider? provider, [MaybeNullWhen(returnValue: false)] out TSelf result);
src\libraries\System.Private.CoreLib\src\System\IUtf8SpanParsable.cs (1)
26static abstract bool TryParse(ReadOnlySpan<byte> utf8Text, IFormatProvider? provider, [MaybeNullWhen(returnValue: false)] out TSelf result);
src\libraries\System.Private.CoreLib\src\System\Numerics\INumberBase.cs (10)
357protected static abstract bool TryConvertFromChecked<TOther>(TOther value, [MaybeNullWhen(false)] out TSelf result) 367protected static abstract bool TryConvertFromSaturating<TOther>(TOther value, [MaybeNullWhen(false)] out TSelf result) 377protected static abstract bool TryConvertFromTruncating<TOther>(TOther value, [MaybeNullWhen(false)] out TSelf result) 388protected static abstract bool TryConvertToChecked<TOther>(TSelf value, [MaybeNullWhen(false)] out TOther result) 398protected static abstract bool TryConvertToSaturating<TOther>(TSelf value, [MaybeNullWhen(false)] out TOther result) 408protected static abstract bool TryConvertToTruncating<TOther>(TSelf value, [MaybeNullWhen(false)] out TOther result) 420static abstract bool TryParse([NotNullWhen(true)] string? s, NumberStyles style, IFormatProvider? provider, [MaybeNullWhen(false)] out TSelf result); 429static abstract bool TryParse(ReadOnlySpan<char> s, NumberStyles style, IFormatProvider? provider, [MaybeNullWhen(false)] out TSelf result); 438static virtual bool TryParse(ReadOnlySpan<byte> utf8Text, NumberStyles style, IFormatProvider? provider, [MaybeNullWhen(false)] out TSelf result) 587static bool IUtf8SpanParsable<TSelf>.TryParse(ReadOnlySpan<byte> utf8Text, IFormatProvider? provider, [MaybeNullWhen(returnValue: false)] out TSelf result)
src\libraries\System.Private.CoreLib\src\System\Runtime\CompilerServices\ConditionalWeakTable.cs (5)
53public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value) 161public bool Remove(TKey key, [MaybeNullWhen(false)] out TValue value) 629internal bool TryGetValueWorker(TKey key, [MaybeNullWhen(false)] out TValue value) 675internal bool TryGetEntry(int index, [NotNullWhen(true)] out TKey? key, [MaybeNullWhen(false)] out TValue value) 706internal bool Remove(TKey key, [MaybeNullWhen(false)] out TValue value)
src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\NFloat.cs (4)
1528static bool INumberBase<NFloat>.TryConvertToChecked<TOther>(NFloat value, [MaybeNullWhen(false)] out TOther result) 1641static bool INumberBase<NFloat>.TryConvertToSaturating<TOther>(NFloat value, [MaybeNullWhen(false)] out TOther result) 1648static bool INumberBase<NFloat>.TryConvertToTruncating<TOther>(NFloat value, [MaybeNullWhen(false)] out TOther result) 1654private static bool TryConvertTo<TOther>(NFloat value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\TypeMapLazyDictionary.cs (1)
252public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out Type value) => TryGetOrLoadType(key, out value);
src\libraries\System.Private.CoreLib\src\System\SByte.cs (3)
1064static bool INumberBase<sbyte>.TryConvertToChecked<TOther>(sbyte value, [MaybeNullWhen(false)] out TOther result) 1132static bool INumberBase<sbyte>.TryConvertToSaturating<TOther>(sbyte value, [MaybeNullWhen(false)] out TOther result) 1200static bool INumberBase<sbyte>.TryConvertToTruncating<TOther>(sbyte value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\Single.cs (4)
1318static bool INumberBase<float>.TryConvertToChecked<TOther>(float value, [MaybeNullWhen(false)] out TOther result) 1386static bool INumberBase<float>.TryConvertToSaturating<TOther>(float value, [MaybeNullWhen(false)] out TOther result) 1393static bool INumberBase<float>.TryConvertToTruncating<TOther>(float value, [MaybeNullWhen(false)] out TOther result) 1399private static bool TryConvertTo<TOther>(float value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\String.cs (2)
762static bool IParsable<string>.TryParse([NotNullWhen(true)] string? s, IFormatProvider? provider, [MaybeNullWhen(returnValue: false)] out string result) 781static bool ISpanParsable<string>.TryParse(ReadOnlySpan<char> s, IFormatProvider? provider, [MaybeNullWhen(returnValue: false)] out string result)
src\libraries\System.Private.CoreLib\src\System\Threading\ThreadPoolWorkQueue.cs (1)
867[MaybeNullWhen(false)] out object workItem)
src\libraries\System.Private.CoreLib\src\System\UInt128.cs (3)
1771static bool INumberBase<UInt128>.TryConvertToChecked<TOther>(UInt128 value, [MaybeNullWhen(false)] out TOther result) 1845static bool INumberBase<UInt128>.TryConvertToSaturating<TOther>(UInt128 value, [MaybeNullWhen(false)] out TOther result) 1925static bool INumberBase<UInt128>.TryConvertToTruncating<TOther>(UInt128 value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\UInt16.cs (3)
905static bool INumberBase<ushort>.TryConvertToChecked<TOther>(ushort value, [MaybeNullWhen(false)] out TOther result) 979static bool INumberBase<ushort>.TryConvertToSaturating<TOther>(ushort value, [MaybeNullWhen(false)] out TOther result) 1053static bool INumberBase<ushort>.TryConvertToTruncating<TOther>(ushort value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\UInt32.cs (3)
944static bool INumberBase<uint>.TryConvertToChecked<TOther>(uint value, [MaybeNullWhen(false)] out TOther result) 1018static bool INumberBase<uint>.TryConvertToSaturating<TOther>(uint value, [MaybeNullWhen(false)] out TOther result) 1098static bool INumberBase<uint>.TryConvertToTruncating<TOther>(uint value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\UInt64.cs (3)
943static bool INumberBase<ulong>.TryConvertToChecked<TOther>(ulong value, [MaybeNullWhen(false)] out TOther result) 1017static bool INumberBase<ulong>.TryConvertToSaturating<TOther>(ulong value, [MaybeNullWhen(false)] out TOther result) 1091static bool INumberBase<ulong>.TryConvertToTruncating<TOther>(ulong value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\UIntPtr.cs (3)
946static bool INumberBase<nuint>.TryConvertToChecked<TOther>(nuint value, [MaybeNullWhen(false)] out TOther result) 1020static bool INumberBase<nuint>.TryConvertToSaturating<TOther>(nuint value, [MaybeNullWhen(false)] out TOther result) 1094static bool INumberBase<nuint>.TryConvertToTruncating<TOther>(nuint value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\WeakReference.T.cs (1)
59public bool TryGetTarget([MaybeNullWhen(false), NotNullWhen(true)] out T target)
System.Private.DataContractSerialization (1)
System\Xml\XmlBinaryWriterSession.cs (1)
121public bool TryGetValue(K key, [MaybeNullWhen(false)] out V value)
System.Private.Windows.Core (17)
System\Private\Windows\Ole\Composition.cs (4)
161[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 167[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 172[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 176[NotNullWhen(true), MaybeNullWhen(false)] out T data) =>
System\Private\Windows\Ole\Composition.NativeToManagedAdapter.cs (4)
593[NotNullWhen(true), MaybeNullWhen(false)] out T data) 609[NotNullWhen(true), MaybeNullWhen(false)] out T data) 623[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 627[NotNullWhen(true), MaybeNullWhen(false)] out T data) =>
System\Private\Windows\Ole\DataStore.cs (5)
17[NotNullWhen(true), MaybeNullWhen(false)] out T data) 180[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 186[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 191[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 195[NotNullWhen(true), MaybeNullWhen(false)] out T data) =>
System\Private\Windows\Ole\IDataObjectInternal.cs (4)
98[NotNullWhen(true), MaybeNullWhen(false)] out T data); 106[NotNullWhen(true), MaybeNullWhen(false)] out T data); 116[NotNullWhen(true), MaybeNullWhen(false)] out T data); 154[NotNullWhen(true), MaybeNullWhen(false)] out T data);
System.Private.Windows.Core.Tests (9)
System\Private\Windows\Ole\TestDataObject.cs (5)
73[MaybeNullWhen(false), NotNullWhen(true)] out T data) => 78[MaybeNullWhen(false), NotNullWhen(true)] out T data) => 84[MaybeNullWhen(false), NotNullWhen(true)] out T data) => 91[MaybeNullWhen(false), NotNullWhen(true)] out T data) => 98[NotNullWhen(true), MaybeNullWhen(false)] out T data)
System\Private\Windows\Ole\TestDataObjectAdapter.cs (4)
31[MaybeNullWhen(false), NotNullWhen(true)] out T data) => 35[MaybeNullWhen(false), NotNullWhen(true)] out T data) => 40[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 46[MaybeNullWhen(false), NotNullWhen(true)] out T data) =>
System.Private.Xml (1)
System\Xml\Xsl\Xslt\Scripts.cs (1)
70public bool TryGetValue(string key, [MaybeNullWhen(false)] out Type value) => _backingDictionary.TryGetValue(key, out value);
System.Private.Xml.Linq (2)
System\Xml\Linq\XHashtable.cs (2)
84public bool TryGetValue(string key, int index, int count, [MaybeNullWhen(false)] out TValue value) 242public bool TryGetValue(string key, int index, int count, [MaybeNullWhen(false)] out TValue value)
System.Runtime.Numerics (6)
System\Numerics\BigInteger.cs (3)
4566static bool INumberBase<BigInteger>.TryConvertToChecked<TOther>(BigInteger value, [MaybeNullWhen(false)] out TOther result) 4685static bool INumberBase<BigInteger>.TryConvertToSaturating<TOther>(BigInteger value, [MaybeNullWhen(false)] out TOther result) 4878static bool INumberBase<BigInteger>.TryConvertToTruncating<TOther>(BigInteger value, [MaybeNullWhen(false)] out TOther result)
System\Numerics\Complex.cs (3)
1612static bool INumberBase<Complex>.TryConvertToChecked<TOther>(Complex value, [MaybeNullWhen(false)] out TOther result) 1811static bool INumberBase<Complex>.TryConvertToSaturating<TOther>(Complex value, [MaybeNullWhen(false)] out TOther result) 1955static bool INumberBase<Complex>.TryConvertToTruncating<TOther>(Complex value, [MaybeNullWhen(false)] out TOther result)
System.Text.Json (6)
System\Text\Json\JsonHelpers.cs (1)
221[MaybeNullWhen(false)] out TValue result)
System\Text\Json\Serialization\Converters\Collection\JsonCollectionConverter.cs (1)
66[MaybeNullWhen(false)] out TCollection value)
System\Text\Json\Serialization\Converters\Collection\JsonDictionaryConverter.cs (1)
77[MaybeNullWhen(false)] out TDictionary value)
System\Text\Json\Serialization\Converters\Object\ObjectDefaultConverter.cs (1)
20internal override bool OnTryRead(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options, scoped ref ReadStack state, [MaybeNullWhen(false)] out T value)
System\Text\Json\Serialization\Converters\Object\ObjectWithParameterizedConstructorConverter.cs (1)
24internal sealed override bool OnTryRead(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options, scoped ref ReadStack state, [MaybeNullWhen(false)] out T value)
System\Text\Json\ValueQueue.cs (1)
46public bool TryDequeue([MaybeNullWhen(false)] out T? value)
System.Threading.Channels (19)
src\libraries\Common\src\System\Collections\Concurrent\IProducerConsumerQueue.cs (1)
22bool TryDequeue([MaybeNullWhen(false)] out T result);
src\libraries\Common\src\System\Collections\Concurrent\MultiProducerMultiConsumerQueue.cs (1)
23bool IProducerConsumerQueue<T>.TryDequeue([MaybeNullWhen(false)] out T result) { return TryDequeue(out result); }
src\libraries\Common\src\System\Collections\Concurrent\SingleProducerSingleConsumerQueue.cs (5)
132public bool TryDequeue([MaybeNullWhen(false)] out T result) 154public bool TryPeek([MaybeNullWhen(false)] out T result) 177private bool TryDequeueSlow(Segment segment, T[] array, bool peek, [MaybeNullWhen(false)] out T result) 220public bool TryDequeueIf(Predicate<T>? predicate, [MaybeNullWhen(false)] out T result) 251private bool TryDequeueIfSlow(Predicate<T>? predicate, Segment segment, T[] array, [MaybeNullWhen(false)] out T result)
System\Threading\Channels\BoundedChannel.cs (2)
109public override bool TryRead([MaybeNullWhen(false)] out T item) 128public override bool TryPeek([MaybeNullWhen(false)] out T item)
System\Threading\Channels\ChannelReader.cs (2)
36public abstract bool TryRead([MaybeNullWhen(false)] out T item); 41public virtual bool TryPeek([MaybeNullWhen(false)] out T item)
System\Threading\Channels\RendezvousChannel.cs (2)
81public override bool TryRead([MaybeNullWhen(false)] out T item) 109public override bool TryPeek([MaybeNullWhen(false)] out T item)
System\Threading\Channels\SingleConsumerUnboundedChannel.cs (2)
123public override bool TryRead([MaybeNullWhen(false)] out T item) 137public override bool TryPeek([MaybeNullWhen(false)] out T item) =>
System\Threading\Channels\UnboundedChannel.cs (2)
109public override bool TryRead([MaybeNullWhen(false)] out T item) 124public override bool TryPeek([MaybeNullWhen(false)] out T item) =>
System\Threading\Channels\UnboundedPriorityChannel.cs (2)
110public override bool TryRead([MaybeNullWhen(false)] out T item) 127public override bool TryPeek([MaybeNullWhen(false)] out T item)
System.Threading.Tasks.Dataflow (19)
Base\DataflowBlock.cs (2)
766public static bool TryReceive<TOutput>(this IReceivableSourceBlock<TOutput> source, [MaybeNullWhen(false)] out TOutput item) 1562public bool TryReceive(Predicate<TOutput>? filter, [MaybeNullWhen(false)] out TOutput item)
Base\IReceivableSourceBlock.cs (1)
25bool TryReceive(Predicate<TOutput>? filter, [MaybeNullWhen(false)] out TOutput item);
Blocks\BroadcastBlock.cs (2)
151public bool TryReceive(Predicate<T>? filter, [MaybeNullWhen(false)] out T item) { return _source.TryReceive(filter, out item); } 561internal bool TryReceive(Predicate<TOutput>? filter, [MaybeNullWhen(false)] out TOutput item)
Blocks\BufferBlock.cs (1)
186public bool TryReceive(Predicate<T>? filter, [MaybeNullWhen(false)] out T item) { return _source.TryReceive(filter, out item); }
Blocks\TransformBlock.cs (1)
347public bool TryReceive(Predicate<TOutput>? filter, [MaybeNullWhen(false)] out TOutput item)
Blocks\TransformManyBlock.cs (1)
559public bool TryReceive(Predicate<TOutput>? filter, [MaybeNullWhen(false)] out TOutput item) { return _source.TryReceive(filter, out item); }
Blocks\WriteOnceBlock.cs (1)
256public bool TryReceive(Predicate<T>? filter, [MaybeNullWhen(false)] out T item)
Internal\Common.cs (1)
69TStateIn stateIn, [MaybeNullWhen(false)] out TStateOut stateOut)
Internal\QueuedMap.cs (1)
111internal bool TryDequeue([MaybeNullWhen(false)] out T item)
Internal\SourceCore.cs (1)
275internal bool TryReceive(Predicate<TOutput>? filter, [MaybeNullWhen(false)] out TOutput item)
src\libraries\Common\src\System\Collections\Concurrent\IProducerConsumerQueue.cs (1)
22bool TryDequeue([MaybeNullWhen(false)] out T result);
src\libraries\Common\src\System\Collections\Concurrent\MultiProducerMultiConsumerQueue.cs (1)
23bool IProducerConsumerQueue<T>.TryDequeue([MaybeNullWhen(false)] out T result) { return TryDequeue(out result); }
src\libraries\Common\src\System\Collections\Concurrent\SingleProducerSingleConsumerQueue.cs (5)
132public bool TryDequeue([MaybeNullWhen(false)] out T result) 154public bool TryPeek([MaybeNullWhen(false)] out T result) 177private bool TryDequeueSlow(Segment segment, T[] array, bool peek, [MaybeNullWhen(false)] out T result) 220public bool TryDequeueIf(Predicate<T>? predicate, [MaybeNullWhen(false)] out T result) 251private bool TryDequeueIfSlow(Predicate<T>? predicate, Segment segment, T[] array, [MaybeNullWhen(false)] out T result)
System.Windows.Forms (21)
System\Windows\Forms\OLE\Clipboard.cs (3)
308[NotNullWhen(true), MaybeNullWhen(false)] out T data) 342[NotNullWhen(true), MaybeNullWhen(false)] out T data) 357[NotNullWhen(true), MaybeNullWhen(false)] out T data) => TryGetData(typeof(T).FullName!, out data);
System\Windows\Forms\OLE\DataObject.cs (6)
156[NotNullWhen(true), MaybeNullWhen(false)] out T data) 167[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 172[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 176[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 189[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 266[NotNullWhen(true), MaybeNullWhen(false)] out T data)
System\Windows\Forms\OLE\DataObjectAdapter.cs (4)
31[MaybeNullWhen(false), NotNullWhen(true)] out T data) => DataObject.TryGetData(out data); 34[MaybeNullWhen(false), NotNullWhen(true)] out T data) => DataObject.TryGetData(format, out data); 38[NotNullWhen(true), MaybeNullWhen(false)] out T data) => DataObject.TryGetData(format, autoConvert, out data); 43[MaybeNullWhen(false), NotNullWhen(true)] out T data) => DataObject.TryGetData(format, resolver, autoConvert, out data);
System\Windows\Forms\OLE\DataObjectExtensions.cs (4)
30[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 39[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 49[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 61[NotNullWhen(true), MaybeNullWhen(false)] out T data) =>
System\Windows\Forms\OLE\ITypedDataObject.cs (4)
26[NotNullWhen(true), MaybeNullWhen(false)] out T data); 31[NotNullWhen(true), MaybeNullWhen(false)] out T data); 37[NotNullWhen(true), MaybeNullWhen(false)] out T data); 46[NotNullWhen(true), MaybeNullWhen(false)] out T data);
System.Windows.Forms.Design (1)
System\Windows\Forms\Design\CommandSet.cs (1)
424private static bool ExecuteSafely<T>(Func<T> func, bool throwOnException, [MaybeNullWhen(false)] out T result)
System.Windows.Forms.Tests (5)
System\Windows\Forms\DataObjectExtensionsTests.cs (4)
231public bool TryGetData<T>([MaybeNullWhen(false), NotNullWhen(true)] out T data) 238public bool TryGetData<T>(string format, [MaybeNullWhen(false), NotNullWhen(true)] out T data) 245public bool TryGetData<T>(string format, bool autoConvert, [MaybeNullWhen(false), NotNullWhen(true)] out T data) 252public bool TryGetData<T>(string format, Func<TypeName, Type?> resolver, bool autoConvert, [MaybeNullWhen(false), NotNullWhen(true)] out T data)
System\Windows\Forms\DataObjectTests.cs (1)
395[NotNullWhen(true), MaybeNullWhen(false)] out T data)
System.Windows.Forms.TestUtilities (8)
Data\TypedAndRuntimeDataObject.cs (4)
13public bool TryGetData<[DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.All)] T>([MaybeNullWhen(false), NotNullWhen(true)] out T data) => 15public bool TryGetData<[DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.All)] T>(string format, [MaybeNullWhen(false), NotNullWhen(true)] out T data) 27public bool TryGetData<[DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.All)] T>(string format, bool autoConvert, [MaybeNullWhen(false), NotNullWhen(true)] out T data) => 34[MaybeNullWhen(false), NotNullWhen(true)] out T data)
Data\TypedDataObject.cs (4)
13public bool TryGetData<[DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.All)] T>([MaybeNullWhen(false), NotNullWhen(true)] out T data) => 15public bool TryGetData<[DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.All)] T>(string format, [MaybeNullWhen(false), NotNullWhen(true)] out T data) 27public bool TryGetData<[DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.All)] T>(string format, bool autoConvert, [MaybeNullWhen(false), NotNullWhen(true)] out T data) => 33[MaybeNullWhen(false), NotNullWhen(true)] out T data) => TryGetData(format, out data);
Test.Utilities (30)
src\Compilers\Core\Portable\Collections\OrderPreservingMultiDictionary.cs (2)
112public bool TryGetValue<TArg>(K key, Func<V, TArg, bool> predicate, TArg arg, [MaybeNullWhen(false)] out V value) 232public bool TryGetValue<TArg>(Func<V, TArg, bool> predicate, TArg arg, [MaybeNullWhen(false)] out V value)
src\Dependencies\Collections\RoslynImmutableInterlocked.cs (1)
587public static bool TryRemove<TKey, TValue>(ref ImmutableSegmentedDictionary<TKey, TValue> location, TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2.cs (1)
263public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2+Builder.cs (1)
118public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\ImmutableSegmentedDictionary`2+ValueBuilder.cs (1)
225public readonly bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\SegmentedDictionary`2.cs (2)
771public bool Remove(TKey key, [MaybeNullWhen(false)] out TValue value) 853public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\Segmented\SegmentedHashSet`1.cs (1)
398public bool TryGetValue(T equalValue, [MaybeNullWhen(false)] out T actualValue)
src\Dependencies\Collections\Specialized\SpecializedCollections.Empty.Dictionary.cs (1)
57public bool TryGetValue(TKey key, [MaybeNullWhen(returnValue: false)] out TValue value)
src\Dependencies\PooledObjects\ArrayBuilder.cs (1)
922public bool TryPop([MaybeNullWhen(false)] out T result)
src\RoslynAnalyzers\Utilities\Compiler\Options\AbstractCategorizedAnalyzerConfigOptions.cs (4)
37static (string s, TryParseValue<T> tryParseValue, [MaybeNullWhen(returnValue: false)] out T parsedValue) => tryParseValue(s, out parsedValue), 113bool TryGetSpecificOptionValue(string specificOptionKey, string optionKeyPrefix, [MaybeNullWhen(false)] out T specificOptionValue) 124bool TryGetAnySpecificOptionValue(IEnumerable<string> specificOptionKeys, string optionKeyPrefix, [MaybeNullWhen(false)] out T specificOptionValue) 138bool TryGetGeneralOptionValue(string optionKeyPrefix, [MaybeNullWhen(false)] out T generalOptionValue)
src\RoslynAnalyzers\Utilities\Compiler\Options\AggregateCategorizedAnalyzerConfigOptions.cs (2)
91static (string s, TryParseValue<T> tryParseValue, [MaybeNullWhen(returnValue: false)] out T parsedValue) => tryParseValue(s, out parsedValue), 112private bool TryGetOptionValue<T, TArg>(string optionName, OptionKind kind, SyntaxTree? tree, DiagnosticDescriptor? rule, TryParseValue<T, TArg> tryParseValue, TArg arg, T defaultValue, [MaybeNullWhen(false)] out T value)
src\RoslynAnalyzers\Utilities\Compiler\Options\ICategorizedAnalyzerConfigOptions.cs (2)
58public delegate bool TryParseValue<T>(string value, [MaybeNullWhen(returnValue: false)] out T parsedValue); 60public delegate bool TryParseValue<T, TArg>(string value, TArg arg, [MaybeNullWhen(returnValue: false)] out T parsedValue);
src\RoslynAnalyzers\Utilities\Compiler\Options\SymbolNamesWithValueOption.cs (2)
237public bool TryGetValue(ISymbol symbol, [MaybeNullWhen(false)] out TValue value) 267private bool TryGetFirstWildcardMatch(ISymbol symbol, [NotNullWhen(true)] out string? firstMatchName, [MaybeNullWhen(false)] out TValue firstMatchValue)
src\RoslynAnalyzers\Utilities\Compiler\SmallDictionary.cs (3)
182public bool TryGetValue(K key, [MaybeNullWhen(returnValue: false)] out V value) 314private bool TryGetValue(int hashCode, K key, [MaybeNullWhen(returnValue: false)] out V value) 348private bool GetFromList(Node? next, K key, [MaybeNullWhen(returnValue: false)] out V value)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\EditorConfigValueSerializer`1.cs (1)
40internal bool TryParseValue(string value, [MaybeNullWhen(false)] out T result)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\AsyncLazy`1.cs (2)
17public abstract bool TryGetValue([MaybeNullWhen(false)] out T result); 185public override bool TryGetValue([MaybeNullWhen(false)] out T result)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\CancellableLazy`1.cs (1)
34public bool TryGetValue([MaybeNullWhen(false)] out T value)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\IBidirectionalMap.cs (2)
14bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value); 15bool TryGetKey(TValue value, [MaybeNullWhen(false)] out TKey key);
xunit.assert (1)
Sdk\CollectionTracker.cs (1)
908 [MaybeNullWhen(false)] out T item)
7 references to MaybeNullWhen
GenerateDocumentationAndConfigFiles (1)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Compilation\CompilationExtensions.cs (1)
262=> compilation.GetTypeByMetadataName(typeof(MaybeNullWhenAttribute).FullName!);
Microsoft.CodeAnalysis.Workspaces (1)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Compilation\CompilationExtensions.cs (1)
262=> compilation.GetTypeByMetadataName(typeof(MaybeNullWhenAttribute).FullName!);
Microsoft.Maui.Controls (1)
Internals\WeakEventProxy.cs (1)
7using MaybeNullWhenAttribute = System.Diagnostics.CodeAnalysis.MaybeNullWhenAttribute;
mscorlib (1)
mscorlib.cs (1)
64[assembly:System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Diagnostics.CodeAnalysis.MaybeNullWhenAttribute))]
netstandard (1)
netstandard.cs (1)
625[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Diagnostics.CodeAnalysis.MaybeNullWhenAttribute))]
System.Runtime (1)
artifacts\obj\System.Runtime\Debug\net10.0\System.Runtime.Forwards.cs (1)
143[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Diagnostics.CodeAnalysis.MaybeNullWhenAttribute))]
Test.Utilities (1)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Compilation\CompilationExtensions.cs (1)
262=> compilation.GetTypeByMetadataName(typeof(MaybeNullWhenAttribute).FullName!);