7 writes to CreateObject
Microsoft.AspNetCore.Grpc.JsonTranscoding (1)
Internal\Json\MessageTypeInfoResolver.cs (1)
34typeInfo.CreateObject = () => Activator.CreateInstance(type)!;
System.Text.Json (6)
System\Text\Json\Serialization\Converters\Collection\ICollectionOfTConverter.cs (1)
46jsonTypeInfo.CreateObject = () => new List<TElement>();
System\Text\Json\Serialization\Converters\Collection\IDictionaryConverter.cs (1)
105jsonTypeInfo.CreateObject = () => new Dictionary<string, object?>();
System\Text\Json\Serialization\Converters\Collection\IDictionaryOfTKeyTValueConverter.cs (1)
48jsonTypeInfo.CreateObject = () => new Dictionary<TKey, TValue>();
System\Text\Json\Serialization\Converters\Collection\IListConverter.cs (1)
85jsonTypeInfo.CreateObject = () => new List<object?>();
System\Text\Json\Serialization\Converters\Collection\IListOfTConverter.cs (1)
46jsonTypeInfo.CreateObject = () => new List<TElement>();
System\Text\Json\Serialization\Converters\Collection\ISetOfTConverter.cs (1)
43jsonTypeInfo.CreateObject = () => new HashSet<TElement>();
25 references to CreateObject
System.Text.Json (25)
System\Text\Json\Serialization\Converters\Collection\ICollectionOfTConverter.cs (1)
43if (jsonTypeInfo.CreateObject is null && Type.IsAssignableFrom(typeof(List<TElement>)))
System\Text\Json\Serialization\Converters\Collection\IDictionaryConverter.cs (1)
102if (jsonTypeInfo.CreateObject is null && Type.IsAssignableFrom(typeof(Dictionary<string, object?>)))
System\Text\Json\Serialization\Converters\Collection\IDictionaryOfTKeyTValueConverter.cs (1)
45if (jsonTypeInfo.CreateObject is null && Type.IsAssignableFrom(typeof(Dictionary<TKey, TValue>)))
System\Text\Json\Serialization\Converters\Collection\IListConverter.cs (1)
82if (jsonTypeInfo.CreateObject is null && Type.IsAssignableFrom(typeof(List<object?>)))
System\Text\Json\Serialization\Converters\Collection\IListOfTConverter.cs (1)
43if (jsonTypeInfo.CreateObject is null && Type.IsAssignableFrom(typeof(List<TElement>)))
System\Text\Json\Serialization\Converters\Collection\ISetOfTConverter.cs (1)
40if (jsonTypeInfo.CreateObject is null && Type.IsAssignableFrom(typeof(HashSet<TElement>)))
System\Text\Json\Serialization\Converters\Collection\JsonCollectionConverter.cs (2)
35if (typeInfo.CreateObject is null) 40state.Current.ReturnValue = typeInfo.CreateObject();
System\Text\Json\Serialization\Converters\Collection\JsonDictionaryConverter.cs (2)
50if (typeInfo.CreateObject is null) 55state.Current.ReturnValue = typeInfo.CreateObject();
System\Text\Json\Serialization\Converters\Collection\ListOfTConverter.cs (2)
28if (state.Current.JsonTypeInfo.CreateObject == null) 33state.Current.ReturnValue = state.Current.JsonTypeInfo.CreateObject();
System\Text\Json\Serialization\Converters\Collection\QueueOfTConverter.cs (2)
26if (state.Current.JsonTypeInfo.CreateObject == null) 31state.Current.ReturnValue = state.Current.JsonTypeInfo.CreateObject();
System\Text\Json\Serialization\Converters\Collection\StackOfTConverter.cs (2)
27if (state.Current.JsonTypeInfo.CreateObject == null) 32state.Current.ReturnValue = state.Current.JsonTypeInfo.CreateObject();
System\Text\Json\Serialization\Converters\Collection\StackOrQueueConverter.cs (1)
31Func<object>? constructorDelegate = typeInfo.CreateObject;
System\Text\Json\Serialization\Converters\Object\ObjectDefaultConverter.cs (4)
41if (jsonTypeInfo.CreateObject == null) 46obj = jsonTypeInfo.CreateObject(); 117if (jsonTypeInfo.CreateObject == null) 122obj = jsonTypeInfo.CreateObject();
System\Text\Json\Serialization\JsonConverter.cs (1)
60/// Indicates that the converter can consume the <see cref="JsonTypeInfo.CreateObject"/> delegate.
System\Text\Json\Serialization\JsonSerializer.Read.HandlePropertyName.cs (1)
129Func<object>? createObjectForExtensionDataProp = jsonPropertyInfo.JsonTypeInfo.CreateObject
System\Text\Json\Serialization\Metadata\JsonMetadataServices.Helpers.cs (1)
44typeInfo.CreateObjectForExtensionDataProperty = ((JsonTypeInfo)typeInfo).CreateObject;
System\Text\Json\Serialization\Metadata\JsonTypeInfo.cs (1)
886=> Converter.ConstructorIsParameterized && CreateObject is null;