Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ CreateInstance()

object? System.ComponentModel.PropertyDescriptor.CreateInstance ( [DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.PublicConstructors)] Type type)
inlineprotectedinherited

Definition at line 122 of file PropertyDescriptor.cs.

123 {
124 Type[] array = new Type[1] { typeof(Type) };
125 ConstructorInfo constructor = type.GetConstructor(array);
126 if (constructor != null)
127 {
128 return TypeDescriptor.CreateInstance(null, type, array, new object[1] { PropertyType });
129 }
130 return TypeDescriptor.CreateInstance(null, type, null, null);
131 }

References System.array, System.ComponentModel.TypeDescriptor.CreateInstance(), System.ComponentModel.PropertyDescriptor.PropertyType, and System.type.