JsonSourceGenerator.Emitter.cs (45)
334CollectionType collectionType = typeGenerationSpec.CollectionType;
346case CollectionType.Array:
347case CollectionType.MemoryOfT:
348case CollectionType.ReadOnlyMemoryOfT:
351case CollectionType.IEnumerable:
352case CollectionType.IDictionary:
353case CollectionType.IList:
356case CollectionType.Stack:
357case CollectionType.Queue:
358string addMethod = collectionType == CollectionType.Stack ? "Push" : "Enqueue";
362case CollectionType.ImmutableEnumerable:
365case CollectionType.Dictionary:
366case CollectionType.IDictionaryOfTKeyTValue:
367case CollectionType.IReadOnlyDictionary:
371case CollectionType.ImmutableDictionary:
426case CollectionType.Array:
431case CollectionType.MemoryOfT:
432case CollectionType.ReadOnlyMemoryOfT:
437case CollectionType.IListOfT:
438case CollectionType.List:
439case CollectionType.IList:
1480private static string GetCollectionInfoMethodName(CollectionType collectionType)
1484CollectionType.Array => "CreateArrayInfo",
1485CollectionType.List => "CreateListInfo",
1486CollectionType.IListOfT or CollectionType.IList => "CreateIListInfo",
1487CollectionType.ICollectionOfT => "CreateICollectionInfo",
1488CollectionType.IEnumerableOfT or CollectionType.IEnumerable => "CreateIEnumerableInfo",
1489CollectionType.StackOfT or CollectionType.Stack => "CreateStackInfo",
1490CollectionType.QueueOfT or CollectionType.Queue => "CreateQueueInfo",
1491CollectionType.ConcurrentStack => "CreateConcurrentStackInfo",
1492CollectionType.ConcurrentQueue => "CreateConcurrentQueueInfo",
1493CollectionType.ImmutableEnumerable => "CreateImmutableEnumerableInfo",
1494CollectionType.IAsyncEnumerableOfT => "CreateIAsyncEnumerableInfo",
1495CollectionType.MemoryOfT => "CreateMemoryInfo",
1496CollectionType.ReadOnlyMemoryOfT => "CreateReadOnlyMemoryInfo",
1497CollectionType.ISet => "CreateISetInfo",
1499CollectionType.Dictionary => "CreateDictionaryInfo",
1500CollectionType.IDictionaryOfTKeyTValue or CollectionType.IDictionary => "CreateIDictionaryInfo",
1501CollectionType.IReadOnlyDictionary => "CreateIReadOnlyDictionaryInfo",
1502CollectionType.ImmutableDictionary => "CreateImmutableDictionaryInfo",