432 instantiations of MaybeNullWhen
Microsoft.AspNetCore.Components (11)
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 (1)
100public bool TryTakeFromJson<[DynamicallyAccessedMembers(JsonSerialized)] TValue>(string key, [MaybeNullWhen(false)] out TValue? 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 (1)
Rendering\EndpointHtmlRenderer.cs (1)
261public bool TryGetValue(string key, [MaybeNullWhen(false)] out StringValues value)
Microsoft.AspNetCore.Components.Endpoints.Tests (2)
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)
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)
438public 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)
2671public 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)
432public 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\ArrayBuilderExtensions.cs (1)
205public static bool TryPop<T>(this ArrayBuilder<T> builder, [MaybeNullWhen(false)] out T result)
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)
InternalUtilities\SpecializedCollections.Empty.Dictionary.cs (1)
55public bool TryGetValue(TKey key, [MaybeNullWhen(returnValue: false)] out TValue value)
src\Dependencies\Collections\ImmutableSegmentedDictionary`2.cs (1)
261public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\ImmutableSegmentedDictionary`2+Builder.cs (1)
116public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\ImmutableSegmentedDictionary`2+ValueBuilder.cs (1)
223public readonly bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\RoslynImmutableInterlocked.cs (1)
585public static bool TryRemove<TKey, TValue>(ref ImmutableSegmentedDictionary<TKey, TValue> location, TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\SegmentedDictionary`2.cs (2)
769public bool Remove(TKey key, [MaybeNullWhen(false)] out TValue value) 851public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\SegmentedHashSet`1.cs (1)
396public bool TryGetValue(T equalValue, [MaybeNullWhen(false)] out T actualValue)
Symbols\TypedConstant.cs (1)
135internal bool TryDecodeValue<T>(SpecialType specialType, [MaybeNullWhen(false)] out T value)
Microsoft.CodeAnalysis.CSharp (2)
FlowAnalysis\NullableWalker.cs (1)
6305bool tryGetReceiver(BoundCall node, [MaybeNullWhen(returnValue: false)] out BoundCall receiver)
Lowering\LocalRewriter\LocalRewriter_Call.cs (1)
362static bool tryGetReceiver(BoundCall node, [MaybeNullWhen(returnValue: false)] out BoundCall receiver)
Microsoft.CodeAnalysis.Workspaces.MSBuild.BuildHost (11)
src\Compilers\Core\Portable\Collections\ArrayBuilderExtensions.cs (1)
205public static bool TryPop<T>(this ArrayBuilder<T> builder, [MaybeNullWhen(false)] out T result)
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\Compilers\Core\Portable\InternalUtilities\SpecializedCollections.Empty.Dictionary.cs (1)
55public bool TryGetValue(TKey key, [MaybeNullWhen(returnValue: false)] out TValue value)
src\Dependencies\Collections\ImmutableSegmentedDictionary`2.cs (1)
261public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\ImmutableSegmentedDictionary`2+Builder.cs (1)
116public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\ImmutableSegmentedDictionary`2+ValueBuilder.cs (1)
223public readonly bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\RoslynImmutableInterlocked.cs (1)
585public static bool TryRemove<TKey, TValue>(ref ImmutableSegmentedDictionary<TKey, TValue> location, TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\SegmentedDictionary`2.cs (2)
769public bool Remove(TKey key, [MaybeNullWhen(false)] out TValue value) 851public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
src\Dependencies\Collections\SegmentedHashSet`1.cs (1)
396public bool TryGetValue(T equalValue, [MaybeNullWhen(false)] out T actualValue)
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)
PresentationFramework (1)
System\Windows\Markup\Localizer\BamlLocalizationDictionary.cs (1)
267internal bool TryGetValue(BamlLocalizableResourceKey key, [MaybeNullWhen(false)] out BamlLocalizableResource value)
System.Collections (14)
System\Collections\Generic\OrderedDictionary.cs (3)
744public bool Remove(TKey key, [MaybeNullWhen(false)] out TValue value) 914public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value) => TryGetValue(key, out value, out _); 924public 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) 2553public bool TryGetValue(TAlternateKey key, [MaybeNullWhen(false)] out TValue value) => 2568public bool TryGetValue(TAlternateKey key, [MaybeNullWhen(false)] out TKey actualKey, [MaybeNullWhen(false)] out TValue value) 2602public bool TryRemove(TAlternateKey key, [MaybeNullWhen(false)] out TValue value) => 2614public 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)
567public 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)
407public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value) 898private 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)
49internal bool TryGetValue(TKey key, [MaybeNullWhen(false), AllowNull] ref TValue value) 77private 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.Mail (2)
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.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 (111)
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)
1699static bool INumberBase<char>.TryConvertToChecked<TOther>(char value, [MaybeNullWhen(false)] out TOther result) 1773static bool INumberBase<char>.TryConvertToSaturating<TOther>(char value, [MaybeNullWhen(false)] out TOther result) 1847static 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)
1302static bool INumberBase<double>.TryConvertToChecked<TOther>(double value, [MaybeNullWhen(false)] out TOther result) 1370static bool INumberBase<double>.TryConvertToSaturating<TOther>(double value, [MaybeNullWhen(false)] out TOther result) 1377static bool INumberBase<double>.TryConvertToTruncating<TOther>(double value, [MaybeNullWhen(false)] out TOther result) 1383private 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)
1719static bool INumberBase<Int128>.TryConvertToChecked<TOther>(Int128 value, [MaybeNullWhen(false)] out TOther result) 1787static bool INumberBase<Int128>.TryConvertToSaturating<TOther>(Int128 value, [MaybeNullWhen(false)] out TOther result) 1862static 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)
1140static bool INumberBase<int>.TryConvertToChecked<TOther>(int value, [MaybeNullWhen(false)] out TOther result) 1208static bool INumberBase<int>.TryConvertToSaturating<TOther>(int value, [MaybeNullWhen(false)] out TOther result) 1279static bool INumberBase<int>.TryConvertToTruncating<TOther>(int value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\Int64.cs (3)
1135static bool INumberBase<long>.TryConvertToChecked<TOther>(long value, [MaybeNullWhen(false)] out TOther result) 1203static bool INumberBase<long>.TryConvertToSaturating<TOther>(long value, [MaybeNullWhen(false)] out TOther result) 1282static bool INumberBase<long>.TryConvertToTruncating<TOther>(long value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\IntPtr.cs (3)
1131static bool INumberBase<nint>.TryConvertToChecked<TOther>(nint value, [MaybeNullWhen(false)] out TOther result) 1199static bool INumberBase<nint>.TryConvertToSaturating<TOther>(nint value, [MaybeNullWhen(false)] out TOther result) 1271static 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 (3)
55public bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value) 618internal bool TryGetValueWorker(TKey key, [MaybeNullWhen(false)] out TValue value) 664internal bool TryGetEntry(int index, [NotNullWhen(true)] out 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\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)
1321static bool INumberBase<float>.TryConvertToChecked<TOther>(float value, [MaybeNullWhen(false)] out TOther result) 1389static bool INumberBase<float>.TryConvertToSaturating<TOther>(float value, [MaybeNullWhen(false)] out TOther result) 1396static bool INumberBase<float>.TryConvertToTruncating<TOther>(float value, [MaybeNullWhen(false)] out TOther result) 1402private static bool TryConvertTo<TOther>(float value, [MaybeNullWhen(false)] out TOther result)
src\libraries\System.Private.CoreLib\src\System\String.cs (2)
761static bool IParsable<string>.TryParse([NotNullWhen(true)] string? s, IFormatProvider? provider, [MaybeNullWhen(returnValue: false)] out string result) 780static 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)
841[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)
88[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 94[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 99[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 103[NotNullWhen(true), MaybeNullWhen(false)] out T data) =>
System\Private\Windows\Ole\Composition.NativeToManagedAdapter.cs (4)
588[NotNullWhen(true), MaybeNullWhen(false)] out T data) 603[NotNullWhen(true), MaybeNullWhen(false)] out T data) 615[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 619[NotNullWhen(true), MaybeNullWhen(false)] out T data) =>
System\Private\Windows\Ole\DataStore.cs (5)
17[NotNullWhen(true), MaybeNullWhen(false)] out T data) 182[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 188[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 193[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 197[NotNullWhen(true), MaybeNullWhen(false)] out T data) =>
System\Private\Windows\Ole\IDataObjectInternal.cs (4)
97[NotNullWhen(true), MaybeNullWhen(false)] out T data); 105[NotNullWhen(true), MaybeNullWhen(false)] out T data); 115[NotNullWhen(true), MaybeNullWhen(false)] out T data); 152[NotNullWhen(true), MaybeNullWhen(false)] 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)
4507static bool INumberBase<BigInteger>.TryConvertToChecked<TOther>(BigInteger value, [MaybeNullWhen(false)] out TOther result) 4626static bool INumberBase<BigInteger>.TryConvertToSaturating<TOther>(BigInteger value, [MaybeNullWhen(false)] out TOther result) 4819static 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)
220[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 (17)
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)
99public override bool TryRead([MaybeNullWhen(false)] out T item) 118public 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\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)
113public override bool TryRead([MaybeNullWhen(false)] out T item) 128public override bool TryPeek([MaybeNullWhen(false)] out T item) =>
System\Threading\Channels\UnboundedPriorityChannel.cs (2)
113public override bool TryRead([MaybeNullWhen(false)] out T item) 130public override bool TryPeek([MaybeNullWhen(false)] out T item)
System.Threading.Tasks.Dataflow (19)
Base\DataflowBlock.cs (2)
790public static bool TryReceive<TOutput>(this IReceivableSourceBlock<TOutput> source, [MaybeNullWhen(false)] out TOutput item) 1607public 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)
157public bool TryReceive(Predicate<T>? filter, [MaybeNullWhen(false)] out T item) { return _source.TryReceive(filter, out item); } 567internal bool TryReceive(Predicate<TOutput>? filter, [MaybeNullWhen(false)] out TOutput item)
Blocks\BufferBlock.cs (1)
192public bool TryReceive(Predicate<T>? filter, [MaybeNullWhen(false)] out T item) { return _source.TryReceive(filter, out item); }
Blocks\TransformBlock.cs (1)
353public bool TryReceive(Predicate<TOutput>? filter, [MaybeNullWhen(false)] out TOutput item)
Blocks\TransformManyBlock.cs (1)
562public bool TryReceive(Predicate<TOutput>? filter, [MaybeNullWhen(false)] out TOutput item) { return _source.TryReceive(filter, out item); }
Blocks\WriteOnceBlock.cs (1)
262public 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)
281internal 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 (20)
System\Windows\Forms\OLE\Clipboard.cs (2)
310[NotNullWhen(true), MaybeNullWhen(false)] out T data) 327[NotNullWhen(true), MaybeNullWhen(false)] out T data)
System\Windows\Forms\OLE\DataObject.cs (6)
185[NotNullWhen(true), MaybeNullWhen(false)] out T data) 196[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 201[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 205[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 218[NotNullWhen(true), MaybeNullWhen(false)] out T data) => 295[NotNullWhen(true), MaybeNullWhen(false)] out T data)
System\Windows\Forms\OLE\DataObjectAdapter.cs (4)
33[MaybeNullWhen(false), NotNullWhen(true)] out T data) => DataObject.TryGetData(out data); 36[MaybeNullWhen(false), NotNullWhen(true)] out T data) => DataObject.TryGetData(format, out data); 40[NotNullWhen(true), MaybeNullWhen(false)] out T data) => DataObject.TryGetData(format, autoConvert, out data); 45[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)
233public bool TryGetData<T>([MaybeNullWhen(false), NotNullWhen(true)] out T data) 240public bool TryGetData<T>(string format, [MaybeNullWhen(false), NotNullWhen(true)] out T data) 247public bool TryGetData<T>(string format, bool autoConvert, [MaybeNullWhen(false), NotNullWhen(true)] out T data) 254public bool TryGetData<T>(string format, Func<TypeName, Type> resolver, bool autoConvert, [MaybeNullWhen(false), NotNullWhen(true)] out T data)
System\Windows\Forms\DataObjectTests.cs (1)
396[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) => 29public bool TryGetData<[DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.All)] T>(string format, Func<TypeName, Type> resolver, bool autoConvert, [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) => 29public bool TryGetData<[DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.All)] T>(string format, Func<TypeName, Type> resolver, bool autoConvert, [MaybeNullWhen(false), NotNullWhen(true)] out T data) =>
xunit.assert (1)
Sdk\CollectionTracker.cs (1)
908 [MaybeNullWhen(false)] out T item)
3 references to MaybeNullWhen
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))]